Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add tests for RT #120071 and RT #123037
  • Loading branch information
usev6 committed Oct 24, 2015
1 parent 6082102 commit 4ec7087
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion S09-typed-arrays/arrays.t
@@ -1,7 +1,7 @@
use v6;
use Test;

plan 79;
plan 81;

# L<S09/Typed arrays/>

Expand Down Expand Up @@ -242,4 +242,21 @@ plan 79;
dies-ok { my Str $x = "foo"; @a[0] := $x; }, 'Binding variablle to typed array checks type';
}

# RT #120071
{
my Int @a = 0 .. 2;
@a[1]:delete;
my @types = @a.map:{.^name};
is @types, <Int Int Int>,
'deleted element of typed arrays does not lose type info inside .map';
}

# RT #123037
{
my Int @a;
@a[4]++;
is @a.gist, '[(Int) (Int) (Int) (Int) 1]',
'.gist on typed array shows real type objects';
}

# vim: ft=perl6

0 comments on commit 4ec7087

Please sign in to comment.