Definition unary_primop (f:nat -> nat) : expr :=
  Lam (prim (v_Nat oo f) (Var 0)).Program Definition bin_primop (f:nat -> nat -> nat) : expr :=
  Lam (prim (fun n1 => Lam (prim (fun n2 => v_Nat (f n1 n2)) (Var 0))) (Var 0)).

Lemma unary_primop_typ : forall f, Typ nil (unary_primop f) (ty_lam ty_nat ty_nat).