[commit: ghc] master: nativeGen: Use foldl' instead of foldl (7dc82d6)

git at git.haskell.org git at git.haskell.org
Tue Nov 28 20:53:07 UTC 2017


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/7dc82d64014a4c5d87095537c20729da7cc65137/ghc

>---------------------------------------------------------------

commit 7dc82d64014a4c5d87095537c20729da7cc65137
Author: Ben Gamari <ben at smart-cactus.org>
Date:   Mon Nov 27 20:02:55 2017 -0500

    nativeGen: Use foldl' instead of foldl


>---------------------------------------------------------------

7dc82d64014a4c5d87095537c20729da7cc65137
 compiler/nativeGen/AsmCodeGen.hs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/compiler/nativeGen/AsmCodeGen.hs b/compiler/nativeGen/AsmCodeGen.hs
index d11eada..6b20a12 100644
--- a/compiler/nativeGen/AsmCodeGen.hs
+++ b/compiler/nativeGen/AsmCodeGen.hs
@@ -972,7 +972,7 @@ build_mapping ncgImpl (CmmProc info lbl live (ListGraph (head:blocks)))
     has_info l = mapMember l info
 
     -- build a mapping from BlockId to JumpDest for shorting branches
-    mapping = foldl add emptyUFM shortcut_blocks
+    mapping = foldl' add emptyUFM shortcut_blocks
     add ufm (id,dest) = addToUFM ufm id dest
 
 apply_mapping :: NcgImpl statics instr jumpDest



More information about the ghc-commits mailing list