Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Native arrays are implemented
  • Loading branch information
usev6 committed May 6, 2015
1 parent 25f28b6 commit 2945c76
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions S02-types/array-shapes.t
Expand Up @@ -74,15 +74,15 @@ plan 25;
'type constraints on my @arr[num] of Type works (2)';
}

#?rakudo skip 'native arrays NYI RT #124506'
{
my int @arr = 1, 2, 3, 4, 5;
is(@arr, <1 2 3 4 5>, 'my type @arr works');
is_deeply push( @arr, 6), [1,2,3,4,5,6], 'push on native @arr works');
throws_like {push @arr, 's'},
is push(@arr, 6), [1,2,3,4,5,6], 'push on native @arr works';
#?rakudo 2 todo 'X::AdHoc "This type cannot unbox to a native integer" RT #125123'
throws_like { EVAL 'push @arr, "s"' },
X::TypeCheck,
'type constraints on my type @arr works (1)';
throws_like {push @arr, 4.2},
throws_like { EVAL 'push @arr, 4.2' },
X::TypeCheck,
'type constraints on my type @arr works (2)';
}
Expand Down

0 comments on commit 2945c76

Please sign in to comment.