]> granicus.if.org Git - clang/commitdiff
Make MS i128 suffix test from r211446 more robust
authorAlp Toker <alp@nuanti.com>
Sat, 21 Jun 2014 23:32:05 +0000 (23:32 +0000)
committerAlp Toker <alp@nuanti.com>
Sat, 21 Jun 2014 23:32:05 +0000 (23:32 +0000)
We want to catch both negative and positive failure conditions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211449 91177308-0d34-0410-b5e6-96231b3b80d8

test/Lexer/ms-extensions.c

index 183d48fde9f90671bef37b70b67ee6f833e67491..ebcf0f49998f4ef753d4707ea2abd749d4fa67c6 100644 (file)
@@ -1,14 +1,16 @@
 // RUN: %clang_cc1 -fsyntax-only -verify -fms-extensions %s
 // RUN: %clang_cc1 -fsyntax-only -verify -fms-compatibility %s
+// RUN: %clang_cc1 -fsyntax-only -verify -triple i386-pc-win32 -fms-compatibility %s
 
 __int8 x1  = 3i8;
 __int16 x2 = 4i16;
 __int32 x3 = 5i32;
 __int64 x5 = 0x42i64;
 __int64 x6 = 0x42I64;
-#ifdef __SIZEOF_INT128__
-__int64 x4 = 70000000i128;
+#ifndef __SIZEOF_INT128__
+// expected-error@+2 {{__int128 is not supported on this target}}
 #endif
+__int64 x4 = 70000000i128;
 
 __int64 y = 0x42i64u;  // expected-error {{invalid suffix}}
 __int64 w = 0x43ui64;