let rec demod_lit ~jump_to_right bag id lit clause_ctx =
(match lit with
| Terms.Predicate t -> assert false
- | Terms.Equation (l,r,ty,_) -> assert false
- (*let bag,l,id1,lit =
+ | Terms.Equation (l,r,ty,_) ->
+ let bag,l,id1,lit =
visit bag [2]
(fun x -> Terms.Node [ Terms.Leaf B.eqP; ty; x; r ]) id lit l
(ctx_demod table vl clause_ctx)
(fun x -> Terms.Node [ Terms.Leaf B.eqP; ty; l; x ]) id1 lit r
(ctx_demod table vl clause_ctx)
in
- let cl,_,_ = Terms.get_from_bag id2 bag in
- bag,id2,cl *) )
+ bag,id2,lit)
in
let nlit,_,bag,id = if nlit = [] then nlit,[],bag,id
else List.fold_left