On various architectures all the 4.0.X versions of g++ fail to properly instanciate some members of a class template if optimisation is set to -O3. For -O2 everything is fine. A test case will be attached.
Versions tested: g++ 4.0.3 20060212 (prerelease) (Debian 4.0.2-9) i686-pc-linux-gnu g++ 4.0.2 x86_64-redhat-linux g++ 4.0.1 (Apple Computer, Inc. build 5247) powerpc-apple-darwin8 Versions known to work: g++ 3.4.X -- Summary: template Instanciation fails for -O3 Product: gcc Version: 4.0.2 Status: UNCONFIRMED Severity: minor Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: _talyn_ at web dot de GCC build triplet: i686-pc-linux-gnu GCC host triplet: i686-pc-linux-gnu GCC target triplet: i686-pc-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26621