[PATCH] D103587: [AIX] Transfer predefined macros

Chris Bowler via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 3 14:29:17 PDT 2021


cebowleratibm added inline comments.


================
Comment at: clang/lib/Basic/Targets/OSTargets.h:680
+
+    if (Opts.LangStd == LangStandard::lang_c11 ||
+        Opts.LangStd == LangStandard::lang_gnu11 ||
----------------
I think LangStandard::isC11() does what you want.  You wouldn't want to update this code every time a new C standard comes out.


================
Comment at: clang/test/Preprocessor/init-ppc.c:742
+
+// RUN: %clang_cc1 -x c -std=c89 -E -dM -ffreestanding -triple=powerpc-ibm-aix7.1.0.0 -fno-signed-char < /dev/null | FileCheck -match-full-lines -check-prefix PPC-AIX-STDC-N %s
+// RUN: %clang_cc1 -x c -std=c90 -E -dM -ffreestanding -triple=powerpc-ibm-aix7.1.0.0 -fno-signed-char < /dev/null | FileCheck -match-full-lines -check-prefix PPC-AIX-STDC-N %s
----------------
I didn't mean to suggest adding all of them.  One negative test on c99 would suffice.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D103587/new/

https://reviews.llvm.org/D103587



More information about the cfe-commits mailing list