Skip to contentSkip to conversation

internal compiler error: in cp_expr_size, at cp/cp-lang.c:307

parisc-linux Randolph Chung 1 participant 1 message Mar 15, 2003

lore
Share & tools
lore
#0 lore raw
Quoted 10 lines
Category:       c++
Synopsis:       [3.3 regression] internal compiler error: in cp_expr_size, at cp/cp-lang.c:307
Confidential:   no
Severity:       serious
Priority:       medium
Class:          ice-on-legal-code
Submitter-Id:   net
Originator:     Randolph Chung <[email protected]>
Release:        3.3 20030309 (Debian prerelease) (Debian testing/unstable)

Environment:

System: Linux gsyprf11.external.hp.com 2.4.20-pa18-UP #1 Sat Jan 4 22:06:52 PST 2003 parisc64 unknown unknown GNU/Linux
Architecture: parisc64

Quoted 1 line

Description:

The following code (extracted from goldedplus), when compiled with g++ -c -O2 bug.cpp, gives:

bug.cpp: In member function `int ftn_golded_nodelist_index::addrcmp() const':
bug.cpp:34: internal compiler error: in cp_expr_size, at cp/cp-lang.c:307 Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.

class ftn_addr {
public:
unsigned short zone;
unsigned short net;
unsigned short node;
unsigned short point;

ftn_addr();
ftn_addr(const ftn_addr& a);
int compare(const ftn_addr& other) const;
ftn_addr& operator=(const ftn_addr& a);
};

#pragma pack(1)

struct _GEIdx {
ftn_addr addr; // Node address
_GEIdx() : addr() {}
};

#pragma pack()

class ftn_golded_nodelist_index {
protected:
_GEIdx current;
ftn_addr searchaddr;
int addrcmp() const;

public:
ftn_golded_nodelist_index();
};

int ftn_golded_nodelist_index::addrcmp() const {
return searchaddr.compare(current.addr);
}

Quoted 1 line

How-To-Repeat:

see description
compiles fine with g++-3.2

Quoted 1 line

Fix:

unknown

Quoted 1 line

Unformatted: