[flang-commits] [PATCH] D104779: [flang] Tweak the conditions for the GCC 7/libstdc++ workaround

Peter Klausler via Phabricator via flang-commits flang-commits at lists.llvm.org
Wed Jun 23 11:37:56 PDT 2021


klausler added inline comments.


================
Comment at: flang/include/flang/Evaluate/type.h:145
   constexpr std::optional<std::int64_t> knownLength() const {
-#if !__clang__ && __GNUC__ == 7
+#if defined(_GLIBCXX_RELEASE) && _GLIBCXX_RELEASE == 7
     if (knownLength_ < 0) {
----------------
mstorsjo wrote:
> klausler wrote:
> > You don't need to check whether _GLIBCXX_RELEASE is defined; if it is not, it'll be replaced with 0 and the test will fail anyway.
> Ok, although leaving out that check cause warnings if building with -Wundef.
Then please leave the check in place; we build f18 with -Werror.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D104779



More information about the flang-commits mailing list