bug-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-gplusplus] Internal compiler error in function instantiate_virtual_


From: Lee Worden
Subject: [Bug-gplusplus] Internal compiler error in function instantiate_virtual_regs_1
Date: Wed, 20 Sep 2000 18:50:04 -0400 (EDT)

Problem seems to involve ?: with a class that converts to+from a scalar
type.

I hit the bug in gcc 2.8.1, but I also find it in egcs-2.91.66, which has
more of a message:

egcs test-g++.cc -o test-g++
../../gcc/function.c:3272: Internal compiler error in function
instantiate_virtual_regs_1

Lee Worden
--
Here is test-g++.cc:

#include <iostream.h>

class LC
{
protected:
  long l;
public:
  inline LC(int x) :l(x) {}
  inline operator int() { return l; }
};

int main(void)
{
  int i = 0;
  LC lx = 8;
  LC lc = i ? lx : (LC)1;
  return 0;
}




reply via email to

[Prev in Thread] Current Thread [Next in Thread]