3 ms·
If you still have access to the original source in the filesystem you could just re-read the snippet and recover the original escaped form. If your language off
by ithkuil 3y ago
If you still have access to the original source in the filesystem you could just re-read the snippet and recover the original escaped form. If your language offers only a single way to escape characters then you may even just re-escape the string when emitting the error (although most languages have some sort of codepoint escape sequence)