Syntactic Confectionery Delight | |
PerlMonks |
Re^3: Regex - one and only one / at beginning and end of file pathby Aristotle (Chancellor) |
on Dec 15, 2003 at 08:14 UTC ( [id://314782]=note: print w/replies, xml ) | Need Help?? |
What concern does that snippet address? I don't see how it has anything to do with anything posted anywhere on this thread? As for performance, despite appearances, you're actually going to have a hard time beating the regex engine. With substr, you usually have to do a (relative) lot of explicit work in Perl code, which means many more ops to interpret; with regexen, most of the infrastructure is implicit in the guts of Perl, which execute much faster. Makeshifts last the longest.
In Section
Seekers of Perl Wisdom
|
|