Commit 372a8c47 authored by simonpj@microsoft.com's avatar simonpj@microsoft.com

Use mkAppTy

Using AppTy in CoreLint was giving a bogus Lint failure
parent 70fb70c5
......@@ -615,7 +615,7 @@ lintCoercion ty@(AppTy ty1 ty2)
= do { (s1,t1) <- lintCoercion ty1
; (s2,t2) <- lintCoercion ty2
; check_co_app ty (typeKind s1) [s2]
; return (AppTy s1 s2, AppTy t1 t2) }
; return (mkAppTy s1 s2, mkAppTy t1 t2) }
lintCoercion ty@(FunTy ty1 ty2)
= do { (s1,t1) <- lintCoercion ty1
......
......@@ -476,11 +476,11 @@ normaliseType env (TyConApp tc tys)
normaliseType env (AppTy ty1 ty2)
= let (coi1,nty1) = normaliseType env ty1
(coi2,nty2) = normaliseType env ty2
in (mkAppTyCoI coi1 coi2, AppTy nty1 nty2)
in (mkAppTyCoI coi1 coi2, mkAppTy nty1 nty2)
normaliseType env (FunTy ty1 ty2)
= let (coi1,nty1) = normaliseType env ty1
(coi2,nty2) = normaliseType env ty2
in (mkFunTyCoI coi1 coi2, FunTy nty1 nty2)
in (mkFunTyCoI coi1 coi2, mkFunTy nty1 nty2)
normaliseType env (ForAllTy tyvar ty1)
= let (coi,nty1) = normaliseType env ty1
in (mkForAllTyCoI tyvar coi, ForAllTy tyvar nty1)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment