Ltac deduce_eq0 :=
lazymatch goal with
| H: _ + _ = O |- _ =>
apply Nat.eq_add_0 in H; destruct H
| H: S _ * _ = O |- _ =>
apply Nat.eq_mul_0_r in H; [| discriminate]
| H: ?x = O |- _ =>
is_var x; subst x
end.
Ltac single := eapply progress_intro; [prove_step | simpl_tape].
Ltac goto x := lazymatch type of x with
| I => exists x
| _ -> I => exists (x ltac:(lia))
end; single; finish.

Lemma const_eq_intro' : forall (x : Sym) xs,
const x = xs ->
const x = x >> xs.