1*c87b03e5Sespie /* Ensure dllexport overrides dllimport. */ 2*c87b03e5Sespie 3*c87b03e5Sespie /* { dg-do compile { target arm*-*-pe* } } */ 4*c87b03e5Sespie /* { dg-do compile { target thumb*-*-pe* } } */ 5*c87b03e5Sespie 6*c87b03e5Sespie __declspec (dllimport) int foo1 (); 7*c87b03e5Sespie __declspec (dllexport) int foo1 (); 8*c87b03e5Sespie 9*c87b03e5Sespie __declspec (dllexport) int foo2 (); 10*c87b03e5Sespie __declspec (dllimport) int foo2 (); 11*c87b03e5Sespie foo1()12*c87b03e5Sespie__declspec (dllexport) int foo1 () { return foo2 (); } foo2()13*c87b03e5Sespie__declspec (dllexport) int foo2 () { return foo1 (); } 14*c87b03e5Sespie 15*c87b03e5Sespie /* { dg-final { scan-assembler "\.section\[ \t\]*\.drectve\n\[^\n\]*-export:foo1.*\.section\[ \t\]*\.drectve\n\[^\n\]*-export:foo2" } } */ 16*c87b03e5Sespie /* { dg-final { scan-assembler-not "(__imp_foo1|__imp_foo2)" } } */ 17