summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Compile/Compute
diff options
context:
space:
mode:
authorhallgren <hallgren@chalmers.se>2014-05-16 21:27:20 +0000
committerhallgren <hallgren@chalmers.se>2014-05-16 21:27:20 +0000
commit1bba23991f725b42494b68bd44cd4729088d825d (patch)
tree41b3468d679b78974daab9b1d731ee9df09416f1 /src/compiler/GF/Compile/Compute
parent307795f3853b7b5772ff0c190e7e054ac64bd777 (diff)
Compute/ConcreteNew.hs: adding a Prawitz rewrite
(table { p_i => t_i } ! x).l ==> table { p_i => t_i.l } ! x This was used in the old partial evaluator and can significantly reduce term sizes in some cases.
Diffstat (limited to 'src/compiler/GF/Compile/Compute')
-rw-r--r--src/compiler/GF/Compile/Compute/ConcreteNew.hs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/compiler/GF/Compile/Compute/ConcreteNew.hs b/src/compiler/GF/Compile/Compute/ConcreteNew.hs
index 1b5559808..181d48830 100644
--- a/src/compiler/GF/Compile/Compute/ConcreteNew.hs
+++ b/src/compiler/GF/Compile/Compute/ConcreteNew.hs
@@ -180,6 +180,7 @@ proj l v =
VFV vs -> liftM vfv (mapM (proj l) vs)
VRec rs -> lookup l rs
VExtR v1 v2 -> proj l v2 `mplus` proj l v1 -- hmm
+ VS (VV pty pvs rs) v2 -> flip VS v2 . VV pty pvs # mapM (proj l) rs
_ -> return (ok1 VP v l)
ok1 f v1@(VError {}) _ = v1