Changing it without reason is unnecessarily obfuscating.
Far from obfuscating regexps, alternate delimiters to '/' can help to clarify. From perldoc perlre:
Modifiers are usually written as "the /x modifier", even though the delimiter in question might not really be a slash.
. . .You can use The /x modifier to break up your regular expression into (slightly) more readable parts.
. . .
Taken together, these features go a long way towards making Perl's regular expressions more readable.
From the Perl Cookbook (1st ed.) Recipe 6.4 Commenting Regular Expressions:
For aesthetics, the example uses alternate delimiters. When you split your match or substition over multiple lines, it helps readability to have matching braces. Another common reason to use alternate delimiters is when your pattern or replacement contains slashes, as in s/\/\//\/..\//g, alternate delimiters makes such patterns easier to read as in s!//!/../!g or s{//}{/../}g
Slashes may be what most of us are used to seeing in single-line regexps, but alternate delimiters have their place too.
In reply to Re^3: What does this mean?
by Cuhulain
in thread What does this mean?
by biginingperl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |