From a8912dea5ee133d56973da7fc3aac35df8405863 Mon Sep 17 00:00:00 2001 From: crumbtoo Date: Sun, 17 Mar 2024 05:59:23 -0600 Subject: [PATCH] there is a fucking ghost that keeps changing this ifoldr to an ifoldl. --- src/Rlp/HindleyMilner.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Rlp/HindleyMilner.hs b/src/Rlp/HindleyMilner.hs index 9696300..ead950e 100644 --- a/src/Rlp/HindleyMilner.hs +++ b/src/Rlp/HindleyMilner.hs @@ -136,7 +136,7 @@ infer1' g1 e = do ((t,j) :< _) <- annotate e g2 <- unify (j ^. constraints) g <- unionContextWithKeyM unifyTypes g1 g2 - pure $ ifoldrOf (contextVars . itraversed) subst t g + pure $ ifoldlOf (contextVars . itraversed) subst t g where -- intuitively, we'd return mgu(s,t) but the union is left-biased making `s` -- the user-specified type: prioritise her.