in reply to Re^2: sort an array
in thread sort an array

the # needed to be escaped

I don't believe you. Pound signs never need to be escaped in regexes, and it shouldn't make any difference if they are or not. I invite you to show us your exact code — the one that behaves differently depending on whether the pound sign is escaped or not.

We're building the house of the future together.

Replies are listed 'Best First'.
Re^4: sort an array
by tilly (Archbishop) on Mar 20, 2006 at 02:47 UTC
    Sorry, but you're wrong.
    $_ = "SomecomplexREhereandthenafoobar"; if (/Some complex RE here and then a # to ignore/x) { print "Escaping that # would have mattered\n"; }

      Yeah, o.k., /x. I lose. ;-) But I wonder - was the OP using /x?

        It's probably becoming more prevalent as TheDamian recommends using xms for regex's in Perl Best Practices.