Check that we don't warn on this testcase. This is basically a test that
authorRafael Espindola <rafael.espindola@gmail.com>
Fri, 23 Nov 2012 13:54:40 +0000 (13:54 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Fri, 23 Nov 2012 13:54:40 +0000 (13:54 +0000)
Decl::isUsed checks the attribute. If the function had a body just the check
is DeclMustBeEmitted would be sufficient.

llvm-svn: 168514

clang/test/Sema/attr-used.c

index e2dfab1..accc7b6 100644 (file)
@@ -17,4 +17,4 @@ void f1() {
   int b __attribute__((used)); // expected-warning {{used attribute ignored}}
 }
 
-
+static void __attribute__((used)) f0(void);