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]

c++/3.0: -pedantic makes an error a warning?


Hi,

the appended testcase compiled on powerpc-linux-gnu produces an error:

[fsirl@enzo:/cvsx/rawhide/BUILD/pilot-link/libcc]$ c++ -I../include 
-I./../include -O2 -fsigned-char -Wall -c datebook.cc
In file included from ../include/pi-datebook.h:90,
                 from datebook.cc:11:
../include/pi-datebook.hxx:37: friend declaration requires class-key, i.e.
   `friend class appointmentList_t'

Now, if I add -pedantic the error is downgraded to a warning:

[fsirl@enzo:/cvsx/rawhide/BUILD/pilot-link/libcc]$ c++ -I../include 
-I./../include -O2 -fsigned-char -Wall -c datebook.cc -pedantic
In file included from ../include/pi-datebook.h:90,
                 from datebook.cc:11:
../include/pi-datebook.hxx:37: warning: friend declaration requires class-key,
   i.e. `friend class appointmentList_t'

Is this normal?

Franz.

datebook.ii.bz2


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