summaryrefslogtreecommitdiff
path: root/compiler/hsSyn
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2012-05-18 10:10:28 +0100
committerSimon Peyton Jones <simonpj@microsoft.com>2012-05-18 10:10:28 +0100
commit869044056c54dfe95017c19bef5274b748cfe724 (patch)
tree8882c13c858b78334d2e5c4d0158ba192dd27cd0 /compiler/hsSyn
parentb6bf6abe2b5729137391a88c8deb4cc7ed851375 (diff)
downloadhaskell-869044056c54dfe95017c19bef5274b748cfe724.tar.gz
Wibbles to lunaris's patch for promoted kinds
Diffstat (limited to 'compiler/hsSyn')
-rw-r--r--compiler/hsSyn/Convert.lhs9
1 files changed, 6 insertions, 3 deletions
diff --git a/compiler/hsSyn/Convert.lhs b/compiler/hsSyn/Convert.lhs
index f4aae3faed..ef17c60299 100644
--- a/compiler/hsSyn/Convert.lhs
+++ b/compiler/hsSyn/Convert.lhs
@@ -876,9 +876,12 @@ cvtTypeKind ty_str ty
PromotedNilT
-> returnL (HsExplicitListTy placeHolderKind [])
- PromotedConsT
- | [ty1, ty2] <- tys'
- -> mk_apps (HsTyVar (getRdrName consDataCon)) [ty1, ty2]
+ PromotedConsT -- See Note [Representing concrete syntax in types]
+ -- in Language.Haskell.TH.Syntax
+ | [ty1, L _ (HsExplicitListTy _ tys2)] <- tys'
+ -> returnL (HsExplicitListTy placeHolderKind (ty1:tys2))
+ | otherwise
+ -> mk_apps (HsTyVar (getRdrName consDataCon)) tys'
StarT
-> returnL (HsTyVar (getRdrName liftedTypeKindTyCon))