]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/compilation/CodeGeneration.java
(refs #7278, refs #7279) Small fixes to InternalCompilerExceptions
[simantics/platform.git] / bundles / org.simantics.scl.compiler / src / org / simantics / scl / compiler / compilation / CodeGeneration.java
index 5d258dd9e2b819c9d2ea4576718c65522586c384..68c5847082d96e7f1db80a1a83f9d4d2d9bcdbb7 100644 (file)
@@ -160,7 +160,7 @@ public class CodeGeneration {
                     continue;
      
                 DecomposedExpression decomposed = 
-                        DecomposedExpression.decompose(expression);
+                        DecomposedExpression.decompose(errorLog, expression);
     
                 CodeWriter w = mw.createFunction((SCLConstant)value.getValue(),
                         decomposed.typeParameters,
@@ -172,7 +172,7 @@ public class CodeGeneration {
                 IVal[] parameterVals = w.getParameters();
                 for(int i=0;i<decomposed.parameters.length;++i)
                     decomposed.parameters[i].setVal(parameterVals[i]);
-                w.return_(decomposed.body.toVal(compilationContext.environment, w));            
+                w.return_(decomposed.body.toVal(compilationContext, w));            
             } catch(RuntimeException e) {
                 long location = value.getExpression().location;
                 if(location == Locations.NO_LOCATION)