1 package org.simantics.scl.compiler.elaboration.expressions.block;
3 import org.simantics.scl.compiler.elaboration.contexts.EnvironmentalContext;
4 import org.simantics.scl.compiler.elaboration.contexts.TranslationContext;
5 import org.simantics.scl.compiler.elaboration.expressions.Expression;
6 import org.simantics.scl.compiler.errors.Locations;
7 import org.simantics.scl.compiler.internal.parsing.Token;
8 import org.simantics.scl.compiler.internal.parsing.types.TypeAst;
10 public class ConstraintStatement extends Statement {
13 public TypeAst[] parameterTypes;
15 public ConstraintStatement(Token name, TypeAst[] parameterTypes) {
17 this.parameterTypes = parameterTypes;
21 public void setLocationDeep(long loc) {
22 if(location == Locations.NO_LOCATION) {
24 for(TypeAst parameterType : parameterTypes)
25 if(parameterType.location == Locations.NO_LOCATION)
26 parameterType.location = location;
31 public Expression toExpression(EnvironmentalContext context, boolean monadic, Expression in) {
32 throw new UnsupportedOperationException();
36 public void resolvePattern(TranslationContext context) {
37 throw new UnsupportedOperationException();
41 public boolean mayBeRecursive() {
42 throw new UnsupportedOperationException();
46 public void accept(StatementVisitor visitor) {
47 throw new UnsupportedOperationException();
51 public StatementGroup getStatementGroup() {
52 return StatementGroup.CHR;