my $path =~ /^\Q$string\E # the base string; '\tmp\foo', e.g.
(\\.*)? # optionally match a slash, etc.
$ # match end of string
/x;
In reply to Re x 2: regexp question
by Sweeper
in thread regexp question
by hotshot
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |