From d7e3c869c2ae56141260d4576b439097e8271383 Mon Sep 17 00:00:00 2001 From: hallgren Date: Fri, 14 Dec 2012 14:00:21 +0000 Subject: More work on the new partial evaluator The work done by the partial evaluator is now divied in two stages: - A static "term traversal" stage that happens only once per term and uses only statically known information. In particular, the values of lambda bound variables are unknown during this stage. Some tables are transformed to reduce the cost of pattern matching. - A dynamic "function application" stage, where function bodies can be evaluated repeatedly with different arguments, without the term traversal overhead and without recomputing statically known information. Also the treatment of predefined functions has been reworked to take advantage of the staging and better handle partial applications. --- src/compiler/GFI.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/compiler/GFI.hs') diff --git a/src/compiler/GFI.hs b/src/compiler/GFI.hs index 55256c3d7..5412053e8 100644 --- a/src/compiler/GFI.hs +++ b/src/compiler/GFI.hs @@ -333,7 +333,7 @@ checkComputeTerm' new sgr t = do ((t,_),_) <- runCheck $ do t <- renameSourceTerm sgr mo t inferLType sgr [] t t1 <- if new - then return (CN.normalForm (CN.resourceValues sgr) t) + then return (CN.normalForm (CN.resourceValues sgr) (L NoLoc IW) t) else computeConcrete sgr t checkPredefError sgr t1 -- cgit v1.2.3