summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManuel M T Chakravarty <chak@cse.unsw.edu.au>2011-07-31 17:29:39 +1000
committerManuel M T Chakravarty <chak@cse.unsw.edu.au>2011-07-31 17:32:39 +1000
commit5ff42f08320838a1000a525d4d9d98a5b370f77f (patch)
tree72d1856e6806bde8dd1465e28528158bb4ee54e7
parent2088abaf4173090e343b521dc89d622936fba850 (diff)
downloadhaskell-5ff42f08320838a1000a525d4d9d98a5b370f77f.tar.gz
Fix the use of UniqueFM in the type checker (commit bf5af91ca597666641b8519abc85a31297b30823) to preserve the ordering of contexts
See also http://www.haskell.org/pipermail/cvs-ghc/2011-July/064550.html
-rw-r--r--compiler/typecheck/TcInteract.lhs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/typecheck/TcInteract.lhs b/compiler/typecheck/TcInteract.lhs
index 4c450f7557..983df3c503 100644
--- a/compiler/typecheck/TcInteract.lhs
+++ b/compiler/typecheck/TcInteract.lhs
@@ -111,7 +111,7 @@ updCCanMap (a,ct) cmap
Given {} -> cmap { cts_given = insert_into (cts_given cmap) }
Derived {} -> cmap { cts_derived = insert_into (cts_derived cmap) }
where
- insert_into m = addToUFM_C unionBags m a (singleCCan ct)
+ insert_into m = addToUFM_C (flip unionBags) m a (singleCCan ct)
getRelevantCts :: Uniquable a => a -> CCanMap a -> (CanonicalCts, CCanMap a)
-- Gets the relevant constraints and returns the rest of the CCanMap