(* fetching rhs functions names *)
Definition rhs_funcs ru :=  (* => Syntax.v ? *)
  match ru with
  | rule_intro _ _ t => functions_of_term t
  end.Definition all_rhs_funcs prg := flat_map rhs_funcs prg.

Lemma qif_eq_eta trs f l: let inf := get_info trs f in let q := inf.(asg) in let norm := inf.(norm) in let l1 := firstn norm l in let l2 := skipn norm l in (q l1) + (maxl l2) = qif trs f l.