1
1
mirror of https://github.com/anoma/juvix.git synced 2025-01-07 08:08:44 +03:00
juvix/tests/positive/Internal/Synonyms.juvix

25 lines
359 B
Plaintext
Raw Normal View History

2023-01-10 19:31:15 +03:00
module Synonyms;
open import Stdlib.Prelude;
Ty1 : Type;
Ty1 := Bool → Bool;
Ty2 : Type;
Ty2 := Ty1;
k : Ty2;
k x := x;
Num : Type;
Num := {A : Type} → (A → A) → A → A;
-- we need the explicit `{_}` since we do not normalize types in the arity checker
czero : Num;
czero {_} f x := x;
csuc : Num → Num;
csuc n {_} f := f ∘ n {_} f;
end;