On Thu, 4 Jul 2019, Ben Grasset wrote:

On Thu, Jul 4, 2019 at 12:29 PM Michael Van Canneyt <mich...@freepascal.org>
wrote:

I would think this is a given...
After all, they are valid characters in a single line string now, that
must be kept
for backward compatibility.


One more question in this general regard... what would be the most
desirable way for the compiler to handle the appearance of a single
apostrophe inside a multi-line string?

for reasons of symmetry, if
'`' (quote backtick quote) is legal, then
`'` (backtick quote backtick)
should also be. I see no point in allowing a normal quote to end a ` string,
as the opposite also does not happen. A backtick also does not end a
single-quoted string.

The backticked string is in all respects the same as a regular string,
except that the single quote delimiter is replaced by a backtick delimiter.

That means that `this is `` a bakcticked string with a backtick in it`
should also work.

if memory serves well, Martin Friebe already pointed this out, and IMO rightly 
so.

Michael.
_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply via email to