Proof using.
intros. unfold doLeader in *. simpl; intros.
repeat break_match; find_inversion; auto; congruence.
Qed.

(* Specifications: *)
Lemma doLeader_lastApplied :
forall st h os st' ms,
doLeader st h = (os, st', ms) ->
lastApplied st' = lastApplied st.