We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents c6be728 + adb56f3 commit 4710633Copy full SHA for 4710633
lib/IDE/ExprContextAnalysis.cpp
@@ -645,7 +645,8 @@ class ExprContextAnalyzer {
645
}
646
case ExprKind::If: {
647
auto *IE = cast<IfExpr>(Parent);
648
- if (SM.rangeContains(IE->getCondExpr()->getSourceRange(),
+ if (IE->isFolded() &&
649
+ SM.rangeContains(IE->getCondExpr()->getSourceRange(),
650
ParsedExpr->getSourceRange())) {
651
recordPossibleType(Context.getBoolDecl()->getDeclaredInterfaceType());
652
break;
0 commit comments