[commit: ghc] wip/names3: Fix determinism (680fb03)

git at git.haskell.org git at git.haskell.org
Thu Sep 8 18:52:47 UTC 2016


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

On branch  : wip/names3
Link       : http://ghc.haskell.org/trac/ghc/changeset/680fb0318641dbc1b9f2df80aeb93757bb84056c/ghc

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

commit 680fb0318641dbc1b9f2df80aeb93757bb84056c
Author: Ben Gamari <ben at smart-cactus.org>
Date:   Thu Aug 25 15:41:16 2016 -0400

    Fix determinism


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

680fb0318641dbc1b9f2df80aeb93757bb84056c
 compiler/iface/MkIface.hs | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/compiler/iface/MkIface.hs b/compiler/iface/MkIface.hs
index 358c813..80d29c4 100644
--- a/compiler/iface/MkIface.hs
+++ b/compiler/iface/MkIface.hs
@@ -566,7 +566,7 @@ addFingerprints hsc_env mb_old_fingerprint iface0 new_decls
 
    -- put the declarations in a canonical order, sorted by OccName
    let sorted_decls = Map.elems $ Map.fromList $
-                          [(ifName d, e) | e@(_, d) <- decls_w_hashes]
+                          [(getOccName d, e) | e@(_, d) <- decls_w_hashes]
 
    -- the flag hash depends on:
    --   - (some of) dflags
@@ -738,8 +738,8 @@ abiDecl :: IfaceDeclABI -> IfaceDecl
 abiDecl (_, decl, _) = decl
 
 cmp_abiNames :: IfaceDeclABI -> IfaceDeclABI -> Ordering
-cmp_abiNames abi1 abi2 = ifName (abiDecl abi1) `compare`
-                         ifName (abiDecl abi2)
+cmp_abiNames abi1 abi2 = getOccName (abiDecl abi1) `compare`
+                         getOccName (abiDecl abi2)
 
 freeNamesDeclABI :: IfaceDeclABI -> NameSet
 freeNamesDeclABI (_mod, decl, extras) =



More information about the ghc-commits mailing list