On Tue Oct 30 18:29:04 2012, MAUKE wrote:
Show quoted text> $ cat bug/infinite-loop
> #!perl
> use Method::Signatures::Simple;
> func f() :A () {}
> __END__
> $ perl bug/infinite-loop
> ^C
>
> The above code sends the parser into an infinite loop.
This is actually a bug in Devel::Declare::Context::Simple. It apparently
doesn't parse the code attributes robustly enough.
Just to be sure, that attribute specification is a syntax error in
normal Perl too:
perl -E 'sub x() :A () { }'
Invalid separator character '(' in attribute list at -e line 1, near
"sub x() :A "
syntax error at -e line 1, near "sub x() :A "
Execution of -e aborted due to compilation errors.