Syntax...
Neal Gafter
neal at gafter.com
Fri Nov 20 21:52:10 PST 2009
I can't quite infer the structure of the language from your examples. Can
you please show the syntax grammar (BNF) for this suggestion?
On Fri, Nov 20, 2009 at 6:14 PM, Vladimir Kirichenko <
vladimir.kirichenko at gmail.com> wrote:
> Vladimir Kirichenko wrote:
> > Or lets go more wild:
> >
> > named function/closure/lambda:
> >
> > fun int plusOne(int x) => x + 1;
> >
> > anonymous:
> >
> > x.aMethod(fun int(int x) => x + 1);
> >
> > type decl:
> >
> > void aMethod( fun int f(int x) ) {....f(1)... }
>
> Assignment:
>
> fun int plusOne(int x) => x + 1;
>
> fun int inc(int x) = plusOne;
>
> --
> Best Regards,
> Vladimir Kirichenko
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/closures-dev/attachments/20091120/17fdf3c1/attachment.html
More information about the closures-dev
mailing list