Putting quotes in wysiwyg strings
Lionello Lunesu
lio at lunesu.remove.com
Wed Nov 22 01:40:07 PST 2006
Bill Baxter wrote:
> From the spec: 'There are no escape sequences inside r" ":'
>
> Shouldn't there be an exception for the " character itself?
> Right now the only way to put the quote into a wysiwyg string like
> foo"bar
> is something like:
> r"foo" ~'"'~ r"bar";
> or
> r"foo" "\"" r"bar";
> or
> r"foo" `"` r"bar";
>
> It would be a lot nicer if one could just do:
>
> r"foo\"bar";
I'd prefer doubling the ", similar to program arguments on the command line:
r"foo""bar"
(This already compiles, but generates foobar instead of foo"bar; if you
want foobar with the suggested behavior, you could add a space: r"foo"
"bar")
L.
More information about the Digitalmars-d
mailing list