Proof using.
intros. unfold handleRequestVote, advanceCurrentTerm in *.
repeat break_match; find_inversion; auto.
Qed.

Lemma handleRequestVote_type_term :
forall st h h' t lli llt st' m,
handleRequestVote h st t h' lli llt = (st', m) ->
(type st' = type st /\ currentTerm st' = currentTerm st) \/
(type st' = Follower /\ currentTerm st' >= currentTerm st).