Set Implicit Arguments.
(* use this "remember" tactic instead of the standard library one *)
Tactic Notation "remember" constr(a) "as" ident(x) :=
let x := fresh x in
let H := fresh "Heq" x in
(set (x:=a) in *; assert (H: x=a) by reflexivity; clearbody x).

Lemma runnable_false (G C M (*D*): Type) (csem: CoreSemantics G C M (*D*)):
forall c, runnable csem c=false ->
(exists rv, halted csem c = Some rv) \/
(exists ef, exists sig, exists args,
at_external csem c = Some (ef, sig, args)).