X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;ds=sidebyside;f=compiler%2Ftypecheck%2FTcSMonad.lhs;fp=compiler%2Ftypecheck%2FTcSMonad.lhs;h=27ecb440d654d34c9b85949138398aa124f3e940;hb=1ddce51848468501577f36119920e9e32e93fba8;hp=36befd9cd6240697fcdafa48f70d842bd5dfca67;hpb=1e8493b3646fcc568a11d502552710848d46aa41;p=ghc-hetmet.git diff --git a/compiler/typecheck/TcSMonad.lhs b/compiler/typecheck/TcSMonad.lhs index 36befd9..27ecb44 100644 --- a/compiler/typecheck/TcSMonad.lhs +++ b/compiler/typecheck/TcSMonad.lhs @@ -186,8 +186,10 @@ makeSolvedByInst :: CanonicalCt -> CanonicalCt -- Wanted -> Given -- Given, Derived -> no-op makeSolvedByInst ct - | Wanted loc <- cc_flavor ct = ct { cc_flavor = mkGivenFlavor (Wanted loc) UnkSkol } - | otherwise = ct + | Wanted loc <- cc_flavor ct + = ct { cc_flavor = Given (setCtLocOrigin loc UnkSkol) } + | otherwise -- Only called on wanteds + = pprPanic "makeSolvedByInst" (ppr ct) deCanonicalise :: CanonicalCt -> FlavoredEvVar deCanonicalise ct = mkEvVarX (cc_id ct) (cc_flavor ct)