diff --git a/compiler/frontend/src/org/jetbrains/jet/lang/psi/JetPsiFactory.java b/compiler/frontend/src/org/jetbrains/jet/lang/psi/JetPsiFactory.java index 46e1c2dd818..dcf879db749 100644 --- a/compiler/frontend/src/org/jetbrains/jet/lang/psi/JetPsiFactory.java +++ b/compiler/frontend/src/org/jetbrains/jet/lang/psi/JetPsiFactory.java @@ -296,9 +296,7 @@ public class JetPsiFactory { assert ifExpr.getCondition() != null; assert ifExpr.getThen() != null; - if (elseExpr != null) { - assert ifExpr.getElse() != null; - } + assert elseExpr == null || ifExpr.getElse() != null; ifExpr = (JetIfExpression)ifExpr.getCondition().replace(condition).getParent().getParent(); ifExpr = (JetIfExpression)ifExpr.getThen().replace(thenExpr).getParent().getParent();