$regexp = "m?" . <STDIN> . "?";
Also be aware that m?pattern? or ?pattern? is a special case of the match operator:
m?PATTERN?msixpodualgcSee m?...? in Regexp Quote-Like Operators in perlop.
?PATTERN?msixpodualgc
This is just like the "m/PATTERN/" search, except that it
matches only once between calls to the reset() operator. ...
Update: See also qr// in the above section of perlop for more info on interpolating strings into regexes. And see also perlre, perlretut, and perlrequick.
Give a man a fish: <%-{-{-{-<
In reply to Re: Regex variables with delimiters
by AnomalousMonk
in thread Regex variables with delimiters
by clerew
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |