From: David Majnemer Date: Thu, 8 Oct 2015 06:31:22 +0000 (+0000) Subject: Update tests touched by r249656 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=7006f5216c2f83d99b5df41201f0e809f562aec2;p=clang Update tests touched by r249656 These test updates almost exclusively around the change in behavior around enum: enums without a definition are considered incomplete except when targeting MSVC ABIs. Since these tests are interested in the 'incomplete-enum' behavior, restrict them to %itanium_abi_triple. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@249660 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/ASTMerge/codegen-exprs.c b/test/ASTMerge/codegen-exprs.c index 6c4a575d60..b5069f993b 100644 --- a/test/ASTMerge/codegen-exprs.c +++ b/test/ASTMerge/codegen-exprs.c @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -emit-pch -o %t.1.ast %S/Inputs/exprs1.c -// RUN: %clang_cc1 -emit-pch -o %t.2.ast %S/Inputs/exprs2.c -// RUN: %clang_cc1 -emit-obj -o /dev/null -ast-merge %t.1.ast -ast-merge %t.2.ast -fsyntax-only -verify %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -emit-pch -o %t.1.ast %S/Inputs/exprs1.c +// RUN: %clang_cc1 -triple %itanium_abi_triple -emit-pch -o %t.2.ast %S/Inputs/exprs2.c +// RUN: %clang_cc1 -triple %itanium_abi_triple -emit-obj -o /dev/null -ast-merge %t.1.ast -ast-merge %t.2.ast -fsyntax-only -verify %s // expected-no-diagnostics diff --git a/test/ASTMerge/exprs.c b/test/ASTMerge/exprs.c index c82e6831f5..7495bb6a87 100644 --- a/test/ASTMerge/exprs.c +++ b/test/ASTMerge/exprs.c @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -emit-pch -o %t.1.ast %S/Inputs/exprs1.c -// RUN: %clang_cc1 -emit-pch -o %t.2.ast %S/Inputs/exprs2.c -// RUN: %clang_cc1 -ast-merge %t.1.ast -ast-merge %t.2.ast -fsyntax-only -verify %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -emit-pch -o %t.1.ast %S/Inputs/exprs1.c +// RUN: %clang_cc1 -triple %itanium_abi_triple -emit-pch -o %t.2.ast %S/Inputs/exprs2.c +// RUN: %clang_cc1 -triple %itanium_abi_triple -ast-merge %t.1.ast -ast-merge %t.2.ast -fsyntax-only -verify %s // expected-no-diagnostics diff --git a/test/Analysis/PR2599.m b/test/Analysis/PR2599.m index fb368e33f1..47dadbf889 100644 --- a/test/Analysis/PR2599.m +++ b/test/Analysis/PR2599.m @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount,alpha.core -analyzer-constraints=range -analyzer-store=region -fobjc-gc -verify %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -analyze -analyzer-checker=core,osx.cocoa.RetainCount,alpha.core -analyzer-constraints=range -analyzer-store=region -fobjc-gc -verify %s typedef const void * CFTypeRef; typedef const struct __CFString * CFStringRef; diff --git a/test/Analysis/retain-release-gc-only.m b/test/Analysis/retain-release-gc-only.m index 1a5ed34c9f..26eb6e12be 100644 --- a/test/Analysis/retain-release-gc-only.m +++ b/test/Analysis/retain-release-gc-only.m @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount,osx.cocoa.NSAutoreleasePool -analyzer-store=region -fobjc-gc-only -fblocks -verify -Wno-objc-root-class %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -analyze -analyzer-checker=core,osx.cocoa.RetainCount,osx.cocoa.NSAutoreleasePool -analyzer-store=region -fobjc-gc-only -fblocks -verify -Wno-objc-root-class %s //===----------------------------------------------------------------------===// // Header stuff. diff --git a/test/Analysis/retain-release-region-store.m b/test/Analysis/retain-release-region-store.m index 917381341a..3f83fb5828 100644 --- a/test/Analysis/retain-release-region-store.m +++ b/test/Analysis/retain-release-region-store.m @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount -analyzer-store=region -analyzer-max-loop 6 -verify %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -analyze -analyzer-checker=core,osx.cocoa.RetainCount -analyzer-store=region -analyzer-max-loop 6 -verify %s //===----------------------------------------------------------------------===// // The following code is reduced using delta-debugging from diff --git a/test/CXX/drs/dr0xx.cpp b/test/CXX/drs/dr0xx.cpp index dd0d4d17a8..3bb6701b32 100644 --- a/test/CXX/drs/dr0xx.cpp +++ b/test/CXX/drs/dr0xx.cpp @@ -1,7 +1,7 @@ // RUN: %clang_cc1 -std=c++98 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -Wno-bind-to-temporary-copy -// RUN: %clang_cc1 -std=c++11 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -// RUN: %clang_cc1 -std=c++14 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -// RUN: %clang_cc1 -std=c++1z %s -verify -fexceptions -fcxx-exceptions -pedantic-errors +// RUN: %clang_cc1 -std=c++11 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -triple %itanium_abi_triple +// RUN: %clang_cc1 -std=c++14 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -triple %itanium_abi_triple +// RUN: %clang_cc1 -std=c++1z %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -triple %itanium_abi_triple namespace dr1 { // dr1: no namespace X { extern "C" void dr1_f(int a = 1); } diff --git a/test/CXX/drs/dr3xx.cpp b/test/CXX/drs/dr3xx.cpp index c438fccebd..a1c1c4ce61 100644 --- a/test/CXX/drs/dr3xx.cpp +++ b/test/CXX/drs/dr3xx.cpp @@ -1,7 +1,7 @@ -// RUN: %clang_cc1 -std=c++98 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -// RUN: %clang_cc1 -std=c++11 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -// RUN: %clang_cc1 -std=c++14 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors -// RUN: %clang_cc1 -std=c++1z %s -verify -fexceptions -fcxx-exceptions -pedantic-errors +// RUN: %clang_cc1 -triple %itanium_abi_triple -std=c++98 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors +// RUN: %clang_cc1 -triple %itanium_abi_triple -std=c++11 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors +// RUN: %clang_cc1 -triple %itanium_abi_triple -std=c++14 %s -verify -fexceptions -fcxx-exceptions -pedantic-errors +// RUN: %clang_cc1 -triple %itanium_abi_triple -std=c++1z %s -verify -fexceptions -fcxx-exceptions -pedantic-errors namespace dr300 { // dr300: yes template void f(R (&)(A)) {} diff --git a/test/CXX/drs/dr4xx.cpp b/test/CXX/drs/dr4xx.cpp index bbe5ee6faa..2a548e2eab 100644 --- a/test/CXX/drs/dr4xx.cpp +++ b/test/CXX/drs/dr4xx.cpp @@ -659,7 +659,7 @@ namespace dr457 { // dr457: yes enum E { ea = a, - eb = b // expected-error {{not an integral constant}} expected-note {{read of volatile-qualified}} + eb = b // expected-error {{constant}} expected-note {{read of volatile-qualified}} }; } diff --git a/test/CXX/expr/expr.const/p5-0x.cpp b/test/CXX/expr/expr.const/p5-0x.cpp index 0a4ac22d06..079870947d 100644 --- a/test/CXX/expr/expr.const/p5-0x.cpp +++ b/test/CXX/expr/expr.const/p5-0x.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -fsyntax-only -std=c++11 -verify %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -fsyntax-only -std=c++11 -verify %s // If an expression of literal class type is used in a context where an integral // constant expression is required, then that class type shall have a single diff --git a/test/CodeGen/2003-12-14-ExternInlineSupport.c b/test/CodeGen/2003-12-14-ExternInlineSupport.c index eb3859c380..cf01fd1ecb 100644 --- a/test/CodeGen/2003-12-14-ExternInlineSupport.c +++ b/test/CodeGen/2003-12-14-ExternInlineSupport.c @@ -1,3 +1,4 @@ -// RUN: %clang_cc1 -std=gnu89 %s -emit-llvm -o - | not grep dead_function +// RUN: %clang_cc1 -triple %itanium_abi_triple -std=gnu89 %s -emit-llvm -o - | FileCheck %s extern __inline__ void dead_function() {} +// CHECK-NOT: dead_function diff --git a/test/CodeGen/volatile-1.c b/test/CodeGen/volatile-1.c index f63274b37f..6912da3d93 100644 --- a/test/CodeGen/volatile-1.c +++ b/test/CodeGen/volatile-1.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -Wno-return-type -Wno-unused-value -emit-llvm %s -o - | FileCheck %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -Wno-return-type -Wno-unused-value -emit-llvm %s -o - | FileCheck %s // CHECK: @i = common global [[INT:i[0-9]+]] 0 volatile int i, j, k; diff --git a/test/CodeGenCXX/inline-dllexport-member.cpp b/test/CodeGenCXX/inline-dllexport-member.cpp index fa78d06800..2160f32e0b 100644 --- a/test/CodeGenCXX/inline-dllexport-member.cpp +++ b/test/CodeGenCXX/inline-dllexport-member.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -triple i686-windows-gnu -fms-compatibility -debug-info-kind=limited -emit-llvm %s -o - \ +// RUN: %clang_cc1 -triple i686-windows-win32 -fms-extensions -debug-info-kind=limited -emit-llvm %s -o - \ // RUN: | FileCheck %s struct __declspec(dllexport) s { @@ -6,6 +6,6 @@ struct __declspec(dllexport) s { }; // CHECK: ![[SCOPE:[0-9]+]] = distinct !DICompileUnit( -// CHECK: !DIGlobalVariable(name: "ui", linkageName: "_ZN1s2uiE", scope: ![[SCOPE]], -// CHECK-SAME: variable: i32* @_ZN1s2uiE +// CHECK: !DIGlobalVariable(name: "ui", linkageName: "\01?ui@s@@2IB", scope: ![[SCOPE]], +// CHECK-SAME: variable: i32* @"\01?ui@s@@2IB" diff --git a/test/FixIt/format.m b/test/FixIt/format.m index d07ee363b4..7af2cfdaf7 100644 --- a/test/FixIt/format.m +++ b/test/FixIt/format.m @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -fsyntax-only -fblocks -verify %s -// RUN: %clang_cc1 -fdiagnostics-parseable-fixits -fblocks %s 2>&1 | FileCheck %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -fsyntax-only -fblocks -verify %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -fdiagnostics-parseable-fixits -fblocks %s 2>&1 | FileCheck %s @class NSString; extern void NSLog(NSString *, ...); diff --git a/test/Modules/system_headers.m b/test/Modules/system_headers.m index 165e8e8664..b69ef3d3c9 100644 --- a/test/Modules/system_headers.m +++ b/test/Modules/system_headers.m @@ -1,7 +1,7 @@ // Test that system-headerness works for building modules. // RUN: rm -rf %t -// RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t/cache -isystem %S/Inputs -pedantic -Werror %s -verify -std=c11 +// RUN: %clang_cc1 -triple %itanium_abi_triple -fmodules -fimplicit-module-maps -fmodules-cache-path=%t/cache -isystem %S/Inputs -pedantic -Werror %s -verify -std=c11 // expected-no-diagnostics @import warning; diff --git a/test/Parser/cxx0x-attributes.cpp b/test/Parser/cxx0x-attributes.cpp index 7eec5761ea..d803812efd 100644 --- a/test/Parser/cxx0x-attributes.cpp +++ b/test/Parser/cxx0x-attributes.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -fcxx-exceptions -fexceptions -fsyntax-only -verify -std=c++11 -Wc++14-compat %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -fcxx-exceptions -fexceptions -fsyntax-only -verify -std=c++11 -Wc++14-compat %s // Need std::initializer_list namespace std { diff --git a/test/Sema/attr-flag-enum.c b/test/Sema/attr-flag-enum.c index a53c1dc8e7..ae3e3ad5ab 100644 --- a/test/Sema/attr-flag-enum.c +++ b/test/Sema/attr-flag-enum.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -verify -fsyntax-only -std=c11 -Wassign-enum %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -verify -fsyntax-only -std=c11 -Wassign-enum %s enum __attribute__((flag_enum)) flag { ea = 0x1, diff --git a/test/Sema/bitfield.c b/test/Sema/bitfield.c index ba8460d3f6..60a6fcf10a 100644 --- a/test/Sema/bitfield.c +++ b/test/Sema/bitfield.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 %s -fsyntax-only -verify -std=c11 -Wno-unused-value +// RUN: %clang_cc1 -triple %itanium_abi_triple %s -fsyntax-only -verify -std=c11 -Wno-unused-value enum e0; // expected-note{{forward declaration of 'enum e0'}} diff --git a/test/Sema/cast-incomplete.c b/test/Sema/cast-incomplete.c index dd10e00d44..ce20dfbf8b 100644 --- a/test/Sema/cast-incomplete.c +++ b/test/Sema/cast-incomplete.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -fsyntax-only %s -verify +// RUN: %clang_cc1 -triple %itanium_abi_triple -fsyntax-only %s -verify // PR5692 enum x; // expected-note {{forward declaration}} diff --git a/test/Sema/decl-in-prototype.c b/test/Sema/decl-in-prototype.c index 4f581aa54e..8cdbdf2fcd 100644 --- a/test/Sema/decl-in-prototype.c +++ b/test/Sema/decl-in-prototype.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -fsyntax-only -verify %s +// RUN: %clang_cc1 -triple %itanium_abi_triple -fsyntax-only -verify %s const int AA = 5; diff --git a/test/Sema/enum.c b/test/Sema/enum.c index 13b88c948c..3546bfe48f 100644 --- a/test/Sema/enum.c +++ b/test/Sema/enum.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 %s -fsyntax-only -verify -pedantic +// RUN: %clang_cc1 -triple %itanium_abi_triple %s -fsyntax-only -verify -pedantic enum e {A, B = 42LL << 32, // expected-warning {{ISO C restricts enumerator values to range of 'int'}} C = -4, D = 12456 };