From bd134c7b2a6880bf3858fd8c27fa16ab946d7718 Mon Sep 17 00:00:00 2001 From: Mateusz Kowalczyk Date: Mon, 31 Mar 2014 05:34:36 +0100 Subject: Print kind signatures on GADTs --- html-test/ref/AdvanceTypes.html | 2 +- html-test/ref/Bug85.html | 135 ++++++++++++++++++++++++++++++++++++++++ html-test/src/Bug85.hs | 15 +++++ 3 files changed, 151 insertions(+), 1 deletion(-) create mode 100644 html-test/ref/Bug85.html create mode 100644 html-test/src/Bug85.hs (limited to 'html-test') diff --git a/html-test/ref/AdvanceTypes.html b/html-test/ref/AdvanceTypes.html index ab37fe61..b918a220 100644 --- a/html-test/ref/AdvanceTypes.html +++ b/html-test/ref/AdvanceTypes.html @@ -50,7 +50,7 @@ window.onload = function () {pageLoad();setSynopsis("mini_AdvanceTypes.html");}; >data Pattern :: [*] -> * where

+Bug85
Safe HaskellSafe-Inferred

Bug85

Documentation

data Foo :: (* -> *) -> * -> * where

Constructors

Bar :: f x -> Foo f (f x) 

data Baz :: * where

Constructors

Baz' :: Baz 

data Qux where

Constructors

Quux :: Qux 
diff --git a/html-test/src/Bug85.hs b/html-test/src/Bug85.hs new file mode 100644 index 00000000..9c5b768b --- /dev/null +++ b/html-test/src/Bug85.hs @@ -0,0 +1,15 @@ +{-# LANGUAGE GADTs, KindSignatures #-} +{-# OPTIONS_HADDOCK use-unicode #-} +module Bug85 where + +-- explicitly stated non-trivial kind +data Foo :: (* -> *) -> * -> * where + Bar :: f x -> Foo f (f x) + +-- Just kind * but explicitly written +data Baz :: * where + Baz' :: Baz + +-- No kind signature written down at all +data Qux where + Quux :: Qux -- cgit v1.2.3