
James Harper <james.harper@bendigoit.com.au> wrote:
The problem is that my sed script says to start at the "(" and then read up until a ")", but I really mean to say read up until a matching ")". Can I do this with sed or should I be using something else?
If you can be sure it's the last quote on the line that you want to match, you could match, say, "[^"]*$ I understand that there are fundamental reasons related to finite-state automata that explain why a regular expression can't find matching quotation marks, parentheses, opening and closing XML tags, etc. Unfortunately I don't have access to a book on the subject, and I'm not a computer science graduate (computer science graduates are supposed to have learned this material - if not, then there's something amiss in the computer science course). I would still like to learn it though.