import org.simantics.scl.compiler.elaboration.expressions.ERecord;
import org.simantics.scl.compiler.elaboration.expressions.Expression;
import org.simantics.scl.compiler.elaboration.expressions.Variable;
-import org.simantics.scl.compiler.elaboration.expressions.VariableProcedure;
import org.simantics.scl.compiler.elaboration.expressions.printing.ExpressionToStringVisitor;
import org.simantics.scl.compiler.elaboration.expressions.records.FieldAssignment;
import org.simantics.scl.compiler.elaboration.relations.SCLRelation;
}
}
- public void collectRefs(TObjectIntHashMap<Object> allRefs, TIntHashSet refs) {
- for(Expression parameter : parameters)
- parameter.collectRefs(allRefs, refs);
- if(typeConstraintEvidenceParameters != null)
- for(Expression parameter : typeConstraintEvidenceParameters)
- parameter.collectRefs(allRefs, refs);
- }
-
public void checkType(TypingContext context) {
if(relation == SpecialCHRRelation.EXECUTE) {
if(parameters.length != 1)
parameter.collectVars(allVars, vars);
}
- public void forVariables(VariableProcedure procedure) {
- for(Expression parameter : parameters)
- parameter.forVariables(procedure);
- if(typeConstraintEvidenceParameters != null)
- for(Expression parameter : typeConstraintEvidenceParameters)
- parameter.forVariables(procedure);
- }
-
public void collectFreeVariables(THashSet<Variable> vars) {
if(relation == SpecialCHRRelation.ASSIGN) {
parameters[1].collectFreeVariables(vars);