add golden test stuff
This commit is contained in:
parent
b7dc5ffdc4
commit
8823154973
24 changed files with 126 additions and 0 deletions
12
golden-tests/tests/hello/expected
Normal file
12
golden-tests/tests/hello/expected
Normal file
|
@ -0,0 +1,12 @@
|
|||
0.IO : 1.★ → ★
|
||||
ω.print : 1.String → IO {ok}
|
||||
ω.main : IO {ok}
|
||||
IO = □
|
||||
print = scheme:(lambda (str) (builtin-io (display str) (newline)))
|
||||
#[main] main = print "hello 🐉"
|
||||
;; IO erased
|
||||
(define print
|
||||
(lambda (str) (builtin-io (display str) (newline))))
|
||||
(define main
|
||||
(print "hello \x1f409;"))
|
||||
hello 🐉
|
7
golden-tests/tests/hello/hello.quox
Normal file
7
golden-tests/tests/hello/hello.quox
Normal file
|
@ -0,0 +1,7 @@
|
|||
def0 IO : ★ → ★ = λ A ⇒ IOState → A × IOState
|
||||
|
||||
#[compile-scheme "(lambda (str) (builtin-io (display str) (newline)))"]
|
||||
postulate print : String → IO {ok}
|
||||
|
||||
#[main]
|
||||
def main = print "hello 🐉"
|
2
golden-tests/tests/hello/run
Normal file
2
golden-tests/tests/hello/run
Normal file
|
@ -0,0 +1,2 @@
|
|||
. ../lib.sh
|
||||
compile_run "$1" hello.quox hello.ss
|
Loading…
Add table
Add a link
Reference in a new issue