This is the mail archive of the gcc-bugs@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]

[Bug c/7776] const char* p = "foo"; if (p == "foo") ... is compiled without warning!


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=7776



------- Additional Comments From udbz@rz.uni-karlsruhe.de  2003-05-24 18:43 -------
Subject: Re: [Bug c/7776] const char* p = "foo"; if (p == "foo") ... is
 compiled without warning!

Hi,

On 24 May 2003, pinskia@physics.uc.edu wrote:

> ------- Additional Comments From pinskia@physics.uc.edu  2003-05-24 14:08 -------
> confirmed on mainline (20030524).
> Should there be a warning on comparing a char* to string constant,
> suggesting strcmp?

Yes, that was the idea.

Greetings,
Peter

---
Peter Schlaile  ***  eMail udbz@rz.uni-karlsruhe.de

So Linus, what are we doing tonight?
          The same thing we do every night Tux. Try to take over the world!





------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


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