mirror of
https://github.com/intel/llvm.git
synced 2026-01-20 10:58:11 +08:00
Seems like a logical extension to me - and of interest because it might help reduce the debug info size of libc++ by applying this attribute to type traits that have a disproportionate debug info cost compared to the benefit (& possibly harm/confusion) they cause users. llvm-svn: 362856
12 lines
428 B
C
12 lines
428 B
C
// RUN: %clang_cc1 %s -verify -fsyntax-only
|
|
|
|
int a __attribute__((nodebug));
|
|
|
|
void b(int p __attribute__((nodebug))) { // expected-warning {{'nodebug' attribute only applies to typedefs, functions, function pointers, Objective-C methods, and variables}}
|
|
int b __attribute__((nodebug));
|
|
}
|
|
|
|
void t1() __attribute__((nodebug));
|
|
|
|
void t2() __attribute__((nodebug(2))); // expected-error {{'nodebug' attribute takes no arguments}}
|