Elizabeth Mattijsen via RT wrote:
>dd9b760 makes it impossible to create a Pair with a mutable key.

Doesn't work.  It defeats my original test case, but you're not actually
type-constraining the key, you're only removing a container wrapper.
So by adding a second container:

> my $a = 3; my $A = $a.VAR; my $b = Pair.new($A.VAR, "z"); say $b.WHICH; $a = 
> 5; say $b.WHICH
Pair|Int|3|Str|z
Pair|Int|5|Str|z

It would be better to reject the Scalar-as-key case entirely, rather
than unwrap.

-zefram

Reply via email to