Bug 65067 - uninitialized const memeber error with g++ 3.1
uninitialized const memeber error with g++ 3.1
Status: CLOSED CURRENTRELEASE
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
7.3
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-05-16 18:15 EDT by Alexander Larsson
Modified: 2008-05-01 11:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2002-12-15 15:26:31 EST
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 Alexander Larsson 2002-05-16 18:15:25 EDT
Building fam with gcc 3.1 i stumbled upon this gem:

struct FDInfo {
  struct FDIOHandler {
    void *closure;
  } read, write;
};

struct IOTypeInfo {
  FDInfo::FDIOHandler FDInfo::*const iotype;
  IOTypeInfo(FDInfo::FDIOHandler FDInfo::* a_iotype) : iotype(a_iotype) {  
}
};

IOTypeInfo foo (&FDInfo::read);


It gives me:
foo.c++:12: uninitialized const member `IOTypeInfo::iotype'

But it worked in gcc 2.96, and i fail to see the problem. iotype is 
clearly initialized.
Comment 1 Alan Cox 2002-12-15 15:26:31 EST
Ok in 3.2 / 8.0

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