I'm thinking that an early 2020b release would be good, to address the macOS Catalina security issue (about which we'll probably hear more).

In that context, I think most of the changes since 2020a are harmless, with the possible exception of the modification of funcerr(), so I'd like to revisit that.

Quick recap:

(1) For some time we've had a "funcerr" command, which triggers an early return from a function with an error flagged; it has an optional argument, namely a specific message to be displayed.

(2) Before the 2020a release we added a function version of this, the point being that in a function argument (unlike a command argument) you could factor in a call to sprintf(), hence saving a line of code if you wanted to show a context-dependent message.

(3) More recently I extended funcerr() to take two arguments: first a boolean error condition, then the message. This could save another two lines of code: instead of wrapping the call to funcerr in "if" and "endif" you could embed the condition in the funcerr() call (which would then not trigger if the boolean were false).

Here are my second thoughts. Usually when we offer a function version of a command it's just a matter of adding convenience, for users comfortable with function calls, with no change in semantics relative to the command. That's true of the first version of funcerr() but not the latest one. So my latest change is kinda unruly.

If we were willing to add a new function we might call it "iferror", as in

  iferror(error_condition, message)

This would work just like the new funcerr(), but funcerr() itself would revert to its usage in 2020a, parallel to the command. Any thoughts?

Allin
_______________________________________________
Gretl-devel mailing list -- gretl-devel@gretlml.univpm.it
To unsubscribe send an email to gretl-devel-le...@gretlml.univpm.it
Website: 
https://gretlml.univpm.it/postorius/lists/gretl-devel.gretlml.univpm.it/

Reply via email to