Merge llvm_testing, and use TypeCheckerIr instead of Abs
This commit is contained in:
commit
7ef7090aa5
21 changed files with 499 additions and 101 deletions
|
|
@ -1,3 +1,6 @@
|
|||
|
||||
f : Int -> Int;
|
||||
f = \x:Int. x+1;
|
||||
tripplemagic : Int -> Int -> Int -> Int;
|
||||
tripplemagic x y z = ((\x:Int. x+x) x) + y + z;
|
||||
|
||||
main : Int;
|
||||
main = tripplemagic ((\x:Int. x+x+3) ((\x:Int. x) 2)) 5 3
|
||||
|
|
|
|||
|
|
@ -1,3 +0,0 @@
|
|||
|
||||
main : Int -> Int -> Int;
|
||||
main x y = (x : Int) + y;
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
|
||||
add : Int -> Int -> Int;
|
||||
add x = \y:Int. x+y;
|
||||
|
||||
main : Int;
|
||||
main = (\z:Int. z+z) ((add 4) 6);
|
||||
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
|
||||
main : Int;
|
||||
main = (\x:Int. x+x+3) ((\x:Int. x) 2);
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
|
||||
f : Int -> Int;
|
||||
f x = let
|
||||
g : Int -> Int;
|
||||
g = (\y:Int. y+1);
|
||||
in
|
||||
g (g x);
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
id : Int -> Int;
|
||||
id x = x;
|
||||
|
||||
add : Int -> Int -> Int;
|
||||
add x y = x + y;
|
||||
|
||||
double : Int -> Int;
|
||||
double n = n + n;
|
||||
|
||||
apply : (Int -> Int -> Int) -> Int -> Int -> Int;
|
||||
apply f x = \y:Int. f x y;
|
||||
|
||||
main : Int;
|
||||
main = apply add ((\x:Int. x + 1) 1) (double (id 3));
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
|
||||
|
||||
f : Int -> Int -> Int;
|
||||
f = \x:Int.\y:Int. x+y;
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
add : Int -> Int -> Int;
|
||||
add x y = x + y;
|
||||
|
||||
apply : (Int -> Int) -> Int -> Int;
|
||||
apply f x = f x;
|
||||
|
||||
main : Int;
|
||||
main = apply (add 4) 6;
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
|
||||
f : Int -> Int;
|
||||
f x = let
|
||||
double : Int -> Int;
|
||||
double = \y:Int. y+y
|
||||
in
|
||||
double (x + 4);
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
|
||||
|
||||
|
||||
main : Int;
|
||||
main = (\f:Int -> Int.\x:Int.\y:Int. f x + f y) (\x:Int. x+x) ((\x:Int. x+1) ((\x:Int. x+3) 2)) 4
|
||||
Loading…
Add table
Add a link
Reference in a new issue