Beefy Boxes and Bandwidth Generously Provided by pair Networks
RobOMonk The stupid question is the question not asked  Re^5:
Best practice or cargo cult?  by demerphq (Chancellor) on Jun
22, 2006 at 07:44 UTC ( #556854=note: print w/ replies, xml )
Need Help??  in reply to Re^4: Best practice or cargo cult? in
thread Best practice or cargo cult?  Well there are two reasons
why I wouldnt do it this way. The first is that doing this
afaict adds a high cost to compiling regexes in the scope where
the overload takes effect. The second is that special
metasequences like we are discussing can be handled much more
efficiently by the regex engine. So for instance a NEOL regop
would be a lot more efficient both in terms of storage and
execution than the ANYOF regop that [^\n] is converted to.  The
ANYOF is implemented by a bitmap lookup with flags, meaning it
requires more than 32 bytes to represent, and for each character
inspected requires a set of bit shifting to do the correct
bitmap test. Wheras an NEOL regop wou