Ltac pull_left A := repeat (rewrite <- (pull_right A) || rewrite <- (pull_right0 A)).
Ltac pull_right A := repeat (rewrite (pull_right A) || rewrite (pull_right0 A)).

(* Specifications: *)
Lemma derives_extract_prop {A} {NA: NatDed A}:
forall (P: Prop) (Q R: A), (P -> Q |-- R) ->  !!P && Q |-- R.
Lemma derives_extract_prop0 {A}{NA: NatDed A}:
forall (P: Prop) (R: A), (P -> TT |-- R)  -> !!P |-- R.
Lemma derives_extract_prop' {A} {NA: NatDed A}:
forall (P: Prop) (Q R: A), (P -> Q |-- R) ->  Q && !!P|-- R.
Lemma prop_imp {A} {ND: NatDed A}: forall (P: Prop) (Q: A), P -> !! P --> Q = Q.
Lemma andp_assoc' {A}{NA: NatDed A}:
forall P Q R : A, Q && (P && R) = P && (Q && R).
Lemma corable_andp_sepcon2{A}{NA: NatDed A}{SA: SepLog A}{CA: CorableSepLog A}:
forall P Q R : A, corable P ->  (Q && P) * R = P && (Q * R).
Lemma corable_sepcon_andp1 {A}{NA: NatDed A}{SA: SepLog A}{CA: CorableSepLog A}:
forall P Q R : A, corable P ->  Q  * (P && R) = P && (Q * R).
Lemma corable_sepcon_andp2 {A}{NA: NatDed A}{SA: SepLog A}{CA: CorableSepLog A}:
forall P Q R : A, corable P ->  Q  * (R && P) = P && (Q * R).
Lemma pure_modus {A} {JA: Join A}{PA: Perm_alg A}{SA: Sep_alg A}{agA: ageable A}{AgeA: Age_alg A}:
forall P Q,  P |-- Q -> pure Q -> P |-- Q && P.
Lemma imp_exp_right {B A : Type} `{saA: ageable A}:
forall (x: B) (p: pred A) (q: B -> pred A),
p |-- q x ->
p |-- exp q.
Lemma derives_extract_prop {A} `{ageable A}:
forall (P: Prop) (Q R: pred A), (P -> Q |-- R) ->  !!P && Q |-- R.
Lemma derives_extract_prop' {A} `{ageable A}:
forall (P: Prop) (Q R: pred A), (P -> Q |-- R) ->  Q && !!P|-- R.