[LLVMbugs] [Bug 261] NEW: [llvmg++] "Cannot copy incompatible structs!" assertion

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Fri Feb 27 08:33:19 PST 2004


           Summary: [llvmg++] "Cannot copy incompatible structs!" assertion
           Product: tools
           Version: 1.0
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: llvm-g++
        AssignedTo: sabre at nondot.org
        ReportedBy: sabre at nondot.org

This testcase:

struct A {
  virtual void Method() = 0;

struct B : public A {
  virtual void Method() { }

typedef void (A::*fn_type_a)(void);
typedef void (B::*fn_type_b)(void);

int main(int argc, char **argv)
  fn_type_a f = reinterpret_cast<fn_type_a>(&B::Method);
  fn_type_b g = reinterpret_cast<fn_type_b>(f);
  B b;
  return 0;

Causes the C++ front-end to crash.


------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.

More information about the llvm-bugs mailing list