blob: 3f385d16c18c4a3ff817d604fa8541735fca053b [file] [log] [blame]
Anton Korobeynikov2f402702008-12-26 00:52:02 +00001// RUN: clang -fsyntax-only -verify %s
2
3inline void __attribute__((dllexport)) foo1(){} // expected-warning{{dllexport attribute ignored}}
4inline void __attribute__((dllimport)) foo2(){} // expected-warning{{dllimport attribute ignored}}
5
6void __attribute__((dllimport)) foo3(){} // expected-error{{dllimport attribute can be applied only to symbol declaration}}
7
8void __attribute__((dllimport, dllexport)) foo4(); // expected-warning{{dllimport attribute ignored}}
9
10void __attribute__((dllexport)) foo5();
11void __attribute__((dllimport)) foo5(); // expected-warning{{dllimport attribute ignored}}
12
Chris Lattner026dc962009-02-14 07:37:35 +000013typedef int __attribute__((dllexport)) type6; // expected-warning{{'dllexport' attribute only applies to variable and function types}}
Anton Korobeynikov2f402702008-12-26 00:52:02 +000014
Chris Lattner026dc962009-02-14 07:37:35 +000015typedef int __attribute__((dllimport)) type7; // expected-warning{{'dllimport' attribute only applies to variable and function}}
Anton Korobeynikov2f402702008-12-26 00:52:02 +000016
17void __attribute__((dllimport)) foo6();
18void foo6(){} // expected-warning {{'foo6' redeclared without dllimport attribute: previous dllimport ignored}}