diff options
Diffstat (limited to 'testsuite/tests/ghci/prog003/D1.hs')
-rw-r--r-- | testsuite/tests/ghci/prog003/D1.hs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/testsuite/tests/ghci/prog003/D1.hs b/testsuite/tests/ghci/prog003/D1.hs new file mode 100644 index 0000000000..4414d65d2a --- /dev/null +++ b/testsuite/tests/ghci/prog003/D1.hs @@ -0,0 +1,13 @@ +module D where + +-- data types and an instance +data D a = A Int | B Float deriving Eq +newtype N a = N Double +type T a = (Int,Double) + +-- a class +class C a where c :: a -> Int + +-- a function +d :: Int -> Int +d x = x * 2 |