consider following string:
blah, foo(a,b), bar(c,d), yo i want extract list of strings:
blah foo(a,b) bar(c,d) yo it seems me should able use quote words here, i'm struggling regex. can me out?
perl has little thing regex recursion, might able for:
either bare word
blahcontaining no parentheses (\w+)a "call",
\w+\((?r)(, *(?r))*\)
the total regex (\w+(\((?r)(, ?(?r))*\))?), seems work.
Comments
Post a Comment