let add_stmt_spec_postcond config s l_post b kind acc =
let assumes = build_bhv_assumes b in
let add_ensure (p_acc, e_acc) e = match e with
| Normal, e ->
let a = prepare_stmt_spec_post config b s l_post assumes Normal e in
let p_acc = add_prop config p_acc kind a in
(p_acc, e_acc)
| Exits, e ->
let a = prepare_stmt_spec_post config b s l_post assumes Exits e in
let e_acc = add_prop config e_acc kind a in
(p_acc, e_acc)
| (Breaks|Continues|Returns),_ ->
begin
if kind = Agoal then
Wp_parameters.warning
"Abrupt statement terminaison property ignored:@, %a"
(Cil.defaultCilPrinter)#pPost_cond e;
acc
end
in
List.fold_left add_ensure acc b.b_post_cond