A snippet:

    my @a = 1..10;
    put [email protected]; # output 1
    put so(+@a); # output True
    put (+@a).so; # output True

This caught me because I used [email protected] when I tried to do something like:

    # in a class with 'has Bool $.pass;'
    return unless ( $!pass = [email protected] );
    # fails with a Type mismatch of Int being assigned to Bool

Is this an expected result, or a bug?


(I was going to ask this on StackOverflow, but it seems so like a bug that I decided to ask here first)

Reply via email to