// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -fsyntax-only -Wno-strict-prototypes -verify %s
// RUN: %clang_cc1 -triple x86_64-unknown-windows -fsyntax-only -Wno-strict-prototypes -verify %s
int notAFunction SWIFTCALL; // expected-warning {{'swiftcall' only applies to function types; type here is 'int'}}
int notAnAsyncFunction SWIFTASYNCCALL; // expected-warning {{'swiftasynccall' only applies to function types; type here is 'int'}}
void SWIFTCALL; // expected-error {{variadic function cannot use swiftcall calling convention}}
void SWIFTASYNCCALL; // expected-error {{variadic function cannot use swiftasynccall calling convention}}
void SWIFTCALL; // expected-error {{function with no prototype cannot use the swiftcall calling convention}}
void SWIFTASYNCCALL; // expected-error {{function with no prototype cannot use the swiftasynccall calling convention}}
void SWIFTCALL ; // expected-error {{vectorcall and swiftcall attributes are not compatible}}
void SWIFTASYNCCALL ; // expected-error {{vectorcall and swiftasynccall attributes are not compatible}}
SWIFTCALL;
SWIFTASYNCCALL;
void ; // expected-error {{'swift_indirect_result' parameter can only be used with swiftcall or swiftasynccall calling convention}}
void SWIFTCALL; // expected-error {{'swift_indirect_result' parameters must be first parameters of function}}
void SWIFTCALL; // expected-error {{'swift_indirect_result' parameter must have pointer type; type here is 'int'}}
void SWIFTCALL;
void SWIFTCALL;
void SWIFTASYNCCALL;
void SWIFTASYNCCALL;
void ; // expected-error {{'swift_error_result' parameter can only be used with swiftcall calling convention}} expected-error{{'swift_error_result' parameter must follow 'swift_context' parameter}}
void SWIFTCALL; // expected-error {{'swift_error_result' parameter must follow 'swift_context' parameter}}
void SWIFTCALL; // expected-error {{'swift_error_result' parameter must have pointer to unqualified pointer type; type here is 'int'}}
void SWIFTCALL; // expected-error {{'swift_error_result' parameter must have pointer to unqualified pointer type; type here is 'int *'}}
void SWIFTCALL;
void SWIFTCALL;
void ; // expected-error {{'swift_context' parameter can only be used with swiftcall or swiftasynccall calling convention}}
void SWIFTCALL; // expected-error {{'swift_context' parameter must have pointer type; type here is 'int'}}
void SWIFTCALL;
void SWIFTCALL;
void SWIFTASYNCCALL;
void SWIFTASYNCCALL;
void ;
void SWIFTCALL; // expected-error {{'swift_async_context' parameter must have pointer type; type here is 'int'}}
void ASYNC_CONTEXT SWIFTCALL; // expected-warning {{'swift_async_context' attribute only applies to parameters}}
void SWIFTCALL; // expected-error {{'swift_async_context' attribute takes no arguments}}
void SWIFTCALL;
void SWIFTCALL;