(** * Useful tactics *)

Ltac inv H := inversion H; clear H; subst.Ltac predSpec pred predspec x y :=
  generalize (predspec x y); case (pred x y); intro.Ltac caseEq name :=
  generalize (eq_refl name); pattern name at -1 in |- *; case name.Ltac destructEq name :=
  destruct name eqn:?.Ltac decEq :=
  match goal with
  | [ |- _ = _ ] => f_equal
  | [ |- (?X ?A <> ?X ?B) ] =>
      cut (A <> B); [intro; congruence | try discriminate]
  end.Ltac byContradiction :=
  cut False; [contradiction|idtac].Ltac omegaContradiction :=
  cut False; [contradiction|omega].

Lemma modusponens: forall (P Q: Prop), P -> (P -> Q) -> Q.