X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Ftypecheck%2FTcType.lhs;h=50ac35ab50a97d0a65ac6d795704440ec82d7638;hp=89aba6504f1d4fce2f54642c76026afb540a7519;hb=4d8c7c976104d2e39a1183967ec0f254a0fc0a47;hpb=492303f32eb179c14a095aa175541bdbff486179 diff --git a/compiler/typecheck/TcType.lhs b/compiler/typecheck/TcType.lhs index 89aba65..50ac35a 100644 --- a/compiler/typecheck/TcType.lhs +++ b/compiler/typecheck/TcType.lhs @@ -956,6 +956,9 @@ tcInstHeadTyAppAllTyVars :: Type -> Bool -- Used in Haskell-98 mode, for the argument types of an instance head -- These must be a constructor applied to type variable arguments tcInstHeadTyAppAllTyVars ty + | Just ty' <- tcView ty -- Look through synonyms + = tcInstHeadTyAppAllTyVars ty' + | otherwise = case ty of TyConApp _ tys -> ok tys FunTy arg res -> ok [arg, res]