I read it as doublequote which is not preceded by backslash
But what about an escaped backslash \\" or two \\\\" ... ?
I'd rather try something like (Untested pseudocode)
$escaped = qr/\\./; $quoted = qr/ (['"]) # start (?: $escaped | [^\1] )* # inside \1 # end, probably \g-1 better /x;
NB: I didn't cover the case of unclosed quotes, which is unclear anyway.
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery
tested - fails - good night! :)
see Re: solution wanted for break-on-spaces (w/specifics) for "working" example