This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: \0 in strings
- To: Per Hedbor <per at idonex dot se>
- Subject: Re: \0 in strings
- From: Horst von Brand <vonbrand at sleipnir dot valparaiso dot cl>
- Date: Sun, 27 Feb 2000 15:18:17 -0300
- cc: gcc-bugs at gcc dot gnu dot org
Per Hedbor <per@idonex.se> said:
> The newest snapshot version of gcc gives errors when it encounters a ˙
> after encountering a \0 in a string:
>
> test.c:1: Unterminated string constant
> test.c:2: Unterminated string constant
> test.c:2: parse error at end of input
>
> The whole contents of 'test.c' is:
> unsigned char *f = "\0˙";
What machine is this? ˙ is what I see when somebody tries to print an EOF,
so this is probably working in reverse somewhere.
In any case, I see the same here (egcs-20000221, glibc-2.1.3 on
i686-redhat-linux). egcs-1.1.2-24 and gcc-2.95.2 work fine.
--
Horst von Brand vonbrand@sleipnir.valparaiso.cl
Casilla 9G, Viņa del Mar, Chile +56 32 672616