Inconsistent comma requirements

Alex Tweedly alex at tweedly.net
Sat Jun 24 13:26:29 EDT 2017



On 24/06/2017 16:37, Richard Gaskin via use-livecode wrote:
>
> Two questions:
>
> How many of you have never before known that commas are optional 
> between definition arguments?
>
> For those who've known about this, were you confused to discover that 
> this only works for definitions but not calls?
>
I did, and no didn't find it confusing.

I discovered it maybe a year or two ago, when some code I downloaded 
used it.

I blinked a few times in surprise, shuddered - and knew that it was just 
a (mis)feature that I will never, ever use :-)

>
> On the other hand, perhaps a rule could be introduced that any 
> keywords used in arg strings with no commas when calling a custom 
> handler are treated as literal text. 
NO, please not.

Just think of the consequences ...
   DoSomething tA and tB
is different from
   put tA and tB into temp
   DoSomething temp
and indeed from
   DoSomething (tA and tB)

-- Alex.




More information about the use-livecode mailing list