Removing -frwitable-strings

Zack Weinberg zack@codesourcery.com
Sat Dec 20 15:33:00 GMT 2003


Matt Austern <austern@apple.com> writes:

> At the risk of getting boring by repeating myself...  This might be an
> argument for treating C and C++ differently.  The two languages have
> different rules about the types of string literals, and it's a lot
> harder to
> call 'char* p = "foo"' clean code in C++ than it is in C.

C++ is treated differently.  -fwritable-strings does not work in C++,
and -Wwrite-strings is effectively always on.

zw



More information about the Gcc mailing list