Function type method reference parsing error
Neal Gafter
neal at gafter.com
Mon May 19 08:39:46 PDT 2008
They should both work. Thanks for reporting this!
I think I need a bug tracking system.
On Mon, May 19, 2008 at 6:03 AM, Mark Mahieu <mark at twistedbanana.demon.co.uk>
wrote:
> I came across this one in the wreckage of a late-night copy/pasting
> accident:
>
>
> public class ParseError {
>
> public static void main(String[] args) {
>
> Object o;
> o = {=>void}#invoke(); // ok
> o = {int=>void}#invoke(int); // fails to compile
> }
> }
>
>
> ParseError.java:7: illegal start of expression
> o = {int=>void}#invoke(int); // fails to compile
> ^
> ParseError.java:7: ';' expected
> o = {int=>void}#invoke(int); // fails to compile
> ^
> ParseError.java:7: illegal start of type
> o = {int=>void}#invoke(int); // fails to compile
> ^
> ParseError.java:7: ';' expected
> o = {int=>void}#invoke(int); // fails to compile
> ^
> ParseError.java:7: illegal start of type
> o = {int=>void}#invoke(int); // fails to compile
> ^
> ParseError.java:7: <identifier> expected
> o = {int=>void}#invoke(int); // fails to compile
> ^
> ParseError.java:7: ';' expected
> o = {int=>void}#invoke(int); // fails to compile
> ^
> ParseError.java:9: class, interface, or enum expected
> }
> ^
> 8 errors
>
>
> Regards,
>
> Mark
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/closures-dev/attachments/20080519/41e4fb78/attachment.html
More information about the closures-dev
mailing list