On 06/03/2017 11:36 AM, Aleks-Daniel Jakimenko-Aleksejev via RT wrote:
sub s (Str() :$str) {say $str.WHAT}; s(:str<1>) # IntStr
sub s (Str :$str) {say $str.Str.WHAT}; s(:str<1>) # Str

I think the last one is coerced explicitly. Btw I didn't know about 'Str() :$str' specification. What does it do?


The previous mail about the type test 'say Str ~~ IntStr' I meant that this is the test what the coercion to Str should force isn't it?

Marcel

Reply via email to