On Tue, 7 Apr 2020, Allin Cottrell wrote:
On Tue, 7 Apr 2020, Sven Schreiber wrote:
> Am 24.03.2020 um 08:38 schrieb Sven Schreiber:
>> Hi,
>> sorry, here is another one of those free-floating wishlist items: Some
>> complex packages have functions with quite many arguments, among which
>> often some boolean switches. The function calls would be easier to read
>> if one could use some keywords for on-off/yes-no/true-false instead of
>> the generic 1-0 (where it could be another general integer arg of
>> course).
>>
>> So could gretl have trivial constants simply mapped to 1 and 0? For
>> example like additional $-accessors: $true $false.
>>
>> If we don't want to have it as built-in stuff, one alternative could be
>> to add functions true() and false() (without arguments I guess) to the
>> extra package.
>>
> Hi, if nobody objects (or has any other feedback) I would eventually go
> ahead with adding these trivial functions to the extra addon.
I'm not averse to adding $true and $false a built-in constants. Any
discussion?
(In some ways TRUE and FALSE would be nicer, but I guess we've been trying to
standardize on $-ids for internals. Could we make an exception here?)
I still fail to see what the advantage is, but maybe it's just me. I see
no adverse side effects. so let's go.
-------------------------------------------------------
Riccardo (Jack) Lucchetti
Dipartimento di Scienze Economiche e Sociali (DiSES)
Università Politecnica delle Marche
(formerly known as Università di Ancona)
r.lucchetti(a)univpm.it
http://www2.econ.univpm.it/servizi/hpp/lucchetti
-------------------------------------------------------