llvm-for-llvmta/tools/clang/test/Sema/avr-signal-attr.c

9 lines
350 B
C
Raw Permalink Normal View History

2022-04-25 13:02:35 +02:00
// RUN: %clang_cc1 %s -triple avr-unknown-unknown -verify -fsyntax-only
struct a { int b; };
struct a test __attribute__((signal)); // expected-warning {{'signal' attribute only applies to functions}}
__attribute__((signal(12))) void foo(void) { } // expected-error {{'signal' attribute takes no arguments}}
__attribute__((signal)) void food() {}