From b51bcaf2f027f0774749e31d5fff2e618b1ee0f2 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Fri, 7 Apr 2017 15:13:47 +0000 Subject: Sema: prevent __declspec(naked) use on x64 MSDN (https://msdn.microsoft.com/en-us/library/h5w10wxs.aspx) indicates that `__declspec(naked)` is only permitted on x86 and ARM targets. Testing with cl does confirm this behaviour. Provide a warning for use of `__declspec(naked)` on x64. llvm-svn: 299774 --- clang/test/Sema/ms-inline-asm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clang/test/Sema/ms-inline-asm.c') diff --git a/clang/test/Sema/ms-inline-asm.c b/clang/test/Sema/ms-inline-asm.c index abf10b67cce..952112ea8cf 100644 --- a/clang/test/Sema/ms-inline-asm.c +++ b/clang/test/Sema/ms-inline-asm.c @@ -1,5 +1,5 @@ // REQUIRES: x86-registered-target -// RUN: %clang_cc1 %s -triple x86_64-apple-darwin10 -fms-extensions -fasm-blocks -Wno-microsoft -Wunused-label -verify -fsyntax-only +// RUN: %clang_cc1 %s -triple i386-apple-darwin10 -fms-extensions -fasm-blocks -Wno-microsoft -Wunused-label -verify -fsyntax-only void t1(void) { __asm __asm // expected-error {{__asm used with no assembly instructions}} -- cgit v1.2.3