// RUN: not %clang_cc1 -triple i686-pc-win32 -emit-llvm -fno-rtti %s 2>&1 | FileCheck %s

// CHECK: error: v-table layout for classes with non-virtual base classes that override methods in virtual bases is not supported yet

struct A {
  virtual int foo() { return a; }
  int a;
};
struct B : virtual A {
  B() : b(1) {}
  virtual int bar() { return b; }
  int b;
};
struct C : virtual A {
  C() : c(2) {}
  virtual int foo() { return c; }
  int c;
};
struct D : B, C {
  D() : d(3) {}
  virtual int bar() { return d; }
  int d;
};
int main() {
  D d;
  return d.foo();
}

// RUN: not %clang_cc1 -triple i686-pc-win32 -emit-llvm-only -fno-rtti %s 2>&1 | FileCheck %s

// CHECK: error: v-table layout for classes with non-virtual base classes that override methods in virtual bases is not supported yet

struct A {
  virtual int foo() { return a; }
  int a;
};
struct B : virtual A {
  B() : b(1) {}
  virtual int bar() { return b; }
  int b;
};
struct C : virtual A {
  C() : c(2) {}
  virtual int foo() { return c; }
  int c;
};
struct D : B, C {
  D() : d(3) {}
  virtual int bar() { return d; }
  int d;
};
int main() {
  D d;
  return d.foo();
}

Change this test to not try to emit any IR. (It should fail to, but it tries to create an output file before encountering the error.)
Change this test to not try to emit any IR. (It should fail to, but it tries to create an output file before encountering the error.)


git-svn-id: ffe668792ed300d6c2daa1f6eba2e0aa28d7ec6c@202343 91177308-0d34-0410-b5e6-96231b3b80d8
