STL Bug in egcs-1.1.1

Thomas Binder binder@iue.tuwien.ac.at
Mon Dec 21 06:29:00 GMT 1998


Hi everybody.

It seems as if I found a bug in either STL's rope class or the compiler itself.

cat stl.cc

#include <rope.h>


eg++ -v -c stl.cc -ansi -pedantic
Reading specs from
/usr/local/egcs/lib/gcc-lib/i686-pc-linux-gnulibc1/egcs-2.91.60/specs
gcc version egcs-2.91.60 19981201 (egcs-1.1.1 release)
 /usr/local/egcs/lib/gcc-lib/i686-pc-linux-gnulibc1/egcs-2.91.60/cpp -lang-c++
-v -undef -D__GNUC__=2 -D__GNUG__=2 -D__cplusplus -D__GNUC_MINOR__=91 -trigraphs
-D__STRICT_ANSI__ -D__ELF__ -D__unix__ -D__i386__ -D__i386__ -D__linux__
-D__unix -D__i386 -D__linux -Asystem(posix) -D__EXCEPTIONS -pedantic
-Asystem(unix) -Acpu(i386) -Amachine(i386) -D__i386 -D__i386__ -D__i686
-D__i686__ -D__pentiumpro -D__pentiumpro__ stl.cc /tmp/ccF4DqZ4.ii
GNU CPP version egcs-2.91.60 19981201 (egcs-1.1.1 release) (i386 Linux/ELF)
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/egcs/include/g++
 /usr/local/include
 /usr/local/egcs/i686-pc-linux-gnulibc1/include
 /usr/local/egcs/lib/gcc-lib/i686-pc-linux-gnulibc1/egcs-2.91.60/include
 /usr/include
End of search list.
 /usr/local/egcs/lib/gcc-lib/i686-pc-linux-gnulibc1/egcs-2.91.60/cc1plus
/tmp/ccF4DqZ4.ii -quiet -dumpbase stl.cc -pedantic -ansi -version -o
/tmp/ccD0kTZs.s
GNU C++ version egcs-2.91.60 19981201 (egcs-1.1.1 release)
(i686-pc-linux-gnulibc1) compiled by GNU C version egcs-2.91.60 19981201
(egcs-1.1.1 release).
In file included from /usr/local/egcs/include/g++/rope.h:18,
                 from stl.cc:2:
/usr/local/egcs/include/g++/stl_rope.h:847: parse error before `)'
/usr/local/egcs/include/g++/stl_rope.h:847:
`__rope_iterator<CharT,Alloc>::operator +=(...)' must take exactly one argument
/usr/local/egcs/include/g++/stl_rope.h:847: confused by earlier errors, bailing
out


If you don't specify -ansi -pedantic the "code" compiles just fine. 

Does that mean the rope class is not ANSI-C++ compliant or is it just a 
"simple" compiler bug ?

regards,
T.Binder
-- 
"Computers are like air conditioners - they stop working properly when you open
 Windows"
                            \\\|///
                          \\  ~ ~  //
                           (  @ @  )
/------------------------oOOo-(_)-oOOo-----------------------------------------\
| Thomas Binder                        |                                       |
| Institute for  Microelectronics      | phone: ++43/1/58801-36036             |
| Technical University Vienna          |                                       |
| Gusshausstrasse  27-29 / E360        | fax  : ++43/1/58801-36099             |
| A-1040  Vienna                       |                                       |
| A U S T R I A                        | email: binder@iue.tuwien.ac.at        |
\---------------------------------Oooo.----------------------------------------/
                        .oooO     (   )
                        (   )      ) /
                         \ (      (_/
                          \_)



More information about the Gcc-bugs mailing list