From 83283b0d6a1e714def620a2ad2a7166c6c3a0147 Mon Sep 17 00:00:00 2001 From: hallgren Date: Mon, 9 Sep 2013 14:29:57 +0000 Subject: Fix an old name shadowing bug in concrete syntax by removing the refresh pass The refresh pass does not correctly keep track of the scope of local variables and can convert things like \x->(\x->x) x into \x1->(\x2->x2) x2. Fortunately, it appears that the refresh pass is not needed anymore, so it has been removed. --- src/compiler/GF/Compile.hs | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src/compiler/GF/Compile.hs') diff --git a/src/compiler/GF/Compile.hs b/src/compiler/GF/Compile.hs index 9463abcc0..67fd750a2 100644 --- a/src/compiler/GF/Compile.hs +++ b/src/compiler/GF/Compile.hs @@ -12,7 +12,7 @@ import GF.Compile.GeneratePMCFG import GF.Compile.GrammarToPGF import GF.Compile.ReadFiles import GF.Compile.Update -import GF.Compile.Refresh +--import GF.Compile.Refresh import GF.Compile.Coding import GF.Compile.Tags @@ -196,8 +196,10 @@ compileSourceModule opts env@(k,gr,_) mb_gfFile mo@(i,mi) = do if tagsFlag then generateTags k mo3 else compileCompleteModule k mo3 where compileCompleteModule k mo3 = do - (k',mo3r:_) <- runPass2 (head.snd) Refresh "refreshing" $ - refreshModule (k,gr) mo3 +-- (k',mo3r:_) <- runPass2 (head.snd) Refresh "refreshing" $ +-- refreshModule (k,gr) mo3 + let k' = k + mo3r = mo3 mo4 <- runPass2 id Optimize "optimizing" $ optimizeModule opts gr mo3r mo5 <- if isModCnc (snd mo4) && flag optPMCFG opts then runPass2' "generating PMCFG" $ generatePMCFG opts gr mb_gfFile mo4 -- cgit v1.2.3