]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/module/ImportDeclaration.java
Removed extra modules OntologyModule imported to namespace
[simantics/platform.git] / bundles / org.simantics.scl.compiler / src / org / simantics / scl / compiler / module / ImportDeclaration.java
index 21d7104051b133957c17b813a1a2a778ac2334f3..8fe903f515ff18b3d5e7d29bcec08399621d47f5 100644 (file)
@@ -53,6 +53,11 @@ public class ImportDeclaration extends DeclarationAst {
         this.spec = DEFAULT_SPEC;
     }
     
+    public ImportDeclaration(long location, String moduleName, String localName, boolean reexport, ImportSpec spec) {
+        this(moduleName, localName, reexport);
+        this.location = location;
+    }
+    
     public ImportDeclaration(String moduleName, String localName, boolean reexport, ImportSpec spec) {
         if(spec == null)
             throw new NullPointerException();
@@ -117,6 +122,10 @@ public class ImportDeclaration extends DeclarationAst {
         if (reexport != other.reexport)
             return false;
         return true;
+    }
+
+    public ImportDeclaration hidden() {
+        return new ImportDeclaration(moduleName, null);
     }    
     
 }