let add_stmt_spec_before config s spec acc =
let ki = (Kstmt s) in
match config.cur_bhv with
| StmtBhv (_n, cur_s, _cur_bhv) when s.sid = cur_s.sid ->
begin match get_behav config ki spec.spec_behavior with
| None ->
acc
| Some b ->
let add kind acc p =
add_prop config acc kind (prepare_pre config ki b p)
in
let acc = List.fold_left (add Aboth) acc b.b_requires in
let acc = List.fold_left (add Ahyp) acc b.b_assumes in
let acc = add_behaviors_props config ki spec acc in
acc
end
| _ ->
add_stmt_spec_precond_as_hyp config s spec acc