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


The code below fails:

$ perl6 -e 'subset UInt of Int where * >= 0; sub foo (UInt $bar?) { }; foo()'
Parameter '' requires an instance, but a type object was passed
  in method Bridge at src/gen/CORE.setting:3097
  in sub infix:<>=> at src/gen/CORE.setting:3028
  in block  at -e:1

whereas the following code works (type of $bar was changed to Int):

$ perl6 -e 'sub foo (Int $bar?) { }; foo()'

Ref: http://irclog.perlgeek.de/perl6/2013-01-17#i_6343821

Reply via email to