2
0

no-gnu-inline-asm.c 481 B

123456789101112131415
  1. // RUN: %clang_cc1 %s -triple i686-apple-darwin -verify -fsyntax-only -fno-gnu-inline-asm
  2. asm ("INST r1, 0"); // expected-error {{GNU-style inline assembly is disabled}}
  3. void foo() __asm("__foo_func"); // AsmLabel is OK
  4. int foo1 asm("bar1") = 0; // OK
  5. asm(" "); // Whitespace is OK
  6. void f (void) {
  7. long long foo = 0, bar;
  8. asm volatile("INST %0, %1" : "=r"(foo) : "r"(bar)); // expected-error {{GNU-style inline assembly is disabled}}
  9. asm (""); // Empty is OK
  10. return;
  11. }