Home | History | Annotate | Download | only in CodeGenCXX
      1 // RUN: %clang_cc1 %s -emit-llvm -o - -fblocks
      2 // Just test that this doesn't crash the compiler...
      3 
      4 void func(void*);
      5 
      6 struct Test
      7 {
      8   virtual void use() { func((void*)this); }
      9   Test(Test&c) { func((void*)this); }
     10   Test() { func((void*)this); }
     11 };
     12 
     13 void useBlock(void (^)(void));
     14 
     15 int main (void) {
     16   __block Test t;
     17   useBlock(^(void) { t.use(); });
     18 }
     19 
     20