Blob Blame History Raw
From e38a64f24bd0acbc49b3b5148e03f5978e06b4a6 Mon Sep 17 00:00:00 2001
From: Brad King <brad.king@kitware.com>
Date: Wed, 25 Aug 2021 12:02:54 -0400
Subject: [PATCH] test: update for LLVM/Clang 13

Clang now defines more builtin macros that happen to be sorted among
macros we check in the tests.  Update the test expectations to account
for them.

Fixes: #204
---
 test/expect/cmd.cc-gnu-c-src-c-E.stdout.txt      | 1 +
 test/expect/cmd.cc-gnu-src-cxx-E.stdout.txt      | 1 +
 test/expect/cmd.cc-gnu-tgt-i386-opt-E.stdout.txt | 1 +
 test/expect/cmd.predefined-macros.stdout.txt.in  | 4 +++-
 4 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/test/expect/cmd.cc-gnu-c-src-c-E.stdout.txt b/test/expect/cmd.cc-gnu-c-src-c-E.stdout.txt
index b248fb8..f880d02 100644
--- a/test/expect/cmd.cc-gnu-c-src-c-E.stdout.txt
+++ b/test/expect/cmd.cc-gnu-c-src-c-E.stdout.txt
@@ -1,4 +1,5 @@
 ^(#define _WIN32 1
+)?(#define __GCC_HAVE_DWARF2_CFI_ASM 1
 )?#define __GNUC_MINOR__ 1
 #define __GNUC__ 1(
 #define __MINGW32__ 1)?
diff --git a/test/expect/cmd.cc-gnu-src-cxx-E.stdout.txt b/test/expect/cmd.cc-gnu-src-cxx-E.stdout.txt
index 1c7bf1f..24a3dad 100644
--- a/test/expect/cmd.cc-gnu-src-cxx-E.stdout.txt
+++ b/test/expect/cmd.cc-gnu-src-cxx-E.stdout.txt
@@ -1,4 +1,5 @@
 ^(#define _WIN32 1
+)?(#define __GCC_HAVE_DWARF2_CFI_ASM 1
 )?#define __GNUC_MINOR__ 1
 #define __GNUC__ 1(
 #define __MINGW32__ 1)?
diff --git a/test/expect/cmd.cc-gnu-tgt-i386-opt-E.stdout.txt b/test/expect/cmd.cc-gnu-tgt-i386-opt-E.stdout.txt
index 4e6d6d0..e13d358 100644
--- a/test/expect/cmd.cc-gnu-tgt-i386-opt-E.stdout.txt
+++ b/test/expect/cmd.cc-gnu-tgt-i386-opt-E.stdout.txt
@@ -1,4 +1,5 @@
 ^(#define _WIN32 1
+)?(#define __GCC_HAVE_DWARF2_CFI_ASM 1
 )?#define __GNUC_MINOR__ 1
 #define __GNUC__ 1(
 #define __MINGW32__ 1)?
diff --git a/test/expect/cmd.predefined-macros.stdout.txt.in b/test/expect/cmd.predefined-macros.stdout.txt.in
index b56fbdc..d7a5b2b 100644
--- a/test/expect/cmd.predefined-macros.stdout.txt.in
+++ b/test/expect/cmd.predefined-macros.stdout.txt.in
@@ -6,7 +6,9 @@
 #define __castxml_major__ @CastXML_VERSION_MAJOR@
 #define __castxml_minor__ @CastXML_VERSION_MINOR@
 #define __castxml_patch__ @CastXML_VERSION_PATCH@
-#define __clang__ 1
+#define __clang__ 1(
+#define __clang_literal_encoding__ [^
+]*)?
 #define __clang_major__ [0-9]+
 #define __clang_minor__ [0-9]+
 #define __clang_patchlevel__ [0-9]+
-- 
2.31.1