Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 56486 - gcc 2.96-99 refuses to compile legal C++ code
gcc 2.96-99 refuses to compile legal C++ code
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
Depends On:
  Show dependency treegraph
Reported: 2001-11-19 15:06 EST by Peter Klotz
Modified: 2007-04-18 12:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-11-19 15:06:45 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Peter Klotz 2001-11-19 15:06:39 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)

Description of problem:

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1.Compile the program supplied under "Additional Information"

Additional info:

#include <string>

class A
	template<typename T>
	void f(const std::string& x, const std::string& y, const T& z, 
const std::string& a="");

template<typename T>
void A::f(const std::string& x, const std::string& y, const T& z, const 
std::string& a)

void A::f<std::string>(const std::string& x, const std::string& y, const 
std::string& z, const std::string& a)

int main(void)
	A a;
	return 0;
Comment 1 Jakub Jelinek 2001-11-19 15:19:15 EST
libstdc++ v2 (found e.g. in gcc-2.95.x and gcc-2.96-RH) never claimed to be
100% ISO C++ 98 conforming, this is just one of the cases. With g++ 2.95.x
you'll get the same result.
If you want this to work, you can use gcc 3.0.x (e.g. found in RHL 7.2
gcc3* rpms).

Note You need to log in before you can comment on or make changes to this bug.