diff options
author | Péter Diviánszky <divipp@gmail.com> | 2016-05-03 16:40:30 +0200 |
---|---|---|
committer | Péter Diviánszky <divipp@gmail.com> | 2016-05-03 16:40:30 +0200 |
commit | f468a49a43193caffe92cdd48a52a699880e14ef (patch) | |
tree | 255c8b454e9a75d05397468b849b8f5b032a878a /testdata/Internals.out | |
parent | fa47957b930c53d78d2da0bcb948e2fbff11f59d (diff) |
refactoring
Diffstat (limited to 'testdata/Internals.out')
-rw-r--r-- | testdata/Internals.out | 52 |
1 files changed, 51 insertions, 1 deletions
diff --git a/testdata/Internals.out b/testdata/Internals.out index b3eac04a..22ff0f64 100644 --- a/testdata/Internals.out +++ b/testdata/Internals.out | |||
@@ -1,60 +1,100 @@ | |||
1 | main is not found | ||
1 | ------------ desugared source code | 2 | ------------ desugared source code |
2 | typeAnn = \(a :: _) -> _rhs a | 3 | typeAnn = \(a :: _) -> _rhs a |
4 | |||
3 | parens = \(a :: _) -> _rhs a | 5 | parens = \(a :: _) -> _rhs a |
6 | |||
4 | undefined :: forall a . a | 7 | undefined :: forall a . a |
8 | |||
5 | primFix :: forall a . (a -> a) -> a | 9 | primFix :: forall a . (a -> a) -> a |
10 | |||
6 | data Unit :: Type where | 11 | data Unit :: Type where |
7 | TT :: Unit | 12 | TT :: Unit |
13 | |||
8 | data String :: Type where | 14 | data String :: Type where |
9 | 15 | ||
16 | |||
10 | data Empty (_ :: String) :: Type where | 17 | data Empty (_ :: String) :: Type where |
11 | 18 | ||
19 | |||
12 | unsafeCoerce :: forall (a :: _) (b :: _) . a -> b | 20 | unsafeCoerce :: forall (a :: _) (b :: _) . a -> b |
21 | |||
13 | 'EqCT :: forall a -> a -> a -> Type | 22 | 'EqCT :: forall a -> a -> a -> Type |
23 | |||
14 | parEval :: forall (a :: _) -> a -> a -> a | 24 | parEval :: forall (a :: _) -> a -> a -> a |
25 | |||
15 | 'T2 :: Type -> Type -> Type | 26 | 'T2 :: Type -> Type -> Type |
27 | |||
16 | match'Type :: forall (a :: Type -> Type) -> a Type -> forall b -> a b -> a b | 28 | match'Type :: forall (a :: Type -> Type) -> a Type -> forall b -> a b -> a b |
29 | |||
17 | 'EqCTt = _rhs ('EqCT (_ :: _)) | 30 | 'EqCTt = _rhs ('EqCT (_ :: _)) |
31 | |||
18 | t2C :: Unit -> Unit -> Unit | 32 | t2C :: Unit -> Unit -> Unit |
33 | |||
19 | data Int :: Type where | 34 | data Int :: Type where |
20 | 35 | ||
36 | |||
21 | data Word :: Type where | 37 | data Word :: Type where |
22 | 38 | ||
39 | |||
23 | data Float :: Type where | 40 | data Float :: Type where |
24 | 41 | ||
42 | |||
25 | data Char :: Type where | 43 | data Char :: Type where |
26 | 44 | ||
45 | |||
27 | data Bool :: Type where | 46 | data Bool :: Type where |
28 | False :: Bool | 47 | False :: Bool |
29 | True :: Bool | 48 | True :: Bool |
49 | |||
30 | data Ordering :: Type where | 50 | data Ordering :: Type where |
31 | LT :: Ordering | 51 | LT :: Ordering |
32 | EQ :: Ordering | 52 | EQ :: Ordering |
33 | GT :: Ordering | 53 | GT :: Ordering |
54 | |||
34 | data Nat :: Type where | 55 | data Nat :: Type where |
35 | Zero :: Nat | 56 | Zero :: Nat |
36 | Succ :: Nat -> Nat | 57 | Succ :: Nat -> Nat |
58 | |||
37 | primIntToWord :: Int -> Word | 59 | primIntToWord :: Int -> Word |
60 | |||
38 | primIntToFloat :: Int -> Float | 61 | primIntToFloat :: Int -> Float |
62 | |||
39 | primIntToNat :: Int -> Nat | 63 | primIntToNat :: Int -> Nat |
64 | |||
40 | primCompareInt :: Int -> Int -> Ordering | 65 | primCompareInt :: Int -> Int -> Ordering |
66 | |||
41 | primCompareWord :: Word -> Word -> Ordering | 67 | primCompareWord :: Word -> Word -> Ordering |
68 | |||
42 | primCompareFloat :: Float -> Float -> Ordering | 69 | primCompareFloat :: Float -> Float -> Ordering |
70 | |||
43 | primCompareChar :: Char -> Char -> Ordering | 71 | primCompareChar :: Char -> Char -> Ordering |
72 | |||
44 | primCompareString :: String -> String -> Ordering | 73 | primCompareString :: String -> String -> Ordering |
74 | |||
45 | primNegateInt :: Int -> Int | 75 | primNegateInt :: Int -> Int |
76 | |||
46 | primNegateWord :: Word -> Word | 77 | primNegateWord :: Word -> Word |
78 | |||
47 | primNegateFloat :: Float -> Float | 79 | primNegateFloat :: Float -> Float |
80 | |||
48 | primAddInt :: Int -> Int -> Int | 81 | primAddInt :: Int -> Int -> Int |
82 | |||
49 | primSubInt :: Int -> Int -> Int | 83 | primSubInt :: Int -> Int -> Int |
84 | |||
50 | primModInt :: Int -> Int -> Int | 85 | primModInt :: Int -> Int -> Int |
86 | |||
51 | primSqrtFloat :: Float -> Float | 87 | primSqrtFloat :: Float -> Float |
88 | |||
52 | primRound :: Float -> Int | 89 | primRound :: Float -> Int |
90 | |||
53 | primIfThenElse :: forall (a :: _) . Bool -> a -> a -> a | 91 | primIfThenElse :: forall (a :: _) . Bool -> a -> a -> a |
54 | primIfThenElse | 92 | primIfThenElse |
55 | = \(a :: _) (b :: _) (c :: _) -> case'Bool (\_ -> _) (_rhs c) (_rhs b) a | 93 | = \(a :: _) (b :: _) (c :: _) -> case'Bool (\_ -> _) (_rhs c) (_rhs b) a |
94 | |||
56 | isEQ | 95 | isEQ |
57 | = \(a :: _) -> case'Ordering (\_ -> _) (_rhs False) (_rhs True) (_rhs False) a | 96 | = \(a :: _) -> case'Ordering (\_ -> _) (_rhs False) (_rhs True) (_rhs False) a |
97 | |||
58 | 'Num :: Type -> Type | 98 | 'Num :: Type -> Type |
59 | 'Num | 99 | 'Num |
60 | = \(a :: _) -> match'Int | 100 | = \(a :: _) -> match'Int |
@@ -74,6 +114,7 @@ isEQ | |||
74 | (_rhs 'Unit) | 114 | (_rhs 'Unit) |
75 | a | 115 | a |
76 | (_rhs ('Empty "no instance of 'Num on ???"))))) | 116 | (_rhs ('Empty "no instance of 'Num on ???"))))) |
117 | |||
77 | fromInt :: forall a . Num a => Int -> a | 118 | fromInt :: forall a . Num a => Int -> a |
78 | fromInt | 119 | fromInt |
79 | = \ @a @_ -> match'Int | 120 | = \ @a @_ -> match'Int |
@@ -89,6 +130,7 @@ fromInt | |||
89 | (_rhs \(e := _rhs primIntToFloat) -> e) | 130 | (_rhs \(e := _rhs primIntToFloat) -> e) |
90 | a | 131 | a |
91 | (match'Nat (\_ -> _) (_rhs \(f := _rhs primIntToNat) -> f) a (_rhs undefined)))) | 132 | (match'Nat (\_ -> _) (_rhs \(f := _rhs primIntToNat) -> f) a (_rhs undefined)))) |
133 | |||
92 | compare :: forall a . Num a => a -> a -> Ordering | 134 | compare :: forall a . Num a => a -> a -> Ordering |
93 | compare | 135 | compare |
94 | = \ @a @_ -> match'Int | 136 | = \ @a @_ -> match'Int |
@@ -104,6 +146,7 @@ compare | |||
104 | (_rhs \(d := _rhs primCompareFloat) -> d) | 146 | (_rhs \(d := _rhs primCompareFloat) -> d) |
105 | a | 147 | a |
106 | (match'Nat (\_ -> _) (_rhs \(e := _rhs undefined) -> e) a (_rhs undefined)))) | 148 | (match'Nat (\_ -> _) (_rhs \(e := _rhs undefined) -> e) a (_rhs undefined)))) |
149 | |||
107 | negate :: forall a . Num a => a -> a | 150 | negate :: forall a . Num a => a -> a |
108 | negate | 151 | negate |
109 | = \ @a @_ -> match'Int | 152 | = \ @a @_ -> match'Int |
@@ -119,6 +162,7 @@ negate | |||
119 | (_rhs \(d := _rhs primNegateFloat) -> d) | 162 | (_rhs \(d := _rhs primNegateFloat) -> d) |
120 | a | 163 | a |
121 | (match'Nat (\_ -> _) (_rhs \(e := _rhs undefined) -> e) a (_rhs undefined)))) | 164 | (match'Nat (\_ -> _) (_rhs \(e := _rhs undefined) -> e) a (_rhs undefined)))) |
165 | |||
122 | 'Eq :: Type -> Type | 166 | 'Eq :: Type -> Type |
123 | 'Eq | 167 | 'Eq |
124 | = \(a :: _) -> match'String | 168 | = \(a :: _) -> match'String |
@@ -146,6 +190,7 @@ negate | |||
146 | (_rhs 'Unit) | 190 | (_rhs 'Unit) |
147 | a | 191 | a |
148 | (_rhs ('Empty "no instance of 'Eq on ???"))))))) | 192 | (_rhs ('Empty "no instance of 'Eq on ???"))))))) |
193 | |||
149 | (==) :: forall a . Eq a => a -> a -> Bool | 194 | (==) :: forall a . Eq a => a -> a -> Bool |
150 | (==) | 195 | (==) |
151 | = \ @a @_ -> match'String | 196 | = \ @a @_ -> match'String |
@@ -185,19 +230,24 @@ negate | |||
185 | r) -> q) | 230 | r) -> q) |
186 | a | 231 | a |
187 | (_rhs undefined)))))) | 232 | (_rhs undefined)))))) |
233 | |||
188 | infix 4 == | 234 | infix 4 == |
235 | |||
189 | data List (_ :: Type) :: Type where | 236 | data List (_ :: Type) :: Type where |
190 | [] :: forall a . [a] | 237 | [] :: forall a . [a] |
191 | (:) :: forall b . b -> [b] -> [b] | 238 | (:) :: forall b . b -> [b] -> [b] |
239 | |||
192 | infixr 5 : | 240 | infixr 5 : |
241 | |||
193 | data HList :: [Type] -> Type where | 242 | data HList :: [Type] -> Type where |
194 | HNil :: HList '[] | 243 | HNil :: HList '[] |
195 | HCons :: forall (a :: _) (b :: _) . a -> HList b -> HList (a : b) | 244 | HCons :: forall (a :: _) (b :: _) . a -> HList b -> HList (a : b) |
245 | |||
196 | hlistNilCase :: forall (a :: _) -> a -> HList [] -> a | 246 | hlistNilCase :: forall (a :: _) -> a -> HList [] -> a |
247 | |||
197 | hlistConsCase | 248 | hlistConsCase |
198 | :: forall a (b :: [Type]) | 249 | :: forall a (b :: [Type]) |
199 | . forall (c :: _) -> (a -> HList b -> c) -> HList (a : b) -> c | 250 | . forall (c :: _) -> (a -> HList b -> c) -> HList (a : b) -> c |
200 | main is not found | ||
201 | ------------ trace | 251 | ------------ trace |
202 | typeAnn :: forall a . a -> a | 252 | typeAnn :: forall a . a -> a |
203 | parens :: forall a . a -> a | 253 | parens :: forall a . a -> a |