On Tue May 05 13:41:01 2015, [email protected] wrote:
> See http://irclog.perlgeek.de/perl6/2015-05-05#i_10552113
>
> Besides the obvious problem (.clone should work there), in the process
> of examining it I encountered another oddity: trapping it with a try
> block doesn't catch the exception unless an explicit CATCH block is
> added with accompanying default; the implicit CATCH misses it
> entirely.
It looks like there were different problems back in May, which seem to
be resolved now.
First, using .clone on an array died. This does no longer happen:
$ perl6 -e 'my @a = 42; @a.clone; say "alive"'
alive
$ perl6 -e 'my @a = 42; my @b; try { @b = @a.clone }; say "alive";
@a.push: 44; say @b; say @a'
alive
[42]
[42 44]
I added two tests for this to S12-attributes/clone.t with commit
25daf16f55.
Second, using a try block didn't catch the exception. AFAIU this is
fixed and skids++ added some tests for this problem with commit
1ad644d704. Since the example with .clone no longer throws an
exception, I don't know whether additional tests are needed and how
they should look like.
Anyway, I'm closing this ticket as 'resolved'. Please reopen if you
have an idea for additional tests.