[PATCH] D136712: Define _GNU_SOURCE for arm baremetal in C++ mode.
Fangrui Song via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Oct 28 14:54:31 PDT 2022
MaskRay added a comment.
The `_GNU_SOURCE` definition needs to be guarded by `if (Opts.CPlusPlus)`.
================
Comment at: clang/test/Driver/arm-baremetal-defines.cpp:1
+// RUN: %clang --target=arm-none-eabi -march=armv7-m %s -emit-llvm -S -c -o - 2>&1 | FileCheck %s
+
----------------
Move this to `test/Preprocessor/init-arm.c`
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D136712/new/
https://reviews.llvm.org/D136712
More information about the cfe-commits
mailing list