I'm sorry, that is:
sub test(@test is copy, $as)
{
@test[0] = 123;
};
my @test = (1, 2, 3, 4);
test(@test);
print @test[0];
After that perl6.exe will produce:
too few arguments passed (1) - 2 params expected
current instr.: 'test' pc 162 (EVAL_13:64)
called from Sub '_block11' pc 85 (EVA
On this code rakudo will hung
sub test($test is write)
{
print $test
};
test(12);
And i think that is must be compiler error, with message Like this "can't
pass const as reference" or something else.
On this code rakudo will hung
sub test($test is write)
{
print $test
};
test(12);
And i think that is must be compiler error, with message Like this "can't
pass const as reference" or something else.