This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: RFC: cpplib: multiline strings
- To: Neil Booth <NeilB at earthling dot net>
- Subject: Re: RFC: cpplib: multiline strings
- From: Zack Weinberg <zack at wolery dot cumb dot org>
- Date: Sun, 20 Aug 2000 08:38:33 -0700
- Cc: gcc at gcc dot gnu dot org
- References: <E13QQs0-0003Ak-00@daikokuya.demon.co.uk>
On Sun, Aug 20, 2000 at 09:54:20AM +0100, Neil Booth wrote:
> I'd like to get rid of them to be honest, but I know that's not an
> option. Instead, I'd like to propose that we make it undefined
> behaviour if the first non-whitespace (in the C sense, i.e. including
> C-style comments) character on the second or subsequent lines of a
> multiline string is a # (or its digraphed equivalent). Thus
I don't have a good sense of who uses multiline strings for what, but
if we're going to support them at all (and I'm not opposed to dropping
them entirely), I don't think we should introduce a strange rule like
that. Especially not just to permit a minor performance optimization.
Besides, I don't think it helps you much - you still have to know
about block comments and escaped newlines.
The old old cpp had two lexers, one for normal text and one for
conditional skipping. The latter knew only about comments, strings,
and directive lines. If you want to put this optimization back, I
think you should take that approach.
zw