
This brings our tree to NetBSD 7.0, as found on -current on the 10-10-2015. This updates: - LLVM to 3.6.1 - GCC to GCC 5.1 - Replace minix/commands/zdump with usr.bin/zdump - external/bsd/libelf has moved to /external/bsd/elftoolchain/ - Import ctwm - Drop sprintf from libminc Change-Id: I149836ac18e9326be9353958bab9b266efb056f0
19 lines
649 B
C
19 lines
649 B
C
// RUN: %clang_cc1 -triple i386-mingw32 -fms-extensions -fsyntax-only -verify %s
|
|
// RUN: %clang_cc1 -triple x86_64-unknown-unknown -fsyntax-only -verify %s
|
|
|
|
int foo(int *a, int i) {
|
|
#ifdef _MSC_VER
|
|
__assume(i != 4);
|
|
__assume(++i > 2); //expected-warning {{the argument to '__assume' has side effects that will be discarded}}
|
|
|
|
int test = sizeof(struct{char qq[(__assume(i != 5), 7)];});
|
|
#else
|
|
__builtin_assume(i != 4);
|
|
__builtin_assume(++i > 2); //expected-warning {{the argument to '__builtin_assume' has side effects that will be discarded}}
|
|
|
|
int test = sizeof(struct{char qq[(__builtin_assume(i != 5), 7)];});
|
|
#endif
|
|
return a[i];
|
|
}
|
|
|