mirror of
https://github.com/idris-lang/Idris2.git
synced 2024-12-20 10:02:03 +03:00
15 lines
221 B
Idris
15 lines
221 B
Idris
|
-- no_clauses.idr
|
||
|
%default total
|
||
|
|
||
|
bad : (0 _ : Z = S Z) -> Void
|
||
|
bad _ impossible
|
||
|
|
||
|
data BadPrf = Ok | No (Z = S Z)
|
||
|
|
||
|
Show BadPrf where
|
||
|
show Ok = "Ok"
|
||
|
show (No prf) = absurd $ bad prf
|
||
|
|
||
|
main : IO ()
|
||
|
main = printLn Ok
|