This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: Pascal Strings -- TAKE FOUR
- To: Ziemowit Laski <zlaski at apple dot com>
- Subject: Re: PATCH: Pascal Strings -- TAKE FOUR
- From: Richard Earnshaw <rearnsha at arm dot com>
- Date: Wed, 04 Jul 2001 11:25:34 +0100
- cc: gcc-patches at gcc dot gnu dot org, Richard dot Earnshaw at arm dot com
- Organization: ARM Ltd.
- Reply-To: Richard dot Earnshaw at arm dot com
+ Pascal-style literals are treated by the compiler as being of type
+ @samp{const unsigned char []} in C++ and @samp{unsigned char []} (or
+ @samp{const unsigned char []}, if the @w{@option{-Wwrite-strings}}
+ option is given) in C.
Yes, this is what -Wwrite-strings does (in a way), but is this really
correct? -Wwrite-strings is really a warning flag. String literals in
(GNU) C are really constants unless -fwritable-strings is given.
R.