We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ffe2c59 commit 74bedacCopy full SHA for 74bedac
S05-grammar/inheritance.t
@@ -1,7 +1,7 @@
1
use v6;
2
use Test;
3
4
-plan 31;
+plan 32;
5
6
# L<S05/Grammars/"Like classes, grammars can inherit">
7
@@ -10,8 +10,13 @@ plan 31;
10
grammar Grammar::Foo {
11
token TOP { <foo> };
12
token foo { 'foo' };
13
+ token so { 'so' };
14
};
15
16
+#?rakudo todo 'RT #77350'
17
+is( try { Grammar::Foo.parse( 'so', :rule<so> ) }, 'so',
18
+ "don't let a Mu based action method fail the parse" );
19
+
20
#?niecza skip 'Cannot dispatch to a method on Foo because it is not inherited or done by Cursor'
21
is(~('foo' ~~ /^<Grammar::Foo::foo>$/), 'foo', 'got right match (foo)');
22
ok Grammar::Foo.parse('foo'), 'got the right match through .parse TOP';
0 commit comments