This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Warnings about rcs_id strings: let's settle this


On 02-May-2003, Kean Johnston <jkj@sco.com> wrote:
> the original
> construct that spawned this thread was almost always written as
> static char *sccsid = "blah";. By the way, why does THAT not emit a
> warning? You are assigning a const char * to a char *, thereby
> potentially losing the const-ness of it. I just tried with the head
> version and -Wall -Wextra -Wcast-qual didn't emit a warning.

"-Wwrite-strings" is the one you're looking for.
The manual explains why it is not in -Wall.

-- 
Fergus Henderson <fjh@cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]