[clang] [clang] Allow C-style casts in constexpr in MS compatible mode (PR #197005)
Shafik Yaghmour via cfe-commits
cfe-commits at lists.llvm.org
Tue Jun 2 22:18:48 PDT 2026
================
@@ -18,6 +18,23 @@ using namespace clang::interp;
State::~State() {}
+// With -fms-compatibility we allow pointer to integer casts
+// followed by nullptr casts.
+void State::clearDiagIfNeeded(diag::kind DiagId) {
----------------
shafik wrote:
The mechanics of this feel pretty mysterious to me, can you add some more comments, explaining how it accomplishes the intent commented above.
https://github.com/llvm/llvm-project/pull/197005
More information about the cfe-commits
mailing list