From a72d95b0d0ca093594315175bfd073dabbb82b1c Mon Sep 17 00:00:00 2001 From: Jan Gruteser <jan.gruteser@hhu.de> Date: Thu, 2 Jan 2025 10:03:45 +0100 Subject: [PATCH] make UsedExternalFunctions local in BAstCreator --- src/main/java/de/tla2bAst/BAstCreator.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/main/java/de/tla2bAst/BAstCreator.java b/src/main/java/de/tla2bAst/BAstCreator.java index 4e2b110..7f144c7 100644 --- a/src/main/java/de/tla2bAst/BAstCreator.java +++ b/src/main/java/de/tla2bAst/BAstCreator.java @@ -38,7 +38,6 @@ public class BAstCreator extends BuiltInOPs implements TranslationGlobals, BBuil private List<OpDeclNode> bConstants; private final ModuleNode moduleNode; - private UsedExternalFunctions usedExternalFunctions; private final Definitions bDefinitions = new Definitions(); @@ -90,7 +89,6 @@ public class BAstCreator extends BuiltInOPs implements TranslationGlobals, BBuil this.moduleNode = moduleNode; this.specAnalyser = specAnalyser; - this.usedExternalFunctions = new UsedExternalFunctions(moduleNode, specAnalyser); this.predicateVsExpression = new PredicateVsExpression(moduleNode); this.bMacroHandler = new BMacroHandler(specAnalyser, conEval); this.recursiveFunctionHandler = new RecursiveFunctionHandler(specAnalyser); @@ -175,7 +173,7 @@ public class BAstCreator extends BuiltInOPs implements TranslationGlobals, BBuil } } - Set<EXTERNAL_FUNCTIONS> set = usedExternalFunctions.getUsedExternalFunctions(); + Set<EXTERNAL_FUNCTIONS> set = new UsedExternalFunctions(moduleNode, specAnalyser).getUsedExternalFunctions(); List<PDefinition> defs = new ArrayList<>(createDefinitionsForExternalFunctions(set)); for (OpDefNode opDefNode : bDefs) { -- GitLab