mirror of
https://github.com/edwinb/Idris2-boot.git
synced 2024-11-24 04:43:25 +03:00
Add a test.
This commit is contained in:
parent
806e8d2569
commit
b20ae8d36b
2
tests/idris2/reg016/expected
Normal file
2
tests/idris2/reg016/expected
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
1/1: Building anyfail (anyfail.idr)
|
||||||
|
anyfail.idr:21:1--22:1:showing (MkEvenMoreComplicated (MkMoreComplicated (MkComplicated (PtrAndSize addr len)))) SomethingVeryComplicatedIs is not a valid impossible case
|
13
tests/idris2/reg016/numbers.idr
Normal file
13
tests/idris2/reg016/numbers.idr
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
main : IO ()
|
||||||
|
main = do
|
||||||
|
printLn $ 3
|
||||||
|
printLn $ 4.2
|
||||||
|
printLn $ "1.2"
|
||||||
|
|
||||||
|
printLn $ cast {to = Int} 4.8
|
||||||
|
printLn $ cast {to = Integer} 1.2
|
||||||
|
printLn $ cast {to = String} 2.7
|
||||||
|
|
||||||
|
printLn $ cast {to = Int} "1.2"
|
||||||
|
printLn $ cast {to = Integer} "2.7"
|
||||||
|
printLn $ cast {to = Double} "5.9"
|
3
tests/idris2/reg016/run
Executable file
3
tests/idris2/reg016/run
Executable file
@ -0,0 +1,3 @@
|
|||||||
|
$1 numbers.idr -x main
|
||||||
|
|
||||||
|
rm -rf build
|
Loading…
Reference in New Issue
Block a user