Open
Description
#if 1 ? 1, 0: 3
#error
#endif
clang -E --std=c++23 --pedantic-errors /tmp/bug.cpp gives:
tmp/bug.cpp:1:10: error: comma operator in operand of #if [-Werror,-Wpedantic]
1 | #if 1 ? 1, 0: 3
| ~^ ~
1 error generated.
I believe that the comma operator has been permitted in constant expressions in C++ since about C++11. If true, this should be accepted.