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 target/34734] attribute((progmem)) not handled properly in C++ for AVRs



------- Comment #2 from hsteinhaus at gmx dot de  2008-03-07 20:59 -------
version 4.2.1 seems to be affected as well:

--------------------------------------------
holger@x:~/scratch$ cat foo.cpp
#include <avr/pgmspace.h>

const int foobar1 = 42;
int foobar2 = 42;
const int PROGMEM foobar3 = 42;
int PROGMEM foobar4 = 42;

holger@x:~/scratch$ avr-g++ -Wall -mmcu=atmega1281 -c foo.cpp
foo.cpp:5: warning: only initialized variables can be placed into program
memory area
foo.cpp:6: warning: only initialized variables can be placed into program
memory area
holger@x:~/scratch$ avr-g++ --version
avr-g++ (GCC) 4.2.1 (SUSE Linux)
Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


-- 


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


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