This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/30622] char *p; p = "str"; puts "str" into rodata
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Jan 2007 17:13:13 -0000
- Subject: [Bug c/30622] char *p; p = "str"; puts "str" into rodata
- References: <bug-30622-12956@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from pinskia at gcc dot gnu dot org 2007-01-28 17:13 -------
More to the point, at one time in the past, GCC had an option to turn
(constant) string literals into readwrite strings, that was removed in 4.0.0
(maybe even in 3.4.0). Also the standard says they are constant string
literals and not just strings.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30622