This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
bugreport: implicitly converting (const char*) to (char*)
- From: Zhang <code0000 at gmail dot com>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 26 Jul 2007 12:09:27 +0800
- Subject: bugreport: implicitly converting (const char*) to (char*)
Dear working group,
Although it looks quite simple, I found the code which implicitly
converts a const char* to char*:
char* str = "Helloworld";
*str = 'a';
It can be legally compiled, and certainly produces an error when
running.
I'm not certain whether it's actually a bug or not.
Hope to hear from you.