Keep It Simple, Stupid | |
PerlMonks |
Re^2: Regex to strip, keep, or add—dependingby JediWizard (Deacon) |
on Aug 06, 2005 at 16:46 UTC ( [id://481517]=note: print w/replies, xml ) | Need Help?? |
FYI... The example I gave will not have issues with nested parens. * (being greedy) would match the last paren followed by a semi-colon (thus nested parens would not be an issue (unless there were nested parens with in the nested function call)). Further proving my point that the perl parser will handle more than you would ever want to try with a regex. Update: I am wrong. The regex I posted will actually match the first ) followed by a ;... which will break in a nested function call. However nested parens aside... my original point, that you (porbably) do not want to attempt to account for everything the perl parser will account for, remains valid. They say that time changes things, but you actually have to change them yourself. Andy Warhol
In Section
Seekers of Perl Wisdom
|
|