The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Perl6RE - Sample Perl6 grammar for regular expressions

SYNOPSIS

  use Perl6RE;
  use Data::Dumper;
  use Parse::RecDescent;
  $p = Parse::RecDescent->new($Perl6RE::grammar);
  print Dumper($p->rx('rx/ ^ <$digit>+ $$ /'));

DESCRIPTION

Simply loads the Perl6 RE grammar suitable for Parse::RecDescent. Contains no actual parsing code beyond returning a nested array of arrays consisting of a pseudo-rational grammar for Perl6 REs

EXPORT

None by default.

AUTHOR

Jeff Goff, <jgoff@perl.org>

SEE ALSO

perl, parrot