First off, %z was deprecated in Lua 5.2 (see section 8.2), and it's not
mentioned at all in the Lua 5.3 manual (although my version of Lua 5.3
does run the above code).
Here is some code that works (and maybe even Soni
would like it, as it's not limited to '"' as the quote character---it can be
any string, and said string can appear escaped!):