Idris2/tests/idris2/interactive/interactive042/Issue35-2.idr
2023-09-07 14:57:22 +01:00

5 lines
104 B
Idris

f : { a, b : Type } -> Either a b -> Either b a
f {a=b} x = x
f (Right x) = Left x
f (Left x) = Right x