From: Pavel Labath Date: Fri, 26 Jul 2013 12:50:30 +0000 (+0000) Subject: Fix tests on targets that don't support thread_local X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=99b3cc6ec4fbcd887b632dcb7147ef472d83fc37;p=clang Fix tests on targets that don't support thread_local This also reverts r187197. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@187199 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/Analysis/temporaries.cpp b/test/Analysis/temporaries.cpp index d7122706f4..ea4abb2d84 100644 --- a/test/Analysis/temporaries.cpp +++ b/test/Analysis/temporaries.cpp @@ -1,5 +1,5 @@ // RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -verify -w -std=c++03 %s -// RUN: %clang_cc1 -triple x86_64-pc-linux -analyze -analyzer-checker=core,debug.ExprInspection -verify -w -std=c++11 %s +// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -verify -w -std=c++11 %s extern bool clang_analyzer_eval(bool); @@ -149,7 +149,7 @@ void testStaticMaterializeTemporaryExpr() { static const Trivial &directRef = Trivial(42); clang_analyzer_eval(directRef.value == 42); // expected-warning{{TRUE}} -#if __cplusplus >= 201103L +#if __has_feature(cxx_thread_local) thread_local static const Trivial &threadRef = getTrivial(); clang_analyzer_eval(threadRef.value == 42); // expected-warning{{TRUE}}