Skip to content

Commit ea16117

Browse files
committed
Deindent while revising #1759
1 parent f28d194 commit ea16117

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

doc/Language/grammars.pod6

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -512,21 +512,21 @@ argument. If no such method exists, it is skipped.
512512
513513
Here is a contrived example of a grammar and actions in action:
514514
515-
=begin code
516-
grammar TestGrammar {
517-
token TOP { \d+ }
518-
}
515+
=begin code
516+
grammar TestGrammar {
517+
token TOP { \d+ }
518+
}
519519
520-
class TestActions {
521-
method TOP($/) {
522-
$/.make(2 + $/);
523-
}
520+
class TestActions {
521+
method TOP($/) {
522+
$/.make(2 + $/);
524523
}
524+
}
525525
526-
my $match = TestGrammar.parse('40', actions => TestActions.new);
527-
say $match; # OUTPUT: «「40」␤»
528-
say $match.made; # OUTPUT: «42␤»
529-
=end code
526+
my $match = TestGrammar.parse('40', actions => TestActions.new);
527+
say $match; # OUTPUT: «「40」␤»
528+
say $match.made; # OUTPUT: «42␤»
529+
=end code
530530
531531
An instance of C<TestActions> is passed as named argument C<actions> to the
532532
L<parse|/routine/parse> call, and when token C<TOP> has matched successfully,
@@ -586,11 +586,11 @@ A slightly more involved example follows:
586586
587587
This produces the following output:
588588
589-
=begin code :lang<text>
590-
Key: second Value: b
591-
Key: hits Value: 42
592-
Key: perl Value: 6
593-
=end code
589+
=begin code :lang<text>
590+
Key: second Value: b
591+
Key: hits Value: 42
592+
Key: perl Value: 6
593+
=end code
594594
595595
Rule C<pair>, which parsed a pair separated by an equals sign, aliases the two
596596
calls to token C<identifier> to separate capture names to make them available

0 commit comments

Comments
 (0)