Seems to work now that we have DefiniteHOW:

m: sub a() returns Int:U { 42 }; say &a.returns; a
rakudo-moar 8f4e90: OUTPUT«(Int:U)␤Type check failed for return value; expected 
Int:U but got Int␤  in sub a at /tmp/LRo5pcMZof:1␤  in block <unit> at 
/tmp/LRo5pcMZof:1␤␤»

m: sub a() returns Int:D { Int }; say &a.returns; a
rakudo-moar 8f4e90: OUTPUT«(Int:D)␤Type check failed for return value; expected 
Int:D but got Int␤  in sub a at /tmp/SnKt55D7zj:1␤  in block <unit> at 
/tmp/SnKt55D7zj:1␤␤»

Tagging it testneeded.

Reply via email to