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


my Int constant foo = 1     # should work and does in rakudo
my constant foo of Int = 1  # should work and does not in rakudo

----

using #perl6 evalbot:

r: my Int constant foo = 1 
rakudo-parrot 5fe2db, rakudo-jvm 5fe2db, rakudo-moar 5fe2db: ( no output ) 

r: my constant foo of Int = 1 
rakudo-jvm 5fe2db: OUTPUT«===SORRY!=== Error while compiling 
/tmp/tmpfile␀Wrong number of arguments passed; expected 1..1, but got 1␀at 
/tmp/tmpfile:1␀------> ␀» 
..rakudo-moar 5fe2db: OUTPUT«===SORRY!=== Error while 
compiling /tmp/tmpfile␀Unexpected named parameter 'SYMBOL' passed␀at 
/tmp/tmpfile:1␀------> ␀» 
..rakudo-parrot 5fe2db: OUTPUT«===SORRY!=== Error while 
compiling /tmp/tmpfile␀too many named arguments: 1 passed, 0 used␀at 
/tmp/tmpfile:1␀------> ␀» 

std: my constant foo of Int = 1 
std 09dda5b: OUTPUT«ok 00:01 122m␀»

Reply via email to