# New Ticket Created by  Edwin Steiner 
# Please include the string:  [perl #115134]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org:443/rt3/Ticket/Display.html?id=115134 >


eval inside a BEGIN block seems to confuse rakudo:


$ ./perl6 -e 'BEGIN { eval "0" }
say "alive"'
===SORRY!===
Confused
at -e:1


With a semicolon, the confusion goes away:

$ ./perl6 -e 'BEGIN { eval "0" };
say "alive"'
alive


Also without the eval there is no confusion:

$ ./perl6 -e 'BEGIN { say "0" } 
say "alive"'
0
alive


This is independent from using -e or a file:

$ cat test.pl
BEGIN { eval '0' }
say 'alive'
$ ./perl6 test.pl
===SORRY!===
Confused
at test.pl:1




$ ./perl6 --version
This is perl6 version 2012.09.1-5-g3d31af9 built on parrot 4.4.0 revision 
RELEASE_4_4_0

Reply via email to