Bug 5039 - Support need GCC in
Support need GCC in
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: egcs (Show other bugs)
6.0
i386 Linux
high Severity high
: ---
: ---
Assigned To: Nalin Dahyabhai
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-09-10 04:05 EDT by rkatti
Modified: 2008-05-01 11:37 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-09-10 11:29:51 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description rkatti 1999-09-10 04:05:48 EDT
Hello,

I have been using the following on my Red Hat linux 6.0
Intel machine :-
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)

I have a problem in compiling the following C++ program
containing template code on this version of the compiler.
It is A BUG IN THIS version of compiler.

The program is as follows :-

-----------------------------------------------------
#include  <stdio.h>
#include <stdlib.h>

class Dummy {

 int i;
};

template < class X >
class Array {
int i;
public :
static void * operator new(size_t ) ;
};

void * Array<Dummy>::operator new(size_t  i) {
printf ("\n new of Dummy ");
return (void *)malloc(i);
}

template <class X> void * Array<class X>::operator
new(size_t  i) {
printf ("\n new of X");
return (void *)malloc(i);
}

Array<Dummy> *a;
Array<int> *i;

int main () {

a = new Array<Dummy>;
i = new Array<int>;

return 0;
}


-----------------------------------------------------

This program gets compiled on the older version of compiler
but on the newer version it gives the following
error message :-
 " c.cxx:15: template-id `operator new<>' for
`Array<Dummy>::operator
new<>(size_t)' does not match any template declaration "


 But, this bug is FIXED on "GCC 2.95.1". I checked
this by downloading the source code of GCC-2.95.1 and
building the compiler on my machine.

 Could you please suggest me the egcs-rpm-number or patch
that contains the fix. Also please, let me know the
source from where I could dowload this patch/rpm.


Regards,
Raghvendra Katti
Comment 1 Jim Kingdon 1999-09-10 11:29:59 EDT
We do not expect to be providing a GCC 2.95.x RPM any time soon.
While 2.95.x does contain many C++ fixes, it also is binary
incompatible for C++ and has many problems on the Alpha.

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