[Aldor-l] How to emulate new infix and postfix operators in Aldor

Page, Bill Bill.Page at drdc-rddc.gc.ca
Tue Aug 29 20:09:17 EDT 2006


Ralf,

On Tuesday, August 29, 2006 7:54 PM you wrote:
> Bill Page wrote: 
> > But I don't see much "syntactic sugar" here.
> 
> The syntactic sugar is that you don't *see* the "apply" function.
> The compiler add "apply" for you without changing the semantics
> of the program.

I would put this differently. 'apply' is a just another generic tie-in
(see http://www.aldor.org/docs/HTML/chap11.html) like 'bracket'. And
juxaposition always denotes application (that's semantics!). See
http://www.aldor.org/docs/HTML/chap4.html#6 No syntax involved here at
all. But I guess it doesn't really matter what you call it unless you
are the compiler writer. :)

> ... 
> Try
> 
> 1 2 (+)
> 
> That works.
> 

Neat. Thanks.

Regards,
Bill Page.




More information about the Aldor-l mailing list