Grammar ABNF - Parse ABNF grammars and create Perl 6 Grammars from them

NAME

Grammar ABNF - Parse ABNF grammars and create Perl 6 Grammars from them

SYNOPSIS


    use Grammar::ABNF;

    my $g = Grammar::ABNF.parse(qq:to<END>, :name<MyGrammar>).made;
    macaddr  = 5( octet [ ":" / "-" ] ) octet\r
    octet    = 2HEXDIGIT\r
    HEXDIGIT = %x30-39 / %x41-46 / %x61-66\r
    END

    $g.parse('02-BF-C0-00-02-01')<macaddr><octet>».Str.print; # 02BFC0000201

AUTHOR

Brian S. Julin

COPYRIGHT

Copyright (c) 2015 Brian S. Julin. All rights reserved.

LICENSE

This program is free software; you can redistribute it and/or modify it under the terms of either the MIT license (as other files in this distribution may be) or the Perl Artistic License 2.0.

REFERENCES

SEE-ALSO

perl6::(1)

The Camelia image is copyright 2009 by Larry Wall. "Raku" is trademark of the Yet Another Society. All rights reserved.