Skip to content
This repository has been archived by the owner on Feb 3, 2021. It is now read-only.

Commit

Permalink
Add quoted literals to regexes.
Browse files Browse the repository at this point in the history
  • Loading branch information
pmichaud committed Oct 15, 2009
1 parent e04a163 commit 41bdc6b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Regex/P6Regex/Actions.pm
Expand Up @@ -128,6 +128,11 @@ method metachar:sym<( )>($/) {
make $past;
}

method metachar:sym<'>($/) {
my $past := PAST::Regex.new( ~$<quote><val>, :pasttype('literal') );
make $past;
}

method metachar:sym<.>($/) {
my $past := PAST::Regex.new( :pasttype('charclass'), :subtype('.') );
make $past;
Expand Down

0 comments on commit 41bdc6b

Please sign in to comment.