This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
C++ section 11.8 and gcc 2.95.2 versus 3.0
- To: gcc at gcc dot gnu dot org
- Subject: C++ section 11.8 and gcc 2.95.2 versus 3.0
- From: Magnus Fromreide <magfr at lysator dot liu dot se>
- Date: Tue, 22 May 2001 23:04:28 +0200 (MET DST)
If you try to compile the examples from section 11.8 of the C++ standard
using g++ -ansi -pedantic then the second one compiles without complaints
while the first one terminates on the third marked fault position, if that
one is removed then it comes through compilation.
gcc 2.95.2 also complained on line 9 of the first example (p->x = i;) and
terminated there so I do suppose that this is a regression from 2.95.2.
Yes, I am aware that the examples aren't normative but if the example is
wrong then we have found a bug in the standard and otherwise we have found
a bug in gcc.