X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.scl.compiler%2Fsrc%2Forg%2Fsimantics%2Fscl%2Fcompiler%2Felaboration%2Fexpressions%2FEExternalConstant.java;h=0b5678f99eb15a9995e23ca7f5c6c82cd0493690;hp=611e96d368ea3fa33c939b18d575fa5b061b3c6c;hb=a9f88c57e622d9ecf2732bd0278e0989dc0dfd5a;hpb=2f63e7a58e49a233b28c6968b848281060117c43 diff --git a/bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/elaboration/expressions/EExternalConstant.java b/bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/elaboration/expressions/EExternalConstant.java index 611e96d36..0b5678f99 100644 --- a/bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/elaboration/expressions/EExternalConstant.java +++ b/bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/elaboration/expressions/EExternalConstant.java @@ -35,27 +35,24 @@ public class EExternalConstant extends Expression { return value; } - public void collectRefs(TObjectIntHashMap allRefs, TIntHashSet refs) { + @Override + public void collectVars(TObjectIntHashMap allVars, + TIntHashSet vars) { } - @Override - public void collectVars(TObjectIntHashMap allVars, - TIntHashSet vars) { - } - - public void toString(StringBuilder b, TypeUnparsingContext tuc) { + public void toString(StringBuilder b, TypeUnparsingContext tuc) { b.append(value); } - @Override - protected void updateType() throws MatchException { - throw new InternalCompilerError("EExternalConstants must have explicitly defined type."); - } - - @Override - public IVal toVal(CompilationContext context, CodeWriter w) { - ModuleWriter mw = w.getModuleWriter(); - return mw.getExternalConstant(value, getType()); + @Override + protected void updateType() throws MatchException { + throw new InternalCompilerError("EExternalConstants must have explicitly defined type."); + } + + @Override + public IVal toVal(CompilationContext context, CodeWriter w) { + ModuleWriter mw = w.getModuleWriter(); + return mw.getExternalConstant(value, getType()); } @Override