Permalink
Browse files

niecza unfudge (mostly from autounfudge)

  • Loading branch information...
1 parent 62db446 commit 0b449f6f3e9b51a24e2c76b4d63644fb6390febf @coke coke committed Dec 21, 2011
@@ -161,7 +161,6 @@ plan 46;
# L<S02/Single-line Comments/"# may not be used as"
# delimiter quoting>
-#?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
{
my $a;
ok eval('$a = q{ 32 }'), 'sanity check';
View
@@ -129,7 +129,6 @@ plan 57;
%other<a> = %hash;
is +%other, 1, '%other[$key] = %hash works (1)';
- #?niecza skip 'Cannot use value like Capture as a Number'
is +%other<a>, 3, '%other[$key] = %hash works (2)';
}
View
@@ -145,7 +145,6 @@ Note that non-ASCII tests are kept in quoting-unicode.t
# L<S02/Interpolating into a single-quoted string/using the \qq>
#?rakudo skip 'q[..] with variations'
-#?niecza skip 'backslash q'
{ # \qq[] constructs interpolate in q[]
my ( @q1, @q2, @q3, @q4 ) = ();
@q1 = q[$foo \qq[$bar]];
@@ -364,7 +363,6 @@ FOO
};
#?rakudo skip '\c97 etc'
-#?niecza skip 'charspec'
{ # weird char escape sequences
is("\c97", "a", '\c97 is "a"');
is("\c102oo", "foo", '\c102 is "f", works next to other letters');
@@ -58,7 +58,6 @@ nok foo().defined, 'contextual $*VAR is undefined';
# the lexical alias that's also created should work just fine:
#
# Notsomuch in niecza, as the "lexical alias" is only seen by the compiler...
-#?niecza 2 skip 'our $*a'
{
sub f { $*a };
our $*a = 'h';
View
@@ -224,7 +224,6 @@ my @array2 = ("test", 1, Mu);
ok !(try { @arr[*-1] }), "readonly accessing [*-1] of an empty array is ok (2)";
dies_ok { @arr[*-1] = 42 }, "assigning to [*-1] of an empty array is fatal";
#?rakudo skip "binding not yet fatal"
- #?niecza skip "no binding of array elements"
dies_ok { @arr[*-1] := 42 }, "binding [*-1] of an empty array is fatal";
}
@@ -235,7 +234,6 @@ my @array2 = ("test", 1, Mu);
ok !(try { @arr[*-2] }), "readonly accessing [*-2] of an one-elem array is ok (2)";
dies_ok { @arr[*-2] = 42 }, "assigning to [*-2] of an one-elem array is fatal";
#?rakudo skip "binding not yet fatal"
- #?niecza skip "no binding of array elements"
dies_ok { @arr[*-2] := 42 }, "binding [*-2] of an empty array is fatal";
}
@@ -250,7 +248,6 @@ my @array2 = ("test", 1, Mu);
"through a variable is run-time error";
dies_ok { @arr[$minus_one] = 42 }, "assigning to [-1] of a normal array is fatal";
#?rakudo skip "binding not yet fatal"
- #?niecza skip "no array binding yet"
dies_ok { @arr[$minus_one] := 42 }, "binding [-1] of a normal array is fatal";
}
View
@@ -54,7 +54,6 @@ is Bool::True.perl, 'Bool::True', 'True.perl';
is Bool::False.perl, 'Bool::False', 'False.perl';
# numification - interaction with +
-#?niecza 2 skip "Numeric"
ok(+Bool::True ~~ Numeric);
ok(+Bool::False ~~ Numeric);
isa_ok(+Bool::True, Int, 'True numifies to an Int');
View
@@ -109,7 +109,6 @@ isa_ok (1..*-1)(10), Range, '(1..*-1)(10) is a Range';
is $c(0, -10, 3), 3, 'that can work with three different arguments';
}
-#?niecza skip 'hangs'
{
my $c = * + * * *;
ok $c ~~ Code, '* + * * * generated a closure';
@@ -240,7 +240,6 @@ plan 85;
}
# Tests former autothreading junction example from Synopsis 09
-#?niecza skip '&skip'
{
my $c = 0;
View
@@ -232,7 +232,6 @@ my @e;
is(~@r, ~@e, "operator call on integer list elements (Same thing, upspace form)");
};
-#?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
#?rakudo skip 'postfix forms'
{ # unary postfix again, but with a twist
my @r;
@@ -489,7 +488,6 @@ my @e;
is %a<c>, 3, 'hash - correct result from >>++';
}
-#?niecza skip 'our sub'
#?DOES 4
{
our sub postfix:<!>($a) {
@@ -762,7 +760,6 @@ my @e;
# RT #77876
# L<S03/Hyper operators/'@array »+=»'>
# Hyper assignment operators
-#?niecza skip 'fails horribly'
{
my @array = 3, 8, 2, 9, 3, 8;
@r = @array »+=« (1, 2, 3, 4, 5, 6);
View
@@ -59,7 +59,6 @@ L<"http://groups.google.de/group/perl.perl6.language/msg/bd9eb275d5da2eda">
}
#?rakudo skip "=:= NYI"
-#?niecza skip "reduce/binding interaction issues"
{
my ($x, $y);
ok ( [=:=] $x, $x, $x), '[=:=] basic sanity 1';
@@ -70,7 +69,6 @@ L<"http://groups.google.de/group/perl.perl6.language/msg/bd9eb275d5da2eda">
ok ( [=:=] $y, $x, $y), '[=:=] after binding';
}
-#?niecza skip "=== on value types NYI"
{
my $a = [1, 2];
my $b = [1, 2];
@@ -342,7 +340,6 @@ is( ([\R~] 'a'..*).[^8].join(', '), 'a, ba, cba, dcba, edcba, fedcba, gfedcba, h
# rakudo had a problem where once-used meta operators weren't installed
# in a sufficiently global location, so using a meta operator in class once
# makes it unusable further on
-#?niecza skip 'gather for'
{
class A {
method m { return [~] gather for ^3 {take 'a'} }
View
@@ -159,7 +159,6 @@ sub tryeq_sloppy ($lhs, $rhs, $todo1 = '') {
}
# Believe it or not, this one overflows on 32-bit Rakduo as of 3/8/2010.
-#?niecza skip 'non-positive-integer **'
{
# RT #73262
is_approx 7**(-1), 0.14285714285714, '7**(-1) works';
@@ -159,7 +159,6 @@ is(((not 1,42)[1]), 42, "not is tighter than comma");
# list prefix
-#?niecza skip 'Undeclared name: "Z"'
{
my $c = any 1, 2 Z 3, 4;
ok($c == 3, "any is less tight than comma and Z");
@@ -20,7 +20,6 @@ my %hash5 = ( "foo" => 1, "bar" => 1, "gorch" => Mu, "baz" => Mu );
#?rakudo todo 'nom regression'
#?niecza todo
ok eval_elsewhere('(%hash1 ~~ %hash2)'), "hash keys identical";
- #?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
ok eval_elsewhere('!(%hash1 ~~ %hash4)'), "hash keys differ";
}
@@ -141,7 +141,6 @@ eval('
# Following are OO tests, but I think they fit better in var/temp.t than in
# oo/.
# L<S06/Temporization/temp invokes its argument's .TEMP method.>
-#?niecza 2 skip 'needs clarification on correct behavior'
{
my $was_in_own_temp_handler = 0;
@@ -9,7 +9,6 @@ plan 6;
eval_lives_ok 'my $x; my $x',
'it is legal to declare my $x twice in the same scope.';
-#?niecza skip 'Not working'
#?rakudo todo 'nom regression'
eval_lives_ok 'state $x; state $x',
'it is legal to declare state $x twice in the same scope.';
View
@@ -170,7 +170,6 @@ my $z = 42; #OK not used
# interaction of my and eval
# yes, it's weird... but that's the way it is
# http://irclog.perlgeek.de/perl6/2009-03-19#i_1001177
-#?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
{
sub eval_elsewhere($str) {
eval $str;
@@ -195,7 +194,6 @@ my $z = 42; #OK not used
}
# RT #62766
-#?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
{
eval_lives_ok 'my $a;my $x if 0;$a = $x', 'my $x if 0';
@@ -210,8 +208,8 @@ my $z = 42; #OK not used
{
my $a;
- #?niecza 2 skip 'still fails?'
#?rakudo todo 'fails'
+ #?niecza 2 skip 'still fails?'
eval_lives_ok 'do { die "foo";my Int $x;CATCH { default { $a = ?($x ~~ Int) } } }';
#?rakudo todo 'previous test skipped'
ok $a, 'unreached declaration in effect at block start';
View
@@ -41,7 +41,6 @@ eval_lives_ok 'my $i = 1; do { $i++ } if $i;',
any branch, the return value is undefined in item context and ()
in list context.
=end comment
-#?niecza skip 'Nil'
{
my $x = do if 0 { 1 } elsif 0 { 2 };
ok !$x.defined, 'when if does not execute any branch, return undefined';
@@ -101,7 +100,6 @@ is eval('my $i; A: do { $i++; redo A until $i == 5; $i-- }; $i'), 4,
"'redo' works with label";
#?rakudo skip 'last not implemented'
-#?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
{
is eval('
my $i;
@@ -118,7 +116,6 @@ is eval('my $i; A: do { $i++; redo A until $i == 5; $i-- }; $i'), 4,
# <agentzh> audreyt: btw, can i use redo in the do-once loop?
# <audreyt> it can, and it will redo it
#?rakudo skip 'redo not implemented'
-#?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
{
is eval('
my $i;
View
@@ -452,7 +452,6 @@ eval_dies_ok('for(0..5) { }','keyword needs at least one whitespace after it');
}
# RT #62478
-#?niecza skip 'different interpretation of eval'
{
try { eval('for (my $ii = 1; $ii <= 3; $ii++) { say $ii; }') };
ok "$!" ~~ /C\-style/, 'mentions C-style';
@@ -461,7 +460,6 @@ eval_dies_ok('for(0..5) { }','keyword needs at least one whitespace after it');
}
# RT #65212
-#?niecza skip 'different eval'
{
my $parsed = 0;
try { eval '$parsed = 1; for (1..3)->$n { last }' };
@@ -480,7 +478,6 @@ eval_dies_ok('for(0..5) { }','keyword needs at least one whitespace after it');
eval_dies_ok 'for (my $i; $i <=3; $i++) { $i; }', 'Unsupported use of C-style "for (;;)" loop; in Perl 6 please use "loop (;;)"';
}
-#?niecza skip 'different eval semantics'
{
try { eval 'for (my $x; $x <=3; $x++) { $i; }'; diag($!) };
ok $! ~~ / 'C-style' /, 'Sensible error message';
View
@@ -92,7 +92,6 @@ plan 20;
}
# gather statement prefix
-#?niecza skip "gather for"
{
my @out = gather for 1..5 {
take $_;
@@ -114,7 +113,6 @@ plan 20;
is($count, 2, "gather is lazy");
}
-#?niecza skip 'take-rw'
{
my @list = gather {
my $v = 1;
@@ -126,7 +124,6 @@ plan 20;
is ~@list, "2 4 6 8 10", "gather with nested while";
}
-#?niecza skip 'take-rw'
{
my @list = gather {
loop (my $v = 1; $v <= 10; $v++)
View
@@ -203,11 +203,8 @@ Tests the given block, as defined in L<S04/"Switch statements">
class TestIt { method passit { 1; }; has %.testing is rw; };
my $passed = 0;
ok( eval('given TestIt.new { $_.passit; };'), '$_. method calls' );
- #?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
ok( eval('given TestIt.new { .passit; };'), '. method calls' );
- #?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
ok( eval('given TestIt.new { $_.testing<a> = 1; };'),'$_. attribute access' );
- #?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
ok( eval('given TestIt.new { .testing<a> = 1; };'), '. attribute access' );
my $t = TestIt.new;
given $t { when TestIt { $passed = 1;} };
View
@@ -94,7 +94,6 @@ plan 14;
}
# RT #71466
-#?niecza skip ':$!to broken'
eval_lives_ok('class A { has $!to; method x { loop { (:$!to); } } };', 'pair colon syntax in a loop refers to an attribute works');
# RT #63760
View
@@ -23,7 +23,6 @@ my regex once {<&abc>}
ok("abcabcabcabcd" ~~ m/<&once>/, 'Once match');
ok($/, 'Once matched');
is(~$/, "abc", 'Once matched');
-#?niecza skip 'auto $0 confuses this'
ok(@($/) == 0, 'Once no array capture');
ok(%($/).keys == 0, 'Once no hash capture');
@@ -33,7 +32,6 @@ my regex rep {<&abc>**{4}}
ok("abcabcabcabcd" ~~ m/<&rep>/, 'Rep match');
ok($/, 'Rep matched');
is(~$/, "abcabcabcabc", 'Rep matched');
-#?niecza skip 'auto $0 confuses this'
ok(@($/) == 0, 'Rep no array capture');
ok(%($/).keys == 0, 'Rep no hash capture');
@@ -46,7 +44,6 @@ is(~$/, "abc", 'Cap zero matched');
is(~$/<cap>, "abc", 'Cap captured');
is(~$/<cap><abc>, "abc", 'Cap abc captured');
-#?niecza skip 'auto $0 confuses this'
ok(@($/) == 0, 'Cap no array capture');
ok(%($/).keys == 1, 'Cap hash capture');
@@ -60,7 +57,6 @@ is(~$/<repcap><abc>[0], "abc", 'Repcap abc zero captured');
is(~$/<repcap><abc>[1], "abc", 'Repcap abc one captured');
is(~$/<repcap><abc>[2], "abc", 'Repcap abc two captured');
is(~$/<repcap><abc>[3], "abc", 'Repcap abc three captured');
-#?niecza skip 'auto $0 confuses this'
ok(@($/) == 0, 'Repcap no array capture');
View
@@ -29,7 +29,6 @@ nok($/.from.defined, 'Match pos is undefined');
my regex Aa { A .* a }
#?rakudo 3 skip 'lexical lookup of <Aa>'
-#?niecza skip 'Unable to resolve method Aa in class Cursor'
ok($str ~~ m/ .*? <Aa> /, 'Subrule match from 3');
#?niecza skip 'System.InvalidCastException: Cannot cast from source type to destination type.'
ok($/.from == 0, 'Full match pos is 0');
View
@@ -36,7 +36,6 @@ ok 'x(ab' !~~ m/<&t1>/, '~ and constant atoms (missing closing bracket)';
ok '(()' !~~ m/^ <&recursive> $/, '"(()" is not matched';
#?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
ok '())' !~~ m/^ <&recursive> $/, '"())" is not matched';
- #?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
ok 'a()' !~~ m/^ <&recursive> $/, '"a()" is not matched';
}
View
@@ -64,7 +64,6 @@ eval_dies_ok( "'RT 71702' ~~ /<[d..b]>? RT/",
ok 'b' ~~ /<[. .. b]>/, 'weird char class matches at least its end point';
# RT #69682
-#?niecza skip 'Unsupported use of - as character range; in Perl 6 please use ..'
{
try { eval "/<[a-z]>/"; }
ok ~$! ~~ / 'Unsupported use of - as character range; in Perl 6 please use ..'/,
View
@@ -18,7 +18,6 @@ lives_ok({"aa!" ~~ /'a'/}, 'quoted "a" is valid');
# used to be a pugs bug
#?rakudo skip 'calling <foo> from outer scopes'
-#?niecza skip 'Unable to resolve method foo in class Cursor'
{
my rule foo { \{ };
ok '{' ~~ /<foo>/, '\\{ in a rule (+)';
View
@@ -13,7 +13,6 @@ is $str, 'hello', '.. it does not do side effect';
ok $str.match(/h/)~~Match, '.. it returns a Match object';
#?DOES 6
-#?niecza skip 'System.IndexOutOfRangeException: Array index is out of range.'
{
for ('a'..'f') {
my $r = eval("rx/$_/");
View
@@ -8,9 +8,7 @@ use Test;
multi sub uno_mas( Int $ro ) { $ro_call++; return 1 + $ro }
multi sub uno_mas( Int $rw is rw ) { $rw_call++; return ++$rw }
- #?niecza skip 'Ambiguous dispatch for &uno_mas'
is uno_mas(42), 43, 'multi works with constant';
- #?niecza todo
is $ro_call, 1, 'read-only multi was called';
my $x = 99;
@@ -46,14 +46,12 @@ plan 15;
# lexical multi can add to package multi if no outer lexical ones
multi waz() { 1 }
-#?niecza skip 'No matching candidates to dispatch for &waz'
{
my multi waz($x) { 2 } #OK not used
is(waz(), 1, 'got multi from package');
is(waz('slon'), 2, 'lexical multi also callable');
}
is(waz(), 1, 'multi from package still callable outside the inner scope...');
-#?niecza skip 'No matching candidates to dispatch for &waz'
dies_ok { eval("waz('vtak')") }, '...but lexical multi no longer callable';
# RT #78208
@@ -46,7 +46,6 @@ eval_dies_ok
eval_lives_ok
'my List sub f () { return () }; f()',
'return of empty list should live';
-#?niecza skip 'Multiple prefix constraints not yet supported'
is eval('my List sub f () { return () }; (f(), "a")'), ['a'],
'return of empty list should be empty list';
Oops, something went wrong.

0 comments on commit 0b449f6

Please sign in to comment.