g++ crash after template errors

Bug #301674 reported by Alan Jenkins
2
Affects Status Importance Assigned to Milestone
gcc-4.2 (Ubuntu)
Won't Fix
Undecided
Unassigned

Bug Description

Binary package hint: gcc-4.2

Apport tells me to report this, so I do! I have to say I don't care - it gives me enough error messages before crashing, I'm sure I can fix them and get it to compile (or work out why what I'm trying to do is impossible :).

gateImpl.cpp:143: error: template definition of non-template ‘typename<unnamed>::NamedLogic<LogicImpl, name_init>::Factory <unnamed>::NamedLogic<LogicImpl, name_init>::factory’
gateImpl.cpp:287: error: ‘<unnamed>::Gates::BUFFER::factory_fwd’ is not a valid template argument because ‘<unnamed>::Gates::BUFFER::factory_fwd’ is a variable, not the address of a variable
gateImpl.cpp:287: error: invalid type in declaration before ‘;’ token
gateImpl.cpp:291: error: expected initializer before ‘factory’
gateImpl.cpp:292: error: ‘factory’ was not declared in this scope
gateImpl.cpp:297: error: redefinition of ‘class<unnamed>::Gates::BUFFER::Impl’
gateImpl.cpp:281: error: previous definition of ‘class<unnamed>::Gates::BUFFER::Impl’
gateImpl.cpp:303: error: redefinition of ‘const char <unnamed>::Gates::BUFFER::name []’
gateImpl.cpp:289: error: ‘const char <unnamed>::Gates::BUFFER::name [4]’ previously defined here
gateImpl.cpp:305: error: conflicting declaration ‘typedef class<unnamed>::Gates::NamedGate<<unnamed>::Gates::BUFFER::Impl, ((const char*)(&<unnamed>::Gates::BUFFER::name))> <unnamed>::Gates::BUFFER::Gate’
gateImpl.cpp:287: error: ‘<unnamed>::Gates::BUFFER::Gate’ has a previous declaration as ‘typedef int <unnamed>::Gates::BUFFER::Gate’
gateImpl.cpp:306: error: expected initializer before ‘&’ token
gateImpl.cpp:250: confused by earlier errors, bailing out
Preprocessed source stored into /tmp/cc8rgSdf.out file, please attach this to your bugreport.
make: *** [gateImpl.o] Error 1

ProblemType: Crash
Architecture: amd64
Date: Mon Nov 24 13:56:22 2008
DistroRelease: Ubuntu 8.04
ExecutablePath: /usr/lib/gcc/x86_64-linux-gnu/4.2.4/cc1plus
Package: g++-4.2 4.2.4-1ubuntu3
PackageArchitecture: amd64
SourcePackage: gcc-4.2
Uname: Linux 2.6.28-rc6-00007-ged31348 x86_64

Tags: apport-crash
Revision history for this message
Alan Jenkins (aj504) wrote :
Revision history for this message
Alan Jenkins (aj504) wrote :

I reduced some of the extraneous errors, try this one instead.

g++ -c -g -Wall -ansi -m32 -Os -o gateImpl.o gateImpl.cpp
gateImpl.cpp:283: error: ‘<unnamed>::Gates::BUFFER::factory_fwd’ is not a valid template argument because ‘<unnamed>::Gates::BUFFER::factory_fwd’ is a variable, not the address of a variable
gateImpl.cpp:283: error: invalid type in declaration before ‘;’ token
gateImpl.cpp:287: error: expected initializer before ‘factory’
gateImpl.cpp:288: error: ‘factory’ was not declared in this scope
gateImpl.cpp:246: confused by earlier errors, bailing out
Preprocessed source stored into /tmp/ccr4gRHa.out file, please attach this to your bugreport.
make: *** [gateImpl.o] Error 1

Revision history for this message
Matthias Klose (doko) wrote :

confirmed; please could you regenerate the preprocessed code / try to build with gcc-snapshot from karmic?
seems to be reproducible with newer compiler versions.

Changed in gcc-4.2 (Ubuntu):
status: New → Confirmed
Revision history for this message
Alan Jenkins (aj504) wrote : Re: [Bug 301674] Re: g++ crash after template errors

On 29 December 2009 16:00, Matthias Klose <email address hidden>wrote:

> confirmed; please could you regenerate the preprocessed code / try to build
> with gcc-snapshot from karmic?
> seems to be reproducible with newer compiler versions.
>
>
> ** Changed in: gcc-4.2 (Ubuntu)
> Status: New => Confirmed
>
>
Sorry, I neglected to preserve the exact source code. I'd have hoped the
preprocessed code was enough on it's own.

Thanks
Alan

Revision history for this message
Matthias Klose (doko) wrote :

marking it as won't fix for gcc-4.2 (which was removed in lucid)

Changed in gcc-4.2 (Ubuntu):
status: Confirmed → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.