]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/top/ExpressionEvaluator.java
Showing compilation warnings in SCL issue view and editors
[simantics/platform.git] / bundles / org.simantics.scl.compiler / src / org / simantics / scl / compiler / top / ExpressionEvaluator.java
index d87beec65a7380361a2c45961fa41c2c886b8c18..c1881fbca53acb2ffc20a21a01a4f4291ed77cb4 100644 (file)
@@ -253,7 +253,7 @@ public class ExpressionEvaluator {
         {
             TranslationContext context = new TranslationContext(compilationContext, localEnvironment);
             expression = expression.resolve(context);
-            if(!errorLog.isEmpty())
+            if(!errorLog.hasNoErrors())
                 throw new SCLExpressionCompilationException(errorLog.getErrors());
         }
         
@@ -278,7 +278,7 @@ public class ExpressionEvaluator {
             
             expectedType.addPolarity(Polarity.POSITIVE);
             context.solveSubsumptions(expression.location);
-            if(!errorLog.isEmpty())
+            if(!errorLog.hasNoErrors())
                 throw new SCLExpressionCompilationException(errorLog.getErrors());
             if(decorateExpression && Types.canonical(expectedEffect) != Types.NO_EFFECTS) {
                 ExpressionDecorator decorator =
@@ -288,7 +288,7 @@ public class ExpressionEvaluator {
             expression = context.solveConstraints(environment, expression);
             expressionType = expression.getType();
             
-            if(!errorLog.isEmpty())
+            if(!errorLog.hasNoErrors())
                 throw new SCLExpressionCompilationException(errorLog.getErrors());
 
             if(localEnvironment != null)
@@ -319,7 +319,7 @@ public class ExpressionEvaluator {
                 new SimplificationContext(compilationContext, DummyJavaReferenceValidator.INSTANCE);
         expression = expression.simplify(context);
         
-        if(!errorLog.isEmpty())
+        if(!errorLog.hasNoErrors())
             throw new SCLExpressionCompilationException(errorLog.getErrors());
         
         if(SCLCompilerConfiguration.SHOW_EXPRESSION_BEFORE_EVALUATION)