# New Ticket Created by  Tim Nelson 
# Please include the string:  [perl #68154]
# in the subject line of all future correspondence about this issue. 
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=68154 >



---------------------------------------------------------------------
| Name: Tim Nelson                 | Because the Creator is,        |
| E-mail: wayl...@wayland.id.au    | I am                           |
---------------------------------------------------------------------

----BEGIN GEEK CODE BLOCK----
Version 3.12
GCS d+++ s+: a- C++$ U+++$ P+++$ L+++ E- W+ N+ w--- V- 
PE(+) Y+>++ PGP->+++ R(+) !tv b++ DI++++ D G+ e++>++++ h! y-
-----END GEEK CODE BLOCK-----
#!/usr/bin/perl6

grammar XKB::Grammar {
        rule TOP                { <ident> {*} };
}

class   TestActions {
        has $currkey;

        multi method TOP($match) {
                say $match.perl;
                printf("%s\n", $match<ident>);
                $currkey = $match<ident>;
        }

}

my $text = 'TLDE';

my $M := XKB::Grammar.parse($text, :action(TestActions));

Reply via email to