From bb322555afb4fb135abc48fbb3383b7216557995 Mon Sep 17 00:00:00 2001 From: Erich Keane Date: Mon, 11 Dec 2017 17:36:42 +0000 Subject: For Linux/gnu compatibility, preinclude if the file is available MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As reported in llvm bugzilla 32377. Here’s a patch to add preinclude of stdc-predef.h. The gcc documentation says “On GNU/Linux, is pre-included.” See https://gcc.gnu.org/gcc-4.8/porting_to.html; The preinclude is inhibited with –ffreestanding. Basically I fixed the failing test cases by adding –ffreestanding which inhibits this behavior. I fixed all the failing tests, including some in extra/test, there's a separate patch for that which is linked here Note: this is a recommit after a test failure took down the original (r318669) Patch By: mibintc Differential Revision: https://reviews.llvm.org/D34158 llvm-svn: 320391 --- clang/test/Index/c-index-getCursor-test.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'clang/test/Index/c-index-getCursor-test.m') diff --git a/clang/test/Index/c-index-getCursor-test.m b/clang/test/Index/c-index-getCursor-test.m index 2361af62ab7..d379904c800 100644 --- a/clang/test/Index/c-index-getCursor-test.m +++ b/clang/test/Index/c-index-getCursor-test.m @@ -1,5 +1,5 @@ -// RUN: c-index-test -write-pch %t.ast -arch x86_64 -mmacosx-version-min=10.6 -fblocks -x objective-c %s -// RUN: c-index-test -test-file-scan %t.ast %s > %t 2>&1 && FileCheck --input-file=%t %s +// RUN: c-index-test -write-pch %t.ast -arch x86_64 -mmacosx-version-min=10.6 -fblocks -x objective-c %s -ffreestanding +// RUN: c-index-test -test-file-scan %t.ast %s -ffreestanding > %t 2>&1 && FileCheck --input-file=%t %s @interface Foo { } -- cgit v1.2.3