Language ideas
Dar Scott
dsc at swcp.com
Fri May 20 17:42:43 EDT 2005
On May 20, 2005, at 1:15 PM, Robert Brenstein wrote:
>
>> > if a is (b or c) then
>> Or if a = (b or c)
>
> I find it ambiguous because it will interfere with normal 'or' clauses.
I agree. I was so busy bragging about how I had done that before that
I neglected to say that. It was not ambiguous in that ancient case
because = was not defined on booleans.
>
>> > put a into b and c
>> Or put a into b,c This is something that would be good.
>
> Akin to what can be done in C :) It could be a handy shortcut
> ocassionally but using 'and' here bother me since 'and' normally
> implies logical operation. May using comma would be better if there is
> a convincing justification to add it.
My first guess of the meanings of the two are not the same.
I had guessed that
put a into b and c
would be the same as
put a into b
put a into c
I had guessed that
put a into b, c
would be the same as
put item 1 of a into b
put item 2 to -1 of a into c
In both cases 'a' would be evaluated one time.
We already find cases where 'and' used in a syntactic sense that is not
the operator 'and' and I agree--it is awkward. However, comma is the
same way. One has to be careful in passing comma'd values as
parameters.
--
**********************************************
DSC (Dar Scott Consulting & Dar's Lab)
http://www.swcp.com/dsc/
Programming and software
**********************************************
More information about the use-livecode
mailing list