c++/10373: Attempt to compile STLport causes segmentation fault

Giovanni Bajo giovannibajo@libero.it
Fri Apr 11 02:44:00 GMT 2003


http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&p
r=10373

Redux:
-------------------------------------------
namespace A {}
namespace B {}

namespace A {
    using namespace B;
}

namespace B {
    using namespace A;
}

void Foo(void) { using namespace A;  }
-------------------------------------------
pr10373.cpp: In function `void Foo()':
pr10373.cpp:12: internal error: Segmentation fault


Confirmed on 3.2 and 3.2.2. Worked on 2.95, and works on 3.3 20030401. So,
it's a regression on the 3.2 branch only, and I'm not sure there is more
time for patches for 3.2.

If this works on 3.4 as well, the PR should be closed as 'fixed'.

For the poster: the obvious workaround is to modify the function where the
ICE happens so that it does not use an internal "using namespace std;". Just
qualify everything needed with "std::", and the code should compile. You're
welcome to submit such a patch to the STLPort guys as a workaround for GCC
3.2.

Giovanni Bajo



More information about the Gcc-bugs mailing list