3 ms·
Interpolation is its own can of worms, but if you just want to be able to encode absolutely anything without escape characters, you just need two delimiters:
by DalekBaldwin 5y ago
Interpolation is its own can of worms, but if you just want to be able to encode absolutely anything without escape characters, you just need two delimiters:
"*n [stringA] "*n
"*n [stringB] '*n
'*n [stringC] "*n
'*n [stringD] '*n
Each string may contain runs of contiguous single or double quotes of length less than n, and furthermore:
stringA may start and/or end with a single quote
stringB may start with a single quote and/or end with a double quote
stringC may start with a double quote and/or end with a single quote
stringD may start and/or end with a double quote