From eb4bfb008e30f8c5f575116e44821dc7cb800201 Mon Sep 17 00:00:00 2001 From: "kr.angelov" Date: Tue, 28 Feb 2012 08:10:47 +0000 Subject: [PATCH] buf fix in the compiler for HOAS --- src/compiler/GF/Compile/GeneratePMCFG.hs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/compiler/GF/Compile/GeneratePMCFG.hs b/src/compiler/GF/Compile/GeneratePMCFG.hs index 4e008cdf7..175246a52 100644 --- a/src/compiler/GF/Compile/GeneratePMCFG.hs +++ b/src/compiler/GF/Compile/GeneratePMCFG.hs @@ -275,8 +275,11 @@ catFactor (PFCat _ f _) = f computeCatRange gr lincat = compute (0,1) lincat where - compute st (RecType rs) = let (st',rs') = List.mapAccumL (\st (lbl,t) -> let (st',t') = compute st t - in (st',(lbl,Identity t'))) st rs + compute st (RecType rs) = let (st',rs') = List.mapAccumL (\st (lbl,t) -> case lbl of + LVar _ -> let (st',t') = compute st t + in (st ,(lbl,Identity t')) + _ -> let (st',t') = compute st t + in (st',(lbl,Identity t'))) st rs in (st',CRec rs') compute st (Table pt vt) = let vs = err error id (allParamValues gr pt) (st',cs') = List.mapAccumL (\st v -> let (st',vt') = compute st vt