let pp_list ~sep pp_item =
  Format.pp_print_list ~pp_sep:(fun ppf () -> Format.fprintf ppf sep) pp_item

let pp_app pp_item fmt =
  Format.fprintf fmt "@[(%a)@]" (pp_list ~sep:"@;<1 2>" pp_item)

let pp_app_name name pp_item fmt =
  Format.fprintf fmt "@[(%s@;<1 2>%a)@]" name (pp_list ~sep:"@;<1 2>" pp_item)
