================
@@ -671,6 +684,10 @@ ExprResult Sema::ImpCastExprToType(Expr *E, QualType Ty,
diagnoseNullableToNonnullConversion(Ty, E->getType(), E->getBeginLoc());
diagnoseZeroToNullptrConversion(Kind, E);
+ if (!isCast(CCK) &&
+ !E->isNullPointerConstant(Context, Expr::NPC_ValueDependentIsNotNull)) {
----------------
dougsonos wrote:
This seems to be causing some failed tests. `isNullPointerConstant` calls
`Expr::EvaluateKnownConstInt` where this assertion fails:
```
assert(!isValueDependent() &&
"Expression evaluator can't be called on a dependent expression.");
```
https://github.com/llvm/llvm-project/pull/84983
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits