compnerd added inline comments.
================ Comment at: clang/lib/Headers/stdatomic.h:21 +#if __STDC_HOSTED__ && __has_include_next(<stdatomic.h>) \ + && !(defined(_MSC_VER) && __cplusplus-0 < 202002l) # include_next <stdatomic.h> ---------------- Mordante wrote: > Is `__cplusplus-0` intentional? If so please add some comments how this > differs from `__cplusplus`. > Since this is a C header we should test whether the macro exists before > querying its value. Yes, that is intentional. The `-0` is a trick! That avoids the need to check for the definition, because it will be evaluated to as the value of `__cplusplus` or be `0` due to the expansion to CPP rules and `-0`. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139266/new/ https://reviews.llvm.org/D139266 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits