From f87daa26cae8f59373fe4a198a9858110901244e Mon Sep 17 00:00:00 2001 From: paulklint Date: Mon, 11 Nov 2024 11:06:04 +0100 Subject: [PATCH] Reverted change --- .../library/lang/rascalcore/check/CheckerCommon.rsc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/org/rascalmpl/core/library/lang/rascalcore/check/CheckerCommon.rsc b/src/org/rascalmpl/core/library/lang/rascalcore/check/CheckerCommon.rsc index e9eb0087..ffc4b2ad 100644 --- a/src/org/rascalmpl/core/library/lang/rascalcore/check/CheckerCommon.rsc +++ b/src/org/rascalmpl/core/library/lang/rascalcore/check/CheckerCommon.rsc @@ -247,11 +247,13 @@ ModuleStatus addTModel (str qualifiedModuleName, TModel tm, ModuleStatus ms){ private type[TModel] ReifiedTModel = #TModel; // precomputed for efficiency -tuple[bool, TModel, ModuleStatus] getTModelForModule(str qualifiedModuleName, ModuleStatus ms, bool convert2physical=false){ +tuple[bool, TModel, ModuleStatus] getTModelForModule(str qualifiedModuleName, ModuleStatus ms){ if(traceTModelCache) println("getTModelForModule: "); pcfg = ms.pathConfig; if(ms.tmodels[qualifiedModuleName]?){ - return ; + tm = convertTModel2PhysicalLocs(ms.tmodels[qualifiedModuleName]); + ms.tmodels[qualifiedModuleName] = tm; + return ; } while(size(ms.tmodels) >= tmodelCacheSize && size(ms.tmodelLIFO) > 0 && ms.tmodelLIFO[-1] != qualifiedModuleName){ ms = removeOldestTModelFromCache(ms); @@ -264,9 +266,7 @@ tuple[bool, TModel, ModuleStatus] getTModelForModule(str qualifiedModuleName, Mo tm = readBinaryValueFile(ReifiedTModel, tplLoc); if(tm.rascalTplVersion? && isValidRascalTplVersion(tm.rascalTplVersion)){ tm.usesPhysicalLocs = false; // temporary - if(convert2physical){ - tm = convertTModel2PhysicalLocs(tm); - } + tm = convertTModel2PhysicalLocs(tm); ms.tmodels[qualifiedModuleName] = tm; mloc = getModuleLocation(qualifiedModuleName, pcfg); if(isModuleLocationInLibs(qualifiedModuleName, mloc, pcfg)){