[clang] [clang][AST] Outline constant-interpreter shift diagnostics (PR #202633)

Timm Baeder via cfe-commits cfe-commits at lists.llvm.org
Thu Jul 2 23:05:07 PDT 2026


================
@@ -147,25 +148,33 @@ bool CheckDynamicCast(InterpState &S, CodePtr OpPC);
 
 enum class ShiftDir { Left, Right };
 
+enum class ShiftFailure {
+  NegativeCount,
+  TooLarge,
+  NegativeLeftOperand,
+  DiscardsBits,
+};
+
+LLVM_ATTRIBUTE_NOINLINE bool DiagnoseShiftFailure(InterpState &S, CodePtr OpPC,
----------------
tbaederr wrote:

```suggestion
LLVM_ATTRIBUTE_NOINLINE bool ciagnoseShiftFailure(InterpState &S, CodePtr OpPC,
```

https://github.com/llvm/llvm-project/pull/202633


More information about the cfe-commits mailing list