Increase an InScopeSet for a substitution
authorRichard Eisenberg <eir@cis.upenn.edu>
Tue, 12 Apr 2016 16:00:55 +0000 (12:00 -0400)
committerRichard Eisenberg <eir@cis.upenn.edu>
Fri, 15 Apr 2016 13:30:11 +0000 (09:30 -0400)
This is a further fix for #11814

compiler/types/FamInstEnv.hs

index 020dd78..62906dd 100644 (file)
@@ -515,7 +515,8 @@ compatibleBranches (CoAxBranch { cab_lhs = lhs1, cab_rhs = rhs1 })
   = case tcUnifyTysFG (const BindMe) lhs1 lhs2 of
       SurelyApart -> True
       Unifiable subst
-        | Type.substTy subst rhs1 `eqType` Type.substTy subst rhs2
+        | Type.substTyAddInScope subst rhs1 `eqType`
+          Type.substTyAddInScope subst rhs2
         -> True
       _ -> False