Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

niecza fudging

  • Loading branch information...
commit d0e149b4bdc736e8535db6c1dee9e368482c6145 1 parent 72da761
Will Coleda coke authored
Showing with 383 additions and 173 deletions.
  1. +6 −0 S02-literals/array-interpolation.t
  2. +2 −0  S03-operators/also.t
  3. +32 −1 S03-operators/range.t
  4. +42 −0 S03-operators/subscript-adverbs.t
  5. +2 −0  S04-phasers/end.t
  6. +2 −0  S04-statements/terminator.t
  7. +6 −0 S05-capture/match-object.t
  8. +202 −170 S05-mass/stdrules.t
  9. +6 −0 S05-match/blocks.t
  10. +2 −0  S05-match/non-capturing.t
  11. +4 −0 S05-match/positions.t
  12. +3 −0  S05-metachars/closure.t
  13. +7 −0 S05-metachars/newline.t
  14. +10 −0 S05-metachars/tilde.t
  15. +2 −0  S05-metasyntax/charset.t
  16. +15 −0 S05-metasyntax/litvar.t
  17. +1 −0  S05-metasyntax/sequential-alternation.t
  18. +2 −0  S05-metasyntax/unknown.t
  19. +3 −0  S05-modifier/counted-match.t
  20. +3 −0  S05-modifier/ignorecase.t
  21. +2 −0  S05-substitution/match.t
  22. +2 −0  S06-currying/assuming-and-mmd.t
  23. +6 −1 S06-multi/by-trait.t
  24. +4 −0 S06-other/anon-hashes-vs-blocks.t
  25. +2 −0  S06-routine-modifiers/scoped-named-subs.t
  26. +6 −1 S06-signature/caller-param.t
  27. +4 −0 S06-signature/code.t
  28. +1 −0  S06-signature/errors.t
  29. +4 −0 S06-signature/scalar-type.t
6 S02-literals/array-interpolation.t
View
@@ -16,7 +16,9 @@ plan 12;
is ~@array, "a b c d",
"arrays whose elements don't contain whitespace stringify correctly (1)";
+ #?niecza skip 'No value for parameter $index in CORE postcircumfix:<[ ]>'
is "@array[]", "a b c d", "arrays whose elements don't contain whitespace stringify correctly (2)";
+ #?niecza skip 'No value for parameter $index in CORE postcircumfix:<[ ]>'
is "@array.[]", "a b c d", '@array.[] interpolates';
is "@array", "@array", '@array (without brackets) doesnt interpolate';
}
@@ -27,6 +29,7 @@ plan 12;
is ~@array, "a b c d e f g h",
"arrays with embedded array references stringify correctly (1)";
+ #?niecza skip 'No value for parameter $index in CORE postcircumfix:<[ ]>'
is "@array[]", "a b c d e f g h", "arrays with embedded array references stringify correctly (2)";
}
@@ -35,6 +38,7 @@ plan 12;
is ~@array, "a b c",
"array whose elements do contain whitespace stringify correctly (1-1)";
+ #?niecza skip 'No value for parameter $index in CORE postcircumfix:<[ ]>'
is "@array[]", "a b c", "array whose elements do contain whitespace stringify correctly (1-2)";
}
@@ -43,6 +47,7 @@ plan 12;
is ~@array, "a\t b c",
"array whose elements do contain whitespace stringify correctly (2-1)";
+ #?niecza skip 'No value for parameter $index in CORE postcircumfix:<[ ]>'
is "@array[]", "a\t b c", "array whose elements do contain whitespace stringify correctly (2-2)";
}
@@ -51,6 +56,7 @@ plan 12;
is ~@array, "a\t b c",
"array whose elements do contain whitespace stringify correctly (3-1)";
+ #?niecza skip 'No value for parameter $index in CORE postcircumfix:<[ ]>'
is "@array[]", "a\t b c", "array whose elements do contain whitespace stringify correctly (3-2)";
}
2  S03-operators/also.t
View
@@ -4,6 +4,7 @@ plan 8;
# L<S03/"Junctive and (all) precedence"/"infix:<&>">
ok ?(1 S& 2), "basic infix:<S&>";
+#?niecza skip 'Excess arguments to CORE seqop, used 3 of 4 positionals'
ok ?(1 S& 2 S& 3), "basic infix:<S&> (multiple S&'s)";
#?rakudo todo 'nom regression'
ok !(0 S& 1), "S& has and-semantics (first term 0)";
@@ -20,6 +21,7 @@ my $executed = 0;
#?rakudo todo 'nom regression'
ok !('a' ~~ 'b' S& { $executed = 1; True }), 'and semantics';
+#?niecza skip 'TODO'
ok !$executed, 'short-circuit';
# vim: ft=perl6
33 S03-operators/range.t
View
@@ -8,30 +8,48 @@ plan 113;
# L<S03/Nonchaining binary precedence/Range object constructor>
# 3..2 must *not* produce "3 2". Use reverse to get a reversed range. -lwall
-
+#?niecza skip 'TODO'
is ~(3..6), "3 4 5 6", "(..) works on numbers (1)";
+#?niecza skip 'TODO'
is ~(3..3), "3", "(..) works on numbers (2)";
+#?niecza skip 'TODO'
is ~(3..2), "", "(..) works on auto-rev numbers (3)";
+#?niecza skip 'TODO'
is ~(8..11), "8 9 10 11", "(..) works on carried numbers (3)";
+#?niecza skip 'TODO'
is ~("a".."c"), "a b c", "(..) works on chars (1)";
+#?niecza skip 'TODO'
is ~("a".."a"), "a", "(..) works on chars (2)";
+#?niecza skip 'TODO'
is ~("b".."a"), "", "(..) works on chars (3)";
+#?niecza skip 'TODO'
is ~("a".."z"), "a b c d e f g h i j k l m n o p q r s t u v w x y z", "(..) works on char range ending in z";
+#?niecza skip 'TODO'
is ~("A".."Z"), "A B C D E F G H I J K L M N O P Q R S T U V W X Y Z", "(..) works on char range ending in Z";
+#?niecza skip 'TODO'
is ~("Y".."AB"), "", "(..) works on carried chars (3)";
#?rakudo 4 skip 'Spec under design here'
+#?niecza skip 'TODO'
is ~('Y'..'z'), 'Y Z', '(..) works on uppercase letter .. lowercase letter (1)';
+#?niecza skip 'TODO'
is ~('z'..'Y'), '', '(..) works on auto-rev uppercase letter .. lowercase letter (2)';
+#?niecza skip 'TODO'
is ~('Y'..'_'), 'Y Z', '(..) works on letter .. non-letter (1)';
+#?niecza skip 'TODO'
is ~('_'..'Y'), '', '(..) works on auto-rev letter .. non-letter (2)';
#?rakudo skip "nom regression: No applicable candidates found to dispatch to for 'Numeric'."
+#?niecza skip 'TODO'
is ~(' '..' '), ' ', 'all-whitespace range works';
+#?niecza skip 'TODO'
is ~(3..9-3), "3 4 5 6", "(..) has correct precedence (1)";
+#?niecza skip 'TODO'
is ~(5..9-5), "", "(..) has correct precedence (2)";
+#?niecza skip 'TODO'
is ~(2+1..6), "3 4 5 6", "(..) has correct precedence (3)";
+#?niecza skip 'TODO'
is ~(2+5..6), "", "(..) has correct precedence (4)";
# Test the three exclusive range operators:
@@ -65,12 +83,15 @@ is ['a' ^..^ 'a'], [], "double-exclusive range (x ^..^ x) where x is a char";
is 1.5 ~~ 1^..^2, Bool::True, "lazy evaluation of the range operator";
# Test the unary ^ operator
+#?niecza skip 'TODO'
is ~(^5), "0 1 2 3 4", "unary ^num produces the range 0..^num";
is [^1], [0], "unary ^ on the boundary ^1 works";
is [^0], [], "unary ^0 produces null range";
is [^-1], [], "unary ^-1 produces null range";
is [^0.1], [0], "unary ^0.1 produces the range 0..^x where 0 < x < 1";
+#?niecza skip 'System.FormatException: Unknown char: a'
is [^'a'], [], "unary ^'a' produces null range";
+#?niecza skip 'TODO'
is ~(^"5"), "0 1 2 3 4", 'unary ^"num" produces the range 0..^num';
{
@@ -90,6 +111,7 @@ is (<c b a> Z 1..5).join('|'), 'c|1|b|2|a|3', 'Ranges and infix:<Z>';
# two ranges
is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
+#?niecza skip 'TODO'
{
# Test with floats
# 2006-12-05:
@@ -127,6 +149,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
## remove these tests from the suite.
# RT #58018
# RT #76950
+#?niecza skip 'TODO'
{
my @three = (1, 1, 1);
my @one = 1;
@@ -146,6 +169,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
is (0..3).map({$_ * 2}).join('|'), '0|2|4|6', '.map works on ranges';
is (0..3).grep({$_ == 1|3}).join('|'), '1|3', '.grep works on ranges';
is (1..3).first({ $_ % 2 == 0}), 2, '.first works on ranges';
+ #?niecza skip 'Unable to resolve method reduce in class Range'
is (1..3).reduce({ $^a + $^b}), 6, '.reduce works on ranges';
}
@@ -162,6 +186,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
is $range.max.WHAT.gist, "Str()", 'range end is a string';
lives_ok { "$range" }, 'can stringify range';
#?rakudo skip "nom regression: No applicable candidates found to dispatch to for 'Numeric'."
+ #?niecza skip 'TODO'
is ~$range, "100.B 101.B 102.B", 'range is correct';
}
@@ -174,6 +199,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
is $range.max, 3, 'range ends at three';
#?rakudo 2 skip "range stringification: Method 'succ' not found for invocant of class 'Match'"
lives_ok { "$range" }, 'can stringify range';
+ #?niecza skip 'TODO'
is ~$range, "1 2 3", 'range is correct';
}
# and another set, just for the lulz
@@ -182,6 +208,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
ok '1 3' ~~ /(\d) . (\d)/, 'regex sanity';
isa_ok $0..$1, Range, '$0..$1 constructs a Range';
#?rakudo skip "range with match object endpoints: Method 'succ' not found for invocant of class 'Match'"
+ #?niecza skip 'cannot increment a value of type Match'
is ($0..$1).join('|'), '1|2|3', 'range from $0..$1';
}
{
@@ -191,6 +218,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
is $range.min, 1, 'range starts at one';
is $range.max, 3, 'range ends at three';
lives_ok { "$range" }, 'can stringify range';
+ #?niecza skip 'TODO'
is ~$range, "1 2 3", 'range is correct';
}
{
@@ -202,6 +230,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
is $range.max, 3, 'range ends at three';
is $range.max.WHAT.gist, "Str()", 'range end is a string';
lives_ok { "$range" }, 'can stringify range';
+ #?niecza skip 'TODO'
is ~$range, "1 2 3", 'range is correct';
}
@@ -209,6 +238,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
# List as implicitly numeric:>
#?rakudo todo 'forbid Ranges and Lists as Range endpoints'
+#?niecza skip 'TODO'
{
ok !defined(try { 0 .. ^10 }), '0 .. ^10 is illegal';
ok !defined(try { 0 .. (0, 1, 2) }), '0 .. List is illegal';
@@ -223,6 +253,7 @@ is (1..6 Z 'a' .. 'c').join, '1a2b3c', 'Ranges and infix:<Z>';
# RT #82620
#?rakudo todo "range leaking Parrot types: Method 'trans' not found for invocant of class 'Str'"
+#?niecza skip 'TODO'
{
lives_ok {("a".."b").map({.trans(""=>"")}).perl},
"range doesn't leak Parrot types";
42 S03-operators/subscript-adverbs.t
View
@@ -20,12 +20,16 @@ plan 64;
is @array[0], "a",
":p on an array returns lvalues (like normal subscripts do as well)";
+ #?niecza skip 'Cannot use value like Pair as a number'
is +(@array[0,1]:p), 2,
":p on an array returned a two-elem array";
+ #?niecza skip 'TODO'
is ~(@array[0,1]:p), "0\ta 1\tB",
":p on an array returned a two-elem array consisting of the correct pairs";
+ #?niecza skip 'Cannot use value like Pair as a number'
is +(@array[42,23]:p), 0, ":p on an array weeded out non-existing entries (1)";
+ #?niecza skip 'TODO'
is ~(@array[42,23]:p), "", ":p on an array weeded out non-existing entries (2)";
}
@@ -42,12 +46,16 @@ plan 64;
is @array[0], "a",
":kv on an array returns lvalues (like normal subscripts do as well)";
+ #?niecza skip 'TODO'
is +(@array[0,1]:kv), 4,
":kv on an array returned a four-elem array";
+ #?niecza skip 'TODO'
is ~(@array[0,1]:kv), "0 a 1 B",
":kv on an array returned the correct four-elem array";
+ #?niecza skip 'TODO'
is +(@array[42,23]:kv), 0, ":kv on an array weeded out non-existing entries (1)";
+ #?niecza skip 'TODO'
is ~(@array[42,23]:kv), "", ":kv on an array weeded out non-existing entries (2)";
}
@@ -55,6 +63,7 @@ plan 64;
{
my @array = <A B>;
+ #?niecza skip 'TODO'
is +(@array[0]:k), 1,
":k on an array returned an one-elem array";
is ~(@array[0]:k), "0",
@@ -65,7 +74,9 @@ plan 64;
is ~(@array[0,1]:k), "0 1",
":k on an array returned the correct two-elem array";
+ #?niecza skip 'TODO'
is +(@array[42,23]:k), 0, ":k on an array weeded out non-existing entries (1)";
+ #?niecza skip 'TODO'
is ~(@array[42,23]:k), "", ":k on an array weeded out non-existing entries (2)";
}
@@ -73,21 +84,29 @@ plan 64;
{
my @array = <A B>;
+ #?niecza skip 'Excess arguments to KERNEL Array.postcircumfix:<[ ]>, unused named v'
is +(@array[0]:v), 1,
":v on an array returned an one-elem array";
+ #?niecza skip 'Excess arguments to KERNEL Array.postcircumfix:<[ ]>, unused named v'
is ~(@array[0]:v), "A",
":v on an array returned the correct one-elem array";
+ #?niecza skip 'TODO'
lives_ok {@array[0]:v = "a"}, 'can assign to @array[0]:v';
+ #?niecza skip 'TODO'
is @array[0], "a",
":v on an array returns lvalues (like normal subscripts do as well)";
+ #?niecza skip 'Excess arguments to KERNEL Array.postcircumfix:<[ ]>, unused named v'
is +(@array[0,1]:v), 2,
":v on an array returned a tow-elem array";
+ #?niecza skip 'Excess arguments to KERNEL Array.postcircumfix:<[ ]>, unused named v'
is ~(@array[0,1]:v), "a B",
":v on an array returned the correct two-elem array";
+ #?niecza skip 'Excess arguments to KERNEL Array.postcircumfix:<[ ]>, unused named v'
is +(@array[42,23]:v), 0, ":v on an array weeded out non-existing entries (1)";
+ #?niecza skip 'Excess arguments to KERNEL Array.postcircumfix:<[ ]>, unused named v'
is ~(@array[42,23]:v), "", ":v on an array weeded out non-existing entries (2)";
}
@@ -105,12 +124,16 @@ plan 64;
is %hash<0>, "a",
":p on a hash returns lvalues (like normal subscripts do as well)";
+ #?niecza skip 'Cannot use value like Pair as a number'
is +(%hash<0 1>:p), 2,
":p on a hash returned a two-elem array";
+ #?niecza skip 'TODO'
is ~(%hash<0 1>:p), "0\ta 1\tB",
":p on a hash returned a two-elem array consisting of the correct pairs";
+ #?niecza skip 'Cannot use value like Pair as a number'
is +(%hash<42 23>:p), 0, ":p on a hash weeded out non-existing entries (1)";
+ #?niecza skip 'TODO'
is ~(%hash<42 23>:p), "", ":p on a hash weeded out non-existing entries (2)";
}
@@ -127,12 +150,16 @@ plan 64;
is %hash<0>, "a",
":kv on a hash returns lvalues (like normal subscripts do as well)";
+ #?niecza skip 'TODO'
is +(%hash<0 1>:kv), 4,
":kv on a hash returned a four-elem array";
+ #?niecza skip 'TODO'
is ~(%hash<0 1>:kv), "0 a 1 B",
":kv on a hash returned the correct four-elem array";
+ #?niecza skip 'TODO'
is +(%hash<42 23>:kv), 0, ":kv on a hash weeded out non-existing entries (1)";
+ #?niecza skip 'TODO'
is ~(%hash<42 23>:kv), "", ":kv on a hash weeded out non-existing entries (2)";
}
@@ -140,6 +167,7 @@ plan 64;
{
my %hash = (0 => "A", 1 => "B");
+ #?niecza skip 'TODO'
is +(%hash<0>:k), 1,
":k on a hash returned an one-elem array";
is ~(%hash<0>:k), "0",
@@ -150,7 +178,9 @@ plan 64;
is ~(%hash<0 1>:k), "0 1",
":k on a hash returned the correct two-elem array";
+ #?niecza skip 'TODO'
is +(%hash<42 23>:k), 0, ":k on a hash weeded out non-existing entries (1)";
+ #?niecza skip 'TODO'
is ~(%hash<42 23>:k), "", ":k on a hash weeded out non-existing entries (2)";
}
@@ -158,21 +188,29 @@ plan 64;
{
my %hash = (0 => "A", 1 => "B");
+ #?niecza skip 'Excess arguments to KERNEL Hash.postcircumfix:<{ }>, unused named v'
is +(%hash<0>:v), 1,
":v on a hash returned an one-elem array";
+ #?niecza skip 'Excess arguments to KERNEL Hash.postcircumfix:<{ }>, unused named v'
is ~(%hash<0>:v), "A",
":v on a hash returned the correct one-elem array";
+ #?niecza skip 'TODO'
lives_ok {%hash<0>:v = "a"}, 'can assign to %hash<0>:v';
+ #?niecza skip 'TODO'
is %hash<0>, "a",
":v on a hash returns lvalues (like normal subscripts do as well)";
+ #?niecza skip 'Excess arguments to KERNEL Hash.postcircumfix:<{ }>, unused named v'
is +(%hash<0 1>:v), 2,
":v on a hash returned a tow-elem array";
+ #?niecza skip 'Excess arguments to KERNEL Hash.postcircumfix:<{ }>, unused named v'
is ~(%hash<0 1>:v), "a B",
":v on a hash returned the correct two-elem array";
+ #?niecza skip 'Excess arguments to KERNEL Hash.postcircumfix:<{ }>, unused named v'
is +(%hash<42 23>:v), 0, ":v on a hash weeded out non-existing entries (1)";
+ #?niecza skip 'Excess arguments to KERNEL Hash.postcircumfix:<{ }>, unused named v'
is ~(%hash<42 23>:v), "", ":v on a hash weeded out non-existing entries (2)";
}
@@ -181,8 +219,10 @@ plan 64;
{
my @array = (42, Mu, 23);
+ #?niecza skip 'TODO'
is +(@array[0,1,2]:kv), 6,
"undefined but existing entries should not be weeded out (1)";
+ #?niecza skip 'TODO'
is ~(@array[0,1,2]:kv), "0 42 1 2 23",
"undefined but existing entries should not be weeded out (2)";
}
@@ -190,8 +230,10 @@ plan 64;
{
my %hash = (0 => 42, 1 => Mu, 2 => 23);
+ #?niecza skip 'TODO'
is +(%hash<0 1 2>:kv), 6,
"undefined but existing entries should not be weeded out (3)";
+ #?niecza skip 'TODO'
is ~(%hash<0 1 2>:kv), "0 42 1 2 23",
"undefined but existing entries should not be weeded out (4)";
}
2  S04-phasers/end.t
View
@@ -8,9 +8,11 @@ eval_lives_ok 'my $x = 3; END { $x * $x }',
my $a = 0;
#?rakudo 2 todo 'lexicals and eval()'
+#?niecza skip 'TODO'
eval_lives_ok 'my $x = 3; END { $a = $x * $x };',
'and those from eval as well';
+#?niecza skip 'TODO'
is $a, 9, 'and they really worked';
# vim: ft=perl6
2  S04-statements/terminator.t
View
@@ -43,6 +43,7 @@ eval_dies_ok('my $x = ', 'incomplete expression');
';
#?pugs todo 'parsing'
+ #?niecza skip 'TODO'
is($z[0], 3, 'auto-curly doesn\'t apply unless we\'re at top level');
}
@@ -56,6 +57,7 @@ eval_dies_ok '(1) { $foo = 2 }', 'parens do not eat spaces after them';
# RT #79964
#?rakudo todo 'RT #79964'
+#?niecza skip 'TODO'
eval_lives_ok "my &f;\nsub g() { }\n&f;", 'implicit terminator before & sigil';
# vim: ft=perl6
6 S05-capture/match-object.t
View
@@ -13,13 +13,19 @@ ok $/.defined, '.defined';
is $/.Str, '12', '.Str';
is $/.from, 2, '.from';
is $/.to, 4, '.to';
+#?niecza skip 'Unable to resolve method prematch in class Match'
is $/.prematch, 'ab', '.prematch';
+#?niecza skip 'Unable to resolve method postmatch in class Match'
is $/.postmatch, 'de', '.postmatch';
+#?niecza skip 'TODO'
is $/.list.elems, 0, '.list (empty)';
is $/.hash.elems, 0, '.hash (empty)';
is $/.keys.elems, 0, '.keys (empty)';
+#?niecza skip 'TODO'
is $/.values.elems, 0, '.values (empty)';
+#?niecza skip 'TODO'
is $/.pairs.elems, 0, '.pairs (empty)';
+#?niecza skip 'TODO'
is $/.kv.elems, 0, '.kv (empty)';
nok 'abde' ~~ /\d/, 'no match';
372 S05-mass/stdrules.t
View
@@ -55,58 +55,67 @@ ok("\x07A" ~~ m/<+alpha>/, q{Match unanchored alpha as charset});
# space
-ok("\x[9]" ~~ m/^<.space>$/, q{Match space as subrule});
-ok(!( "\x[9]" ~~ m/^<!space>.$/ ), q{Don't match negated space as subrule} );
-ok(!( "\x[9]" ~~ m/^<-space>$/ ), q{Don't match inverted space as subrule} );
-ok(!( "(" ~~ m/^<.space>$/ ), q{Don't match unrelated space as subrule} );
-ok("(" ~~ m/^<!space>.$/, q{Match unrelated negated space as subrule});
-ok("(" ~~ m/^<-space>$/, q{Match unrelated inverted space as subrule});
-
-ok("\x[9]" ~~ m/^<+space>$/, q{Match space as charset});
-ok("\x[9]" ~~ m/^<+[A]+space>$/, q{Match compound space as charset});
-ok(!( "\x[9]" ~~ m/^<-space>$/ ), q{Don't match externally inverted space as charset} );
-ok(!( "\x[9]" ~~ m/^<+[A]-space>$/ ), q{Don't match compound inverted space as charset} );
-ok(!( "\x[9]" ~~ m/^<-space>$/ ), q{Don't match internally inverted space as charset} );
-ok(!( "(" ~~ m/^<+space>$/ ), q{Don't match unrelated space as charset} );
-ok("(" ~~ m/^<-space>$/, q{Match inverted space as charset});
-ok("(\x[9]" ~~ m/<+space>/, q{Match unanchored space as charset});
+#?niecza skip 'Unable to resolve method space in class Cursor'
+{
+ ok("\x[9]" ~~ m/^<.space>$/, q{Match space as subrule});
+ ok(!( "\x[9]" ~~ m/^<!space>.$/ ), q{Don't match negated space as subrule} );
+ ok(!( "\x[9]" ~~ m/^<-space>$/ ), q{Don't match inverted space as subrule} );
+ ok(!( "(" ~~ m/^<.space>$/ ), q{Don't match unrelated space as subrule} );
+ ok("(" ~~ m/^<!space>.$/, q{Match unrelated negated space as subrule});
+ ok("(" ~~ m/^<-space>$/, q{Match unrelated inverted space as subrule});
+
+ ok("\x[9]" ~~ m/^<+space>$/, q{Match space as charset});
+ ok("\x[9]" ~~ m/^<+[A]+space>$/, q{Match compound space as charset});
+ ok(!( "\x[9]" ~~ m/^<-space>$/ ), q{Don't match externally inverted space as charset} );
+ ok(!( "\x[9]" ~~ m/^<+[A]-space>$/ ), q{Don't match compound inverted space as charset} );
+ ok(!( "\x[9]" ~~ m/^<-space>$/ ), q{Don't match internally inverted space as charset} );
+ ok(!( "(" ~~ m/^<+space>$/ ), q{Don't match unrelated space as charset} );
+ ok("(" ~~ m/^<-space>$/, q{Match inverted space as charset});
+ ok("(\x[9]" ~~ m/<+space>/, q{Match unanchored space as charset});
+}
# digit
-ok("0" ~~ m/^<.digit>$/, q{Match digit as subrule});
-ok(!( "0" ~~ m/^<!digit>.$/ ), q{Don't match negated digit as subrule} );
-ok(!( "0" ~~ m/^<-digit>$/ ), q{Don't match inverted digit as subrule} );
-ok(!( "\x[C]" ~~ m/^<.digit>$/ ), q{Don't match unrelated digit as subrule} );
-ok("\x[C]" ~~ m/^<!digit>.$/, q{Match unrelated negated digit as subrule});
-ok("\x[C]" ~~ m/^<-digit>$/, q{Match unrelated inverted digit as subrule});
-
-ok("0" ~~ m/^<+digit>$/, q{Match digit as charset});
-ok("0" ~~ m/^<+[A]+digit>$/, q{Match compound digit as charset});
-ok(!( "0" ~~ m/^<-digit>$/ ), q{Don't match externally inverted digit as charset} );
-ok(!( "0" ~~ m/^<+[A]-digit>$/ ), q{Don't match compound inverted digit as charset} );
-ok(!( "0" ~~ m/^<-digit>$/ ), q{Don't match internally inverted digit as charset} );
-ok(!( "\x[C]" ~~ m/^<+digit>$/ ), q{Don't match unrelated digit as charset} );
-ok("\x[C]" ~~ m/^<-digit>$/, q{Match inverted digit as charset});
-ok("\x[C]0" ~~ m/<+digit>/, q{Match unanchored digit as charset});
+#?niecza skip 'Unable to resolve method digit in class Cursor'
+{
+ ok("0" ~~ m/^<.digit>$/, q{Match digit as subrule});
+ ok(!( "0" ~~ m/^<!digit>.$/ ), q{Don't match negated digit as subrule} );
+ ok(!( "0" ~~ m/^<-digit>$/ ), q{Don't match inverted digit as subrule} );
+ ok(!( "\x[C]" ~~ m/^<.digit>$/ ), q{Don't match unrelated digit as subrule} );
+ ok("\x[C]" ~~ m/^<!digit>.$/, q{Match unrelated negated digit as subrule});
+ ok("\x[C]" ~~ m/^<-digit>$/, q{Match unrelated inverted digit as subrule});
+
+ ok("0" ~~ m/^<+digit>$/, q{Match digit as charset});
+ ok("0" ~~ m/^<+[A]+digit>$/, q{Match compound digit as charset});
+ ok(!( "0" ~~ m/^<-digit>$/ ), q{Don't match externally inverted digit as charset} );
+ ok(!( "0" ~~ m/^<+[A]-digit>$/ ), q{Don't match compound inverted digit as charset} );
+ ok(!( "0" ~~ m/^<-digit>$/ ), q{Don't match internally inverted digit as charset} );
+ ok(!( "\x[C]" ~~ m/^<+digit>$/ ), q{Don't match unrelated digit as charset} );
+ ok("\x[C]" ~~ m/^<-digit>$/, q{Match inverted digit as charset});
+ ok("\x[C]0" ~~ m/<+digit>/, q{Match unanchored digit as charset});
+}
# alnum
-ok("n" ~~ m/^<.alnum>$/, q{Match alnum as subrule});
-ok(!( "n" ~~ m/^<!alnum>.$/ ), q{Don't match negated alnum as subrule} );
-ok(!( "n" ~~ m/^<-alnum>$/ ), q{Don't match inverted alnum as subrule} );
-ok(!( '{' ~~ m/^<.alnum>$/ ), q{Don't match unrelated alnum as subrule} );
-ok('{' ~~ m/^<!alnum>.$/, q{Match unrelated negated alnum as subrule});
-ok('{' ~~ m/^<-alnum>$/, q{Match unrelated inverted alnum as subrule});
-
-ok("n" ~~ m/^<+alnum>$/, q{Match alnum as charset});
-ok("n" ~~ m/^<+[A]+alnum>$/, q{Match compound alnum as charset});
-ok(!( "n" ~~ m/^<-alnum>$/ ), q{Don't match externally inverted alnum as charset} );
-ok(!( "n" ~~ m/^<+[A]-alnum>$/ ), q{Don't match compound inverted alnum as charset} );
-
-ok(!( "n" ~~ m/^<-alnum>$/ ), q{Don't match internally inverted alnum as charset} );
-ok(!( '{' ~~ m/^<+alnum>$/ ), q{Don't match unrelated alnum as charset} );
-ok('{' ~~ m/^<-alnum>$/, q{Match inverted alnum as charset});
-ok('{n' ~~ m/<+alnum>/, q{Match unanchored alnum as charset});
+#?niecza skip 'Unable to resolve method alnum in class Cursor'
+{
+ ok("n" ~~ m/^<.alnum>$/, q{Match alnum as subrule});
+ ok(!( "n" ~~ m/^<!alnum>.$/ ), q{Don't match negated alnum as subrule} );
+ ok(!( "n" ~~ m/^<-alnum>$/ ), q{Don't match inverted alnum as subrule} );
+ ok(!( '{' ~~ m/^<.alnum>$/ ), q{Don't match unrelated alnum as subrule} );
+ ok('{' ~~ m/^<!alnum>.$/, q{Match unrelated negated alnum as subrule});
+ ok('{' ~~ m/^<-alnum>$/, q{Match unrelated inverted alnum as subrule});
+
+ ok("n" ~~ m/^<+alnum>$/, q{Match alnum as charset});
+ ok("n" ~~ m/^<+[A]+alnum>$/, q{Match compound alnum as charset});
+ ok(!( "n" ~~ m/^<-alnum>$/ ), q{Don't match externally inverted alnum as charset} );
+ ok(!( "n" ~~ m/^<+[A]-alnum>$/ ), q{Don't match compound inverted alnum as charset} );
+
+ ok(!( "n" ~~ m/^<-alnum>$/ ), q{Don't match internally inverted alnum as charset} );
+ ok(!( '{' ~~ m/^<+alnum>$/ ), q{Don't match unrelated alnum as charset} );
+ ok('{' ~~ m/^<-alnum>$/, q{Match inverted alnum as charset});
+ ok('{n' ~~ m/<+alnum>/, q{Match unanchored alnum as charset});
+}
# ascii
@@ -123,133 +132,153 @@ ok('{n' ~~ m/<+alnum>/, q{Match unanchored alnum as charset});
# ok("+" ~~ m/<+ascii>/, q{Match unanchored ascii as charset});
# blank
-
-ok("\x[9]" ~~ m/^<.blank>$/, q{Match blank as subrule});
-ok(!( "\x[9]" ~~ m/^<!blank>.$/ ), q{Don't match negated blank as subrule} );
-ok(!( "\x[9]" ~~ m/^<-blank>$/ ), q{Don't match inverted blank as subrule} );
-ok(!( "&" ~~ m/^<.blank>$/ ), q{Don't match unrelated blank as subrule} );
-ok("&" ~~ m/^<!blank>.$/, q{Match unrelated negated blank as subrule});
-ok("&" ~~ m/^<-blank>$/, q{Match unrelated inverted blank as subrule});
-
-ok("\x[9]" ~~ m/^<+blank>$/, q{Match blank as charset});
-ok("\x[9]" ~~ m/^<+[A]+blank>$/, q{Match compound blank as charset});
-ok(!( "\x[9]" ~~ m/^<-blank>$/ ), q{Don't match externally inverted blank as charset} );
-ok(!( "\x[9]" ~~ m/^<+[A]-blank>$/ ), q{Don't match compound inverted blank as charset} );
-ok(!( "\x[9]" ~~ m/^<-blank>$/ ), q{Don't match internally inverted blank as charset} );
-ok(!( "&" ~~ m/^<+blank>$/ ), q{Don't match unrelated blank as charset} );
-ok("&" ~~ m/^<-blank>$/, q{Match inverted blank as charset});
-ok("&\x[9]" ~~ m/<+blank>/, q{Match unanchored blank as charset} );
+#?niecza skip 'Unable to resolve method blank in class Cursor'
+{
+ ok("\x[9]" ~~ m/^<.blank>$/, q{Match blank as subrule});
+ ok(!( "\x[9]" ~~ m/^<!blank>.$/ ), q{Don't match negated blank as subrule} );
+ ok(!( "\x[9]" ~~ m/^<-blank>$/ ), q{Don't match inverted blank as subrule} );
+ ok(!( "&" ~~ m/^<.blank>$/ ), q{Don't match unrelated blank as subrule} );
+ ok("&" ~~ m/^<!blank>.$/, q{Match unrelated negated blank as subrule});
+ ok("&" ~~ m/^<-blank>$/, q{Match unrelated inverted blank as subrule});
+
+ ok("\x[9]" ~~ m/^<+blank>$/, q{Match blank as charset});
+ ok("\x[9]" ~~ m/^<+[A]+blank>$/, q{Match compound blank as charset});
+ ok(!( "\x[9]" ~~ m/^<-blank>$/ ), q{Don't match externally inverted blank as charset} );
+ ok(!( "\x[9]" ~~ m/^<+[A]-blank>$/ ), q{Don't match compound inverted blank as charset} );
+ ok(!( "\x[9]" ~~ m/^<-blank>$/ ), q{Don't match internally inverted blank as charset} );
+ ok(!( "&" ~~ m/^<+blank>$/ ), q{Don't match unrelated blank as charset} );
+ ok("&" ~~ m/^<-blank>$/, q{Match inverted blank as charset});
+ ok("&\x[9]" ~~ m/<+blank>/, q{Match unanchored blank as charset} );
+}
# cntrl
-ok("\x[7F]" ~~ m/^<.cntrl>$/, q{Match cntrl as subrule});
-ok(!( "\x[7F]" ~~ m/^<!cntrl>.$/ ), q{Don't match negated cntrl as subrule} );
-ok(!( "\x[7F]" ~~ m/^<-cntrl>$/ ), q{Don't match inverted cntrl as subrule} );
-ok(!( "=" ~~ m/^<.cntrl>$/ ), q{Don't match unrelated cntrl as subrule} );
-ok("=" ~~ m/^<!cntrl>.$/, q{Match unrelated negated cntrl as subrule});
-ok("=" ~~ m/^<-cntrl>$/, q{Match unrelated inverted cntrl as subrule});
-
-ok("\x[7F]" ~~ m/^<+cntrl>$/, q{Match cntrl as charset} );
-ok("\x[7F]" ~~ m/^<+[A]+cntrl>$/, q{Match compound cntrl as charset});
-ok(!( "\x[7F]" ~~ m/^<-cntrl>$/ ), q{Don't match externally inverted cntrl as charset} );
-ok(!( "\x[7F]" ~~ m/^<+[A]-cntrl>$/ ), q{Don't match compound inverted cntrl as charset} );
-ok(!( "\x[7F]" ~~ m/^<-cntrl>$/ ), q{Don't match internally inverted cntrl as charset} );
-ok(!( "=" ~~ m/^<+cntrl>$/ ), q{Don't match unrelated cntrl as charset} );
-ok("=" ~~ m/^<-cntrl>$/, q{Match inverted cntrl as charset});
-ok("=\x[7F]" ~~ m/<+cntrl>/, q{Match unanchored cntrl as charset} );
+#?niecza skip 'Unable to resolve method cntrl in class Cursor'
+{
+ ok("\x[7F]" ~~ m/^<.cntrl>$/, q{Match cntrl as subrule});
+ ok(!( "\x[7F]" ~~ m/^<!cntrl>.$/ ), q{Don't match negated cntrl as subrule} );
+ ok(!( "\x[7F]" ~~ m/^<-cntrl>$/ ), q{Don't match inverted cntrl as subrule} );
+ ok(!( "=" ~~ m/^<.cntrl>$/ ), q{Don't match unrelated cntrl as subrule} );
+ ok("=" ~~ m/^<!cntrl>.$/, q{Match unrelated negated cntrl as subrule});
+ ok("=" ~~ m/^<-cntrl>$/, q{Match unrelated inverted cntrl as subrule});
+
+ ok("\x[7F]" ~~ m/^<+cntrl>$/, q{Match cntrl as charset} );
+ ok("\x[7F]" ~~ m/^<+[A]+cntrl>$/, q{Match compound cntrl as charset});
+ ok(!( "\x[7F]" ~~ m/^<-cntrl>$/ ), q{Don't match externally inverted cntrl as charset} );
+ ok(!( "\x[7F]" ~~ m/^<+[A]-cntrl>$/ ), q{Don't match compound inverted cntrl as charset} );
+ ok(!( "\x[7F]" ~~ m/^<-cntrl>$/ ), q{Don't match internally inverted cntrl as charset} );
+ ok(!( "=" ~~ m/^<+cntrl>$/ ), q{Don't match unrelated cntrl as charset} );
+ ok("=" ~~ m/^<-cntrl>$/, q{Match inverted cntrl as charset});
+ ok("=\x[7F]" ~~ m/<+cntrl>/, q{Match unanchored cntrl as charset} );
+}
# graph
-#?rakudo 14 skip '<.graph>'
-ok("V" ~~ m/^<.graph>$/, q{Match graph as subrule});
-ok(!( "V" ~~ m/^<!graph>.$/ ), q{Don't match negated graph as subrule} );
-ok(!( "V" ~~ m/^<-graph>$/ ), q{Don't match inverted graph as subrule} );
-ok(!( "\x[7F]" ~~ m/^<.graph>$/ ), q{Don't match unrelated graph as subrule} );
-ok("\x[7F]" ~~ m/^<!graph>.$/, q{Match unrelated negated graph as subrule});
-ok("\x[7F]" ~~ m/^<-graph>$/, q{Match unrelated inverted graph as subrule});
-
-ok("V" ~~ m/^<+graph>$/, q{Match graph as charset} );
-ok("V" ~~ m/^<+[A]+graph>$/, q{Match compound graph as charset});
-ok(!( "V" ~~ m/^<-graph>$/ ), q{Don't match externally inverted graph as charset} );
-ok(!( "V" ~~ m/^<+[A]-graph>$/ ), q{Don't match compound inverted graph as charset} );
-ok(!( "V" ~~ m/^<-graph>$/ ), q{Don't match internally inverted graph as charset} );
-ok(!( "\x[7F]" ~~ m/^<+graph>$/ ), q{Don't match unrelated graph as charset} );
-ok("\x[7F]" ~~ m/^<-graph>$/, q{Match inverted graph as charset});
-ok("\x[7F]V" ~~ m/<+graph>/, q{Match unanchored graph as charset} );
+#?niecza skip 'Unable to resolve method cntrl in class Cursor'
+#?rakudo skip '<.graph>'
+{
+ ok("V" ~~ m/^<.graph>$/, q{Match graph as subrule});
+ ok(!( "V" ~~ m/^<!graph>.$/ ), q{Don't match negated graph as subrule} );
+ ok(!( "V" ~~ m/^<-graph>$/ ), q{Don't match inverted graph as subrule} );
+ ok(!( "\x[7F]" ~~ m/^<.graph>$/ ), q{Don't match unrelated graph as subrule} );
+ ok("\x[7F]" ~~ m/^<!graph>.$/, q{Match unrelated negated graph as subrule});
+ ok("\x[7F]" ~~ m/^<-graph>$/, q{Match unrelated inverted graph as subrule});
+
+ ok("V" ~~ m/^<+graph>$/, q{Match graph as charset} );
+ ok("V" ~~ m/^<+[A]+graph>$/, q{Match compound graph as charset});
+ ok(!( "V" ~~ m/^<-graph>$/ ), q{Don't match externally inverted graph as charset} );
+ ok(!( "V" ~~ m/^<+[A]-graph>$/ ), q{Don't match compound inverted graph as charset} );
+ ok(!( "V" ~~ m/^<-graph>$/ ), q{Don't match internally inverted graph as charset} );
+ ok(!( "\x[7F]" ~~ m/^<+graph>$/ ), q{Don't match unrelated graph as charset} );
+ ok("\x[7F]" ~~ m/^<-graph>$/, q{Match inverted graph as charset});
+ ok("\x[7F]V" ~~ m/<+graph>/, q{Match unanchored graph as charset} );
+}
# lower
-ok("a" ~~ m/^<.lower>$/, q{Match lower as subrule});
-ok(!( "a" ~~ m/^<!lower>.$/ ), q{Don't match negated lower as subrule} );
-ok(!( "a" ~~ m/^<-lower>$/ ), q{Don't match inverted lower as subrule} );
-ok(!( "\x[1E]" ~~ m/^<.lower>$/ ), q{Don't match unrelated lower as subrule} );
-ok("\x[1E]" ~~ m/^<!lower>.$/, q{Match unrelated negated lower as subrule});
-ok("\x[1E]" ~~ m/^<-lower>$/, q{Match unrelated inverted lower as subrule});
-
-ok("a" ~~ m/^<+lower>$/, q{Match lower as charset} );
-ok("a" ~~ m/^<+[A]+lower>$/, q{Match compound lower as charset});
-ok(!( "a" ~~ m/^<-lower>$/ ), q{Don't match externally inverted lower as charset} );
-ok(!( "a" ~~ m/^<+[A]-lower>$/ ), q{Don't match compound inverted lower as charset} );
-ok(!( "a" ~~ m/^<-lower>$/ ), q{Don't match internally inverted lower as charset} );
-ok(!( "\x[1E]" ~~ m/^<+lower>$/ ), q{Don't match unrelated lower as charset} );
-ok("\x[1E]" ~~ m/^<-lower>$/, q{Match inverted lower as charset});
-ok("\x[1E]a" ~~ m/<+lower>/, q{Match unanchored lower as charset} );
+#?niecza skip 'Unable to resolve method lower in class Cursor'
+{
+ ok("a" ~~ m/^<.lower>$/, q{Match lower as subrule});
+ ok(!( "a" ~~ m/^<!lower>.$/ ), q{Don't match negated lower as subrule} );
+ ok(!( "a" ~~ m/^<-lower>$/ ), q{Don't match inverted lower as subrule} );
+ ok(!( "\x[1E]" ~~ m/^<.lower>$/ ), q{Don't match unrelated lower as subrule} );
+ ok("\x[1E]" ~~ m/^<!lower>.$/, q{Match unrelated negated lower as subrule});
+ ok("\x[1E]" ~~ m/^<-lower>$/, q{Match unrelated inverted lower as subrule});
+
+ ok("a" ~~ m/^<+lower>$/, q{Match lower as charset} );
+ ok("a" ~~ m/^<+[A]+lower>$/, q{Match compound lower as charset});
+ ok(!( "a" ~~ m/^<-lower>$/ ), q{Don't match externally inverted lower as charset} );
+ ok(!( "a" ~~ m/^<+[A]-lower>$/ ), q{Don't match compound inverted lower as charset} );
+ ok(!( "a" ~~ m/^<-lower>$/ ), q{Don't match internally inverted lower as charset} );
+ ok(!( "\x[1E]" ~~ m/^<+lower>$/ ), q{Don't match unrelated lower as charset} );
+ ok("\x[1E]" ~~ m/^<-lower>$/, q{Match inverted lower as charset});
+ ok("\x[1E]a" ~~ m/<+lower>/, q{Match unanchored lower as charset} );
+}
# print
-#?rakudo 14 skip '<.print>'
-ok("M" ~~ m/^<.print>$/, q{Match print as subrule});
-ok(!( "M" ~~ m/^<!print>.$/ ), q{Don't match negated print as subrule} );
-ok(!( "M" ~~ m/^<-print>$/ ), q{Don't match inverted print as subrule} );
-ok(!( "\x[7F]" ~~ m/^<.print>$/ ), q{Don't match unrelated print as subrule} );
-ok("\x[7F]" ~~ m/^<!print>.$/, q{Match unrelated negated print as subrule});
-ok("\x[7F]" ~~ m/^<-print>$/, q{Match unrelated inverted print as subrule});
-
-ok("M" ~~ m/^<+print>$/, q{Match print as charset} );
-ok("M" ~~ m/^<+[A]+print>$/, q{Match compound print as charset});
-ok(!( "M" ~~ m/^<-print>$/ ), q{Don't match externally inverted print as charset} );
-ok(!( "M" ~~ m/^<+[A]-print>$/ ), q{Don't match compound inverted print as charset} );
-ok(!( "M" ~~ m/^<-print>$/ ), q{Don't match internally inverted print as charset} );
-ok(!( "\x[7F]" ~~ m/^<+print>$/ ), q{Don't match unrelated print as charset} );
-ok("\x[7F]" ~~ m/^<-print>$/, q{Match inverted print as charset});
-ok("\x[7F]M" ~~ m/<+print>/, q{Match unanchored print as charset} );
+#?niecza skip 'Unable to resolve method lower in class Cursor'
+#?rakudo skip '<.print>'
+{
+ ok("M" ~~ m/^<.print>$/, q{Match print as subrule});
+ ok(!( "M" ~~ m/^<!print>.$/ ), q{Don't match negated print as subrule} );
+ ok(!( "M" ~~ m/^<-print>$/ ), q{Don't match inverted print as subrule} );
+ ok(!( "\x[7F]" ~~ m/^<.print>$/ ), q{Don't match unrelated print as subrule} );
+ ok("\x[7F]" ~~ m/^<!print>.$/, q{Match unrelated negated print as subrule});
+ ok("\x[7F]" ~~ m/^<-print>$/, q{Match unrelated inverted print as subrule});
+
+ ok("M" ~~ m/^<+print>$/, q{Match print as charset} );
+ ok("M" ~~ m/^<+[A]+print>$/, q{Match compound print as charset});
+ ok(!( "M" ~~ m/^<-print>$/ ), q{Don't match externally inverted print as charset} );
+ ok(!( "M" ~~ m/^<+[A]-print>$/ ), q{Don't match compound inverted print as charset} );
+ ok(!( "M" ~~ m/^<-print>$/ ), q{Don't match internally inverted print as charset} );
+ ok(!( "\x[7F]" ~~ m/^<+print>$/ ), q{Don't match unrelated print as charset} );
+ ok("\x[7F]" ~~ m/^<-print>$/, q{Match inverted print as charset});
+ ok("\x[7F]M" ~~ m/<+print>/, q{Match unanchored print as charset} );
+}
# punct
-ok("[" ~~ m/^<.punct>$/, q{Match punct as subrule});
-ok(!( "[" ~~ m/^<!punct>.$/ ), q{Don't match negated punct as subrule} );
-ok(!( "[" ~~ m/^<-punct>$/ ), q{Don't match inverted punct as subrule} );
-ok(!( "F" ~~ m/^<.punct>$/ ), q{Don't match unrelated punct as subrule} );
-ok("F" ~~ m/^<!punct>.$/, q{Match unrelated negated punct as subrule});
-ok("F" ~~ m/^<-punct>$/, q{Match unrelated inverted punct as subrule});
-
-ok("[" ~~ m/^<+punct>$/, q{Match punct as charset} );
-ok("[" ~~ m/^<+[A]+punct>$/, q{Match compound punct as charset});
-ok(!( "[" ~~ m/^<-punct>$/ ), q{Don't match externally inverted punct as charset} );
-ok(!( "[" ~~ m/^<+[A]-punct>$/ ), q{Don't match compound inverted punct as charset} );
-ok(!( "[" ~~ m/^<-punct>$/ ), q{Don't match internally inverted punct as charset} );
-ok(!( "F" ~~ m/^<+punct>$/ ), q{Don't match unrelated punct as charset} );
-ok("F" ~~ m/^<-punct>$/, q{Match inverted punct as charset});
-ok("F[" ~~ m/<+punct>/, q{Match unanchored punct as charset} );
+#?niecza skip 'Unable to resolve method punct in class Cursor'
+{
+ ok("[" ~~ m/^<.punct>$/, q{Match punct as subrule});
+ ok(!( "[" ~~ m/^<!punct>.$/ ), q{Don't match negated punct as subrule} );
+ ok(!( "[" ~~ m/^<-punct>$/ ), q{Don't match inverted punct as subrule} );
+ ok(!( "F" ~~ m/^<.punct>$/ ), q{Don't match unrelated punct as subrule} );
+ ok("F" ~~ m/^<!punct>.$/, q{Match unrelated negated punct as subrule});
+ ok("F" ~~ m/^<-punct>$/, q{Match unrelated inverted punct as subrule});
+
+ ok("[" ~~ m/^<+punct>$/, q{Match punct as charset} );
+ ok("[" ~~ m/^<+[A]+punct>$/, q{Match compound punct as charset});
+ ok(!( "[" ~~ m/^<-punct>$/ ), q{Don't match externally inverted punct as charset} );
+ ok(!( "[" ~~ m/^<+[A]-punct>$/ ), q{Don't match compound inverted punct as charset} );
+ ok(!( "[" ~~ m/^<-punct>$/ ), q{Don't match internally inverted punct as charset} );
+ ok(!( "F" ~~ m/^<+punct>$/ ), q{Don't match unrelated punct as charset} );
+ ok("F" ~~ m/^<-punct>$/, q{Match inverted punct as charset});
+ ok("F[" ~~ m/<+punct>/, q{Match unanchored punct as charset} );
+}
# upper
-ok("A" ~~ m/^<.upper>$/, q{Match upper as subrule});
-ok(!( "A" ~~ m/^<!upper>.$/ ), q{Don't match negated upper as subrule} );
-ok(!( "A" ~~ m/^<-upper>$/ ), q{Don't match inverted upper as subrule} );
-ok(!( "\x[5F]" ~~ m/^<.upper>$/ ), q{Don't match unrelated upper as subrule} );
-ok("\x[5F]" ~~ m/^<!upper>.$/, q{Match unrelated negated upper as subrule});
-ok("\x[5F]" ~~ m/^<-upper>$/, q{Match unrelated inverted upper as subrule});
-
-ok("A" ~~ m/^<+upper>$/, q{Match upper as charset} );
-ok("A" ~~ m/^<+[A]+upper>$/, q{Match compound upper as charset});
-
-ok(!( "A" ~~ m/^<-upper>$/ ), q{Don't match externally inverted upper as charset} );
-ok(!( "A" ~~ m/^<+[A]-upper>$/ ), q{Don't match compound inverted upper as charset} );
-ok(!( "A" ~~ m/^<-upper>$/ ), q{Don't match internally inverted upper as charset} );
-ok(!( "\x[5F]" ~~ m/^<+upper>$/ ), q{Don't match unrelated upper as charset} );
-ok("\x[5F]" ~~ m/^<-upper>$/, q{Match inverted upper as charset});
-ok("\x[5F]A" ~~ m/<+upper>/, q{Match unanchored upper as charset} );
+#?niecza skip 'Unable to resolve method upper in class Cursor'
+{
+ ok("A" ~~ m/^<.upper>$/, q{Match upper as subrule});
+ ok(!( "A" ~~ m/^<!upper>.$/ ), q{Don't match negated upper as subrule} );
+ ok(!( "A" ~~ m/^<-upper>$/ ), q{Don't match inverted upper as subrule} );
+ ok(!( "\x[5F]" ~~ m/^<.upper>$/ ), q{Don't match unrelated upper as subrule} );
+ ok("\x[5F]" ~~ m/^<!upper>.$/, q{Match unrelated negated upper as subrule});
+ ok("\x[5F]" ~~ m/^<-upper>$/, q{Match unrelated inverted upper as subrule});
+
+ ok("A" ~~ m/^<+upper>$/, q{Match upper as charset} );
+ ok("A" ~~ m/^<+[A]+upper>$/, q{Match compound upper as charset});
+
+ ok(!( "A" ~~ m/^<-upper>$/ ), q{Don't match externally inverted upper as charset} );
+ ok(!( "A" ~~ m/^<+[A]-upper>$/ ), q{Don't match compound inverted upper as charset} );
+ ok(!( "A" ~~ m/^<-upper>$/ ), q{Don't match internally inverted upper as charset} );
+ ok(!( "\x[5F]" ~~ m/^<+upper>$/ ), q{Don't match unrelated upper as charset} );
+ ok("\x[5F]" ~~ m/^<-upper>$/, q{Match inverted upper as charset});
+ ok("\x[5F]A" ~~ m/<+upper>/, q{Match unanchored upper as charset} );
+}
# word
# unspecced
@@ -271,21 +300,24 @@ ok("\x[5F]A" ~~ m/<+upper>/, q{Match unanchored upper as charset} );
# xdigit
-ok("0" ~~ m/^<.xdigit>$/, q{Match xdigit as subrule});
-ok(!( "0" ~~ m/^<!xdigit>.$/ ), q{Don't match negated xdigit as subrule} );
-ok(!( "0" ~~ m/^<-xdigit>$/ ), q{Don't match inverted xdigit as subrule} );
-ok(!( "}" ~~ m/^<.xdigit>$/ ), q{Don't match unrelated xdigit as subrule} );
-ok("}" ~~ m/^<!xdigit>.$/, q{Match unrelated negated xdigit as subrule});
-ok("}" ~~ m/^<-xdigit>$/, q{Match unrelated inverted xdigit as subrule});
-
-ok("0" ~~ m/^<+xdigit>$/, q{Match xdigit as charset} );
-ok("0" ~~ m/^<+[A]+xdigit>$/, q{Match compound xdigit as charset});
-ok(!( "0" ~~ m/^<-xdigit>$/ ), q{Don't match externally inverted xdigit as charset} );
-ok(!( "0" ~~ m/^<+[A]-xdigit>$/ ), q{Don't match compound inverted xdigit as charset} );
-ok(!( "0" ~~ m/^<-xdigit>$/ ), q{Don't match internally inverted xdigit as charset} );
-ok(!( "}" ~~ m/^<+xdigit>$/ ), q{Don't match unrelated xdigit as charset} );
-ok("}" ~~ m/^<-xdigit>$/, q{Match inverted xdigit as charset});
-ok("}0" ~~ m/<+xdigit>/, q{Match unanchored xdigit as charset} );
+#?niecza skip 'Unable to resolve method xdigit in class Cursor'
+{
+ ok("0" ~~ m/^<.xdigit>$/, q{Match xdigit as subrule});
+ ok(!( "0" ~~ m/^<!xdigit>.$/ ), q{Don't match negated xdigit as subrule} );
+ ok(!( "0" ~~ m/^<-xdigit>$/ ), q{Don't match inverted xdigit as subrule} );
+ ok(!( "}" ~~ m/^<.xdigit>$/ ), q{Don't match unrelated xdigit as subrule} );
+ ok("}" ~~ m/^<!xdigit>.$/, q{Match unrelated negated xdigit as subrule});
+ ok("}" ~~ m/^<-xdigit>$/, q{Match unrelated inverted xdigit as subrule});
+
+ ok("0" ~~ m/^<+xdigit>$/, q{Match xdigit as charset} );
+ ok("0" ~~ m/^<+[A]+xdigit>$/, q{Match compound xdigit as charset});
+ ok(!( "0" ~~ m/^<-xdigit>$/ ), q{Don't match externally inverted xdigit as charset} );
+ ok(!( "0" ~~ m/^<+[A]-xdigit>$/ ), q{Don't match compound inverted xdigit as charset} );
+ ok(!( "0" ~~ m/^<-xdigit>$/ ), q{Don't match internally inverted xdigit as charset} );
+ ok(!( "}" ~~ m/^<+xdigit>$/ ), q{Don't match unrelated xdigit as charset} );
+ ok("}" ~~ m/^<-xdigit>$/, q{Match inverted xdigit as charset});
+ ok("}0" ~~ m/<+xdigit>/, q{Match unanchored xdigit as charset} );
+}
# L<S05/Predefined Subrules/always returns false>
6 S05-match/blocks.t
View
@@ -20,6 +20,7 @@ if 1 {
}
#?rakudo todo 'nom regression'
+#?niecza skip 'TODO'
ok !defined($/), '$/ still undefined in the outer block';
my $loop = 1;
@@ -30,6 +31,7 @@ while $loop {
$loop = 0;
}
#?rakudo todo 'nom regression'
+#?niecza skip 'TODO'
ok !defined($/), '$/ still undefined in the outer block';
{
@@ -37,6 +39,7 @@ ok !defined($/), '$/ still undefined in the outer block';
is ~$/, 'c', '... and can use the match var';
}
#?rakudo todo 'nom regression'
+#?niecza skip 'TODO'
ok !defined($/), '$/ still undefined in the outer block';
my $discarded = do {
@@ -45,6 +48,7 @@ my $discarded = do {
}
#?rakudo todo 'nom regression'
+#?niecza skip 'TODO'
ok !defined($/), '$/ still undefined in the outer block';
{
@@ -59,6 +63,7 @@ ok !defined($/), '$/ still undefined in the outer block';
ok $count, 'Can match in the condition of a while loop';
is $match, 'b', '... and can use $/ in the block';
#?rakudo todo 'Assignment to matched string affects earlier match objects'
+ #?niecza skip 'TODO'
is "$/", 'b', '... and can use $/ outside the block';
}
@@ -80,6 +85,7 @@ ok !defined($/), '$/ still undefined in the outer block';
flunk 'regex did not match - $/ is properly set with explicit $_ in a given { } block';
}
if /\w+/ {
+ #?niecza skip 'TODO'
is $/, 'Wall', '$/ is properly set in a given { } block';
} else {
flunk 'regex did not match - $/ is properly set in a given { } block';
2  S05-match/non-capturing.t
View
@@ -18,11 +18,13 @@ my $str = "abbbbbbbbc";
ok($str ~~ m{a(b+)c}, 'Matched 1');
ok($/, 'Saved 1');
is($/, $str, 'Grabbed all 1');
+#?niecza skip 'TODO'
is($/[0], substr($str,1,-1), 'Correctly captured 1');
ok($str ~~ m{a[b+]c}, 'Matched 2');
ok($/, 'Saved 2');
is($/, $str, 'Grabbed all 2');
+#?niecza skip 'TODO'
ok(!defined($/[0]), "Correctly didn't capture 2");
{
4 S05-match/positions.t
View
@@ -24,12 +24,16 @@ ok($/.from == 3, 'Match.from is 3');
ok($str !~~ m/ Z .+ a /, 'No match');
#?rakudo skip 'unspecced'
+#?niecza skip 'System.InvalidCastException: Cannot cast from source type to destination type.'
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');
+#?niecza skip 'Unable to resolve method from in class Any'
ok($/<Aa>.from == 3, 'Subrule match pos is 3');
3  S05-metachars/closure.t
View
@@ -24,6 +24,7 @@ plan 12;
}
#?rakudo skip 'assignment to match variables (dubious)'
+#?niecza skip 'assigning to readonly value'
{
ok("abc" ~~ m/a(bc){$<caught> = $0}/, 'Inner match');
is(~$/<caught>, "bc", 'Inner caught');
@@ -35,6 +36,7 @@ ok("abc" ~~ m/a(bc){$caught = $0}/, 'Outer match');
is($caught, "bc", 'Outer caught');
#?rakudo skip 'assignment to match variables (dubious)'
+#?niecza skip 'assigning to readonly value'
{
ok("abc" ~~ m/a(bc){$0 = uc $0}/, 'Numeric match');
is($/, "abc", 'Numeric matched');
@@ -44,6 +46,7 @@ is($caught, "bc", 'Outer caught');
#?rakudo skip 'make() inside closure'
{
ok("abc" ~~ m/a(bc){make uc $0}/ , 'Zero match');
+ #?niecza skip 'TODO'
is($($/), "BC", 'Zero matched');
is(~$0, "bc", 'One matched');
}
7 S05-metachars/newline.t
View
@@ -17,8 +17,11 @@ ok("\n" ~~ m/\n/, '\n');
ok("\o15\o12" ~~ m/\n/, 'CR/LF');
ok("\o12" ~~ m/\n/, 'LF');
ok("a\o12" ~~ m/\n/, 'aLF');
+#?niecza skip 'TODO'
ok("\o15" ~~ m/\n/, 'CR');
+#?niecza skip 'TODO'
ok("\x85" ~~ m/\n/, 'NEL');
+#?niecza skip 'TODO'
#?rakudo todo 'Unicode'
ok("\x2028" ~~ m/\n/, 'LINE SEP');
@@ -27,10 +30,14 @@ ok(!( "abc" ~~ m/\n/ ), 'not abc');
ok(!( "\n" ~~ m/\N/ ), 'not \n');
ok(!( "\o12" ~~ m/\N/ ), 'not LF');
+#?niecza skip 'TODO'
ok(!( "\o15\o12" ~~ m/\N/ ), 'not CR/LF');
+#?niecza skip 'TODO'
ok(!( "\o15" ~~ m/\N/ ), 'not CR');
+#?niecza skip 'TODO'
ok(!( "\x85" ~~ m/\N/ ), 'not NEL');
#?rakudo todo 'Unicode'
+#?niecza skip 'TODO'
ok(!( "\x2028" ~~ m/\N/ ), 'not LINE SEP');
ok("abc" ~~ m/\N/, 'abc');
10 S05-metachars/tilde.t
View
@@ -16,6 +16,7 @@ ok '(a)d' !~~ m/<&t1>/, '~ and constant atoms (wrong content)';
# this shouldn't throw an exception. See here:
# http://irclog.perlgeek.de/perl6/2009-01-08#i_816425
#?rakudo skip 'should not throw exceptions'
+#?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
ok 'x(ab' !~~ m/<&t1>/, '~ and constant atoms (missing closing bracket)';
{
@@ -29,9 +30,13 @@ ok 'x(ab' !~~ m/<&t1>/, '~ and constant atoms (missing closing bracket)';
ok '(a(a))' ~~ m/^ <&recursive> $/, 'recursive "(a(a))"';
ok '(()())' ~~ m/^ <&recursive> $/, 'recursive "(()())"';
#?rakudo 4 skip 'should not throw exceptions'
+ #?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 '(()' !~~ 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';
}
@@ -45,13 +50,17 @@ ok 'x(ab' !~~ m/<&t1>/, '~ and constant atoms (missing closing bracket)';
ok '(a(a))' ~~ m/^ <&m1> $/, 'mutually recursive "(a(a))"';
ok '(()())' ~~ m/^ <&m1> $/, 'mutually recursive "(()())"';
#?rakudo 3 skip 'exceptions from regexes'
+ #?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
ok '(' !~~ m/^ <&m1> $/, '"(" is not matched';
+ #?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
ok '(()' !~~ m/^ <&m1> $/, '"(()" is not matched';
+ #?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
ok '())' !~~ m/^ <&m1> $/, '"())" is not matched';
ok 'a()' !~~ m/^ <&m1> $/, '"a()" is not matched';
}
#?rakudo skip 'backtracking into ~'
+#?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
{
my regex even_a { ['a' ~ 'a' <&even_a> ]? };
ok 'aaaa' ~~ m/^ <&even_a> $ /, 'backtracking into tilde rule (1)';
@@ -59,6 +68,7 @@ ok 'x(ab' !~~ m/<&t1>/, '~ and constant atoms (missing closing bracket)';
}
#?rakudo skip 'backtracking to find ~ goal'
+#?niecza skip 'Unable to resolve method FAILGOAL in class Cursor'
{
my regex even_b { 'a' ~ 'a' <&even_b>? };
ok 'aaaa' ~~ m/^ <&even_b> /, 'tilde regex backtracks to find its goal';
2  S05-metasyntax/charset.t
View
@@ -57,6 +57,7 @@ ok( "foo" ~~ /<[f] #`[comment] + [o]>/, 'comment embedded in charset works' );
ok "\x[10001]" ~~ /<[\x10000..\xEFFFF]>/, 'large \\x char spec';
#?rakudo skip 'RT 71702: lethal reverse range in charset'
+#?niecza skip 'TODO'
eval_dies_ok( "'RT 71702' ~~ /<[d..b]>? RT/",
'reverse range in charset is lethal (RT 71702)' );
@@ -65,6 +66,7 @@ ok 'b' ~~ /<[. .. b]>/, 'weird char class matches at least its end point';
# RT #69682
#?rakudo skip 'nom regression'
+#?niecza skip 'Unsupported use of - as character range; in Perl 6 please use ..'
{
eval "/<[a-z]>/";
ok ~$! ~~ / 'Unsupported use of - as character range; in Perl 6 please use ..'/,
15 S05-metasyntax/litvar.t
View
@@ -33,16 +33,25 @@ ok("zzzzzz{$var}zzzzzz" ~~ m/$var/, 'Nested scalar interpolation');
ok(!( "aaaaab" ~~ m/$var/ ), 'Rulish scalar interpolation');
#?pugs 6 todo 'feature'
+#?niecza skip 'TODO'
ok('a' ~~ m/$aref[0]/, 'Array ref 0');
+#?niecza skip 'TODO'
ok('a' ~~ m/$aref.[0]/, 'Array ref dot 0');
+#?niecza skip 'TODO'
ok('a' ~~ m/@var[0]/, 'Array 0');
+#?niecza skip 'TODO'
ok('1' ~~ m/$href.{'a'}/, 'Hash ref dot A');
+#?niecza skip 'TODO'
ok('1' ~~ m/$href{'a'}/, 'Hash ref A');
+#?niecza skip 'TODO'
ok('1' ~~ m/%var{'a'}/, 'Hash A');
+#?niecza skip 'TODO'
ok('1' ~~ m/$href.<a>/, 'Hash ref dot A');
+#?niecza skip 'TODO'
ok('1' ~~ m/$href<a>/, 'Hash ref A');
+#?niecza skip 'TODO'
ok('1' ~~ m/%var<a>/, 'Hash A');
ok(!( 'a' ~~ m/$aref[1]/ ), 'Array ref 1');
@@ -59,6 +68,7 @@ ok(!( '1' ~~ m/%var<b>/ ), 'Hash B');
# However, if $var contains a Regex object, instead of attempting to convert it to a string, it is called as a subrule
# A simple test for this
my $rx = rx/foo/;
+#?niecza skip 'TODO'
ok('foobar' ~~ /$rx bar/, 'regex object in a regex');
ok('quxbaz' !~~ /$rx baz/, 'nonmatching regex object in a regex');
@@ -67,13 +77,18 @@ ok('quxbaz' !~~ /$rx baz/, 'nonmatching regex object in a regex');
# L<S05/Variable (non-)interpolation/An interpolated array:>
#?pugs 3 todo 'feature'
+#?niecza skip 'TODO'
ok("a" ~~ m/@var/, 'Simple array interpolation (a)');
+#?niecza skip 'TODO'
ok("b" ~~ m/@var/, 'Simple array interpolation (b)');
+#?niecza skip 'TODO'
ok("c" ~~ m/@var/, 'Simple array interpolation (c)');
ok(!( "d" ~~ m/@var/ ), 'Simple array interpolation (d)');
#?pugs 2 todo 'feature'
+#?niecza skip 'TODO'
ok("ddddaddddd" ~~ m/@var/, 'Nested array interpolation (a)');
+#?niecza skip 'TODO'
ok("abca" ~~ m/^@var+$/, 'Multiple array matching');
ok(!( "abcad" ~~ m/^@var+$/ ), 'Multiple array non-matching');
1  S05-metasyntax/sequential-alternation.t
View
@@ -22,6 +22,7 @@ plan 10;
#L<S05/"Variable (non-)interpolation"/"An interpolated array:">
#?rakudo todo 'sequential alternation NYI'
+#?niecza skip 'TODO'
{
my $str = 'x' x 7;
my @list = <x xx xxxx>;
2  S05-metasyntax/unknown.t
View
@@ -18,6 +18,7 @@ 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 (+)';
@@ -25,6 +26,7 @@ lives_ok({"aa!" ~~ /'a'/}, 'quoted "a" is valid');
}
# RT #74832
+#?niecza skip 'Quantifier quantifies nothing'
{
nok eval('/ a+ + /'), 'Cannot parse regex a+ +';
#?rakudo todo 'RT 74832'
3  S05-modifier/counted-match.t
View
@@ -51,6 +51,7 @@ my $data = "f fo foo fooo foooo fooooo foooooo";
# more interesting variations of :nth(...)
#?rakudo todo 'nom regression'
+#?niecza skip 'TODO - but one hangs'
{
my @match = $data.match(/fo+/, :nth(2, 3)).list;
is +@match, 2, 'nth(list) is ok';
@@ -65,6 +66,7 @@ my $data = "f fo foo fooo foooo fooooo foooooo";
is @match, <foo foooo foooooo>, 'nth(infinite series) matched correctly';
}
+#?niecza skip 'Excess arguments to CORE Cool.match'
{
#?rakudo todo 'nom regression'
is 'abecidofug'.match(/<[aeiou]>./, :nth(1,3,5), :x(2)).join('|'),
@@ -83,6 +85,7 @@ my $data = "f fo foo fooo foooo fooooo foooooo";
# test that non-monotonic items in :nth lists are ignored
#?rakudo todo 'nom regression'
+#?niecza skip 'TODO'
{
is 'abacadaeaf'.match(/a./, :nth(2, 1, 4)).join(', '),
'ac, ae', 'non-monotonic items in :nth are ignored';
3  S05-modifier/ignorecase.t
View
@@ -37,12 +37,15 @@ ok "hello" !~~ m:i/<&mixedcase>/, "no match with :i if matched by subrule";
ok "hello" ~~ m:i/Hello/, "match with :i (direct)";
ok "hello" !~~ m:ignorecase/<&mixedcase>/, "no match with :ignorecase + subrule";
+#?niecza skip 'TODO'
ok "hello" !~~ m:ignorecase/Hello/, "match with :ignorecase (direct)";
ok('Δ' ~~ m:i/δ/, ':i with greek chars');
# The German ß (&szlig;) maps to uppercase SS:
#?rakudo 2 todo 'ignorecase and SS/&szlig;'
+#?niecza skip 'TODO'
ok('ß' ~~ m:i/SS/, "ß matches SS with :ignorecase");
+#?niecza skip 'TODO'
ok('SS' ~~ m:i/ß/, "SS matches ß with :ignorecase");
2  S05-substitution/match.t
View
@@ -12,6 +12,8 @@ ok $str.match(/h/), 'We can use match';
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/$_/");
2  S06-currying/assuming-and-mmd.t
View
@@ -14,7 +14,9 @@ is &testsub("a_str", 42), "Str", "basic MMD works with subrefs (1)";
is &testsub(23, 42), "Int", "basic MMD works with subrefs (2)";
#?pugs todo 'bug'
+#?niecza skip 'Unable to resolve method assuming in class Code'
is &testsub.assuming("a_str")(42), "Str", "basic MMD works with assuming (1)";
+#?niecza skip 'Unable to resolve method assuming in class Code'
is &testsub.assuming(23)\ .(42), "Int", "basic MMD works with assuming (2)";
# vim: ft=perl6
7 S06-multi/by-trait.t
View
@@ -7,13 +7,18 @@ use Test;
my $rw_call = 0;
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 skip 'TODO'
is $ro_call, 1, 'read-only multi was called';
my $x = 99;
+ #?niecza skip 'Ambiguous dispatch for &uno_mas'
is uno_mas( $x ), 100, 'multi works with variable';
+ #?niecza skip 'TODO'
is $x, 100, 'variable was modified';
+ #?niecza skip 'TODO'
is $rw_call, 1, 'read-write multi was called';
}
4 S06-other/anon-hashes-vs-blocks.t
View
@@ -41,9 +41,13 @@ ok $bar ~~ Hash, '%foo in a block causes hash composing';
{
ok {; a => 1 } ~~ Block, '{; ... } is a Block';
ok { a => 1 } ~~ Hash, '{ a => 1} is a Hash';
+ #?niecza skip 'No value in ANON available for parameter $a'
ok { $^a => $^b } ~~ Block, 'placeholders force it to be a block';
+ #?niecza skip 'No value in ANON available for parameter $a'
ok { $^a => 'b' } ~~ Block, '... as a key';
+ #?niecza skip 'No value in ANON available for parameter $x'
ok { a => $^x } ~~ Block, '... as a value';
+ #?niecza skip 'No value in ANON available for parameter $x'
ok { b => 3, a => $^x, 4 => 5 } ~~ Block, '... somewhere deep inside';
ok {;} ~~ Block, '{;} is a Block';
}
2  S06-routine-modifiers/scoped-named-subs.t
View
@@ -44,9 +44,11 @@ eval_dies_ok
'Return of list with wrong type dies';
#?rakudo 2 todo 'RT 65128'
+#?niecza skip 'TODO'
eval_lives_ok
'my Num List sub f () { return () }; f()',
'return of empty list should live';
+#?niecza skip 'Multiple prefix constraints not yet supported'
is eval('my Num List sub f () { return () }; (f(), "a")'), ['a'],
'return of empty list should be empty list';
7 S06-signature/caller-param.t
View
@@ -9,15 +9,20 @@ sub callerunderscore ($foo = $CALLER::_) {
is(callerunderscore("foo"), "-foo-", 'CALLER:: string arg');
is(callerunderscore(1), "-1-", 'CALLER:: number arg');
$_ = "foo";
+#?niecza skip 'System.Exception: Improper null return from sub default for $foo = $CALLER::_ in MAIN callerunderscore'
is(callerunderscore(), "-foo-", 'CALLER:: $_ set once');
$_ = "bar";
+#?niecza skip 'System.Exception: Improper null return from sub default for $foo = $CALLER::_ in MAIN callerunderscore'
is(callerunderscore(), "-bar-", 'CALLER:: $_ set twice');
for ("quux") {
- is(callerunderscore(), '-quux-', 'CALLER:: $_ set by for');
+ #?niecza skip 'System.Exception: Improper null return from sub default for $foo = $CALLER::_ in MAIN callerunderscore'
+ is(callerunderscore(), '-quux-', 'CALLER:: $_ set by for');
}
given 'hirgel' {
+ #?niecza skip 'System.Exception: Improper null return from sub default for $foo = $CALLER::_ in MAIN callerunderscore'
is callerunderscore, '-hirgel-', '$CALLER::_ set by given';
}
+#?niecza skip 'System.Exception: Improper null return from sub default for $foo = $CALLER::_ in MAIN callerunderscore'
is(callerunderscore(), '-bar-', 'CALLER:: $_ reset after for');
4 S06-signature/code.t
View
@@ -22,15 +22,18 @@ tester(sub ($x) { $collector = 3 * $x });
ok $collector == 12, 'same with anonymous sub';
sub tester2(&my_sub) { 1 } #OK not used
+#?niecza skip 'TODO'
dies_ok {tester2(42)}, "can't pass thing that doesn't do Callable";
sub not_returns_a_sub { 3 };
+#?niecza skip 'TODO'
dies_ok {tester2(not_returns_a_sub)},
"can't pass thing that doesn't do Callable";
is tester2({ 'block' }), 1, 'Can pass a block to a &parameter';
# RT #68578
+#?niecza skip 'TODO'
{
sub rt68578( Callable &x ) {} #OK not used
dies_ok { rt68578({ 'block' }) },
@@ -43,6 +46,7 @@ is tester2({ 'block' }), 1, 'Can pass a block to a &parameter';
sub foo(&foo = &foo) {
$tracker = &foo
};
+ #?niecza skip 'TODO'
lives_ok { foo },
'can call a sub with a code object defaulting to something of its own name';
ok !$tracker.defined, 'the inner &foo is undefined (scoping)';
1  S06-signature/errors.t
View
@@ -25,6 +25,7 @@ eval_lives_ok 'sub quuuux ($!) { ... }', 'but $! is OK';
}
# RT #71478
+#?niecza skip 'Excess arguments to MAIN_3 foo, used 1 of 2 positionals'
{
my $success = eval 'sub foo(%h) { %h }; foo(1, 2); 1';
my $error = "$!";
4 S06-signature/scalar-type.t
View
@@ -19,12 +19,16 @@ plan 8;
is( foo(make_array()), ::Array, "2-elem array arg, sub-returned, invoked inline" );
+ #?niecza skip 'System.InvalidCastException: Cannot cast from source type to destination type.'
is( foo(hash()), ::Hash, "anon-def empty hash arg defined inline" );
+ #?niecza skip 'System.InvalidCastException: Cannot cast from source type to destination type.'
is( foo({'a'=>'b'}), ::Hash, "anon-def 1-elem hash arg defined inline" );
+ #?niecza skip 'System.InvalidCastException: Cannot cast from source type to destination type.'
is( foo({'a'=>'b','c'=>'d'}), ::Hash, "anon-def 2-elem hash arg defined inline" );
+ #?niecza skip 'System.InvalidCastException: Cannot cast from source type to destination type.'
is( foo(make_hash()), ::Hash, "2-elem hash arg, sub-returned, invoked inline" );
}
Please sign in to comment.
Something went wrong with that request. Please try again.