[clang] [Draft][Clang][HIP] Guard declarations of `cmath` comparisons when using Microsoft's STL (PR #200395)
Juan Manuel Martinez CaamaƱo via cfe-commits
cfe-commits at lists.llvm.org
Mon Jun 1 06:38:04 PDT 2026
jmmartinez wrote:
Thanks a lot for the comments!
In the last version of this patch I've addressed several mistakes that I'd made:
* Originally I put the fix in the `_cuda_` version of the header instead of its `_hip_` counterpart. In the last version I fixed this.
* I reduced the scope of the builtins to cover only these 6 builtins: isunordered, isgreater, isgreaterequal, isless, islessequal, islessgreater. It seems that only these got the `constexpr` while the other builtins use the `_CONSTEXPR23` macro. I'm going to create an issue on the STL to ask for clarification seems the unconditional constexpr on these builtins seems to go against the standard (we still have to address the `__cpp_lib_constexpr_cmath`).
* Used `__has_include(<version>)`
* Added a test
https://github.com/llvm/llvm-project/pull/200395
More information about the cfe-commits
mailing list