[Bug c++/26665] New: Gcc segmentation fault
babydavid at sjtu dot edu dot cn
gcc-bugzilla@gcc.gnu.org
Mon Mar 13 14:46:00 GMT 2006
My code is:
//-----------------------------------------------
#include <iostream>
template < int I >
struct _integer {
enum { _value = I };
typedef _integer<_value> _type;
};
#define _I(Int) \
typename _integer<Int>::_type
template< class type >
void hi(type) {
std::cout << std::endl;
}
int main() {
hi(_I(1)()); //Bug report here.
return 0;
}
//-------------------------------------------
And my gcc command is:
g++ -O2 test.cpp -o test
//-------------------------------------------
The bug report is:
test.cpp: In function Âint main()Â:
test.cpp:72: internal compiler error: Segmentation fault
--
Summary: Gcc segmentation fault
Product: gcc
Version: 4.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: babydavid at sjtu dot edu dot cn
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26665
More information about the Gcc-bugs
mailing list