Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision
  • ci-release
  • ci/msammler/more_feed
  • ci/refactor_staging
  • coq-stdpp-1.0
  • dfrumin/coq-stdpp-set_map_2
  • master
  • msammler/bitvector
  • msammler/bool_decide_simpl_never
  • msammler/monad_without_universe_constraints
  • ralf/empty-opaque
  • ralf/hint-mode-check
  • ralf/hint-mode-plus
  • ralf/listZ
  • ralf/lookup_insert
  • ralf/make_simple_intropattern
  • ralf/multiset-solver
  • robbert/cancel_inj_surj
  • robbert/cbn
  • robbert/f_equiv_pointwise
  • robbert/from_option
  • robbert/map_Forall_Exist
  • robbert/map_disjoint_difference
  • robbert/map_filter_True_False
  • robbert/map_fold_foldr
  • robbert/multiset_singleton
  • robbert/new_stuff
  • robbert/rel_decision
  • robbert/set_fold_delete
  • robbert/set_guide
  • robbert/tc_opaque
  • rodolphe/dune-rocq
  • tchajed/stdpp-sprop-gmap
  • coq-stdpp-1.0.0
  • coq-stdpp-1.1.0
  • coq-stdpp-1.10.0
  • coq-stdpp-1.11.0
  • coq-stdpp-1.12.0
  • coq-stdpp-1.2.0
  • coq-stdpp-1.2.1
  • coq-stdpp-1.3.0
  • coq-stdpp-1.4.0
  • coq-stdpp-1.5.0
  • coq-stdpp-1.6.0
  • coq-stdpp-1.7.0
  • coq-stdpp-1.8.0
  • coq-stdpp-1.9.0
46 results

Target

Select target project
  • iris/stdpp
  • johannes/stdpp
  • proux1/stdpp
  • dosualdo/stdpp
  • benoit/coq-stdpp
  • dfrumin/coq-stdpp
  • haidang/stdpp
  • amintimany/coq-stdpp
  • swasey/coq-stdpp
  • simongregersen/stdpp
  • proux/stdpp
  • janno/coq-stdpp
  • amaurremi/coq-stdpp
  • msammler/stdpp
  • tchajed/stdpp
  • YaZko/stdpp
  • maximedenes/stdpp
  • jakobbotsch/stdpp
  • Blaisorblade/stdpp
  • simonspies/stdpp
  • lepigre/stdpp
  • devilhena/stdpp
  • simonfv/stdpp
  • jihgfee/stdpp
  • snyke7/stdpp
  • Armael/stdpp
  • gmalecha/stdpp
  • olaure01/stdpp
  • sarahzrf/stdpp
  • atrieu/stdpp
  • herbelin/stdpp
  • arthuraa/stdpp
  • lgaeher/stdpp
  • mrhaandi/stdpp
  • mattam82/stdpp
  • Quarkbeast/stdpp
  • aa755/stdpp
  • gmevel/stdpp
  • lstefane/stdpp
  • jung/stdpp
  • vsiles/stdpp
  • dlesbre/stdpp
  • bergwerf/stdpp
  • marijnvanwezel/stdpp
  • ivanbakel/stdpp
  • tperami/stdpp
  • adamAndMath/stdpp
  • Villetaneuse/stdpp
  • sanjit/stdpp
  • yiyunliu/stdpp
  • thomas-lamiaux/stdpp
  • Tragicus/stdpp
  • kbedarka/stdpp
53 results
Select Git revision
  • ci-release
  • ci/msammler/_1_2_lemmas
  • ci/msammler/more_feed
  • coq-stdpp-1.0
  • dfrumin/coq-stdpp-set_map_2
  • marijnvanwezel/permutations_submseteq
  • master
  • msammler/bitvector
  • msammler/bool_decide_simpl_never
  • ralf/hint-mode-check
  • ralf/hint-mode-plus
  • ralf/listZ
  • robbert/cbn
  • robbert/f_equiv_pointwise
  • robbert/from_option
  • robbert/gmultiset_positive
  • robbert/map_filter_True_False
  • robbert/multiset_singleton
  • robbert/n_module
  • robbert/new_gmap
  • robbert/set_fold_union
  • robbert/set_guide
  • robbert/simpl_never_pos_n
  • robbert/tc_opaque
  • tchajed/stdpp-sprop-gmap
  • coq-stdpp-1.0.0
  • coq-stdpp-1.1.0
  • coq-stdpp-1.2.0
  • coq-stdpp-1.2.1
  • coq-stdpp-1.3.0
  • coq-stdpp-1.4.0
  • coq-stdpp-1.5.0
  • coq-stdpp-1.6.0
  • coq-stdpp-1.7.0
  • coq-stdpp-1.8.0
35 results
Show changes
This diff is collapsed.
This diff is collapsed.
...@@ -28,7 +28,7 @@ Lemma listset_empty_alt X : X ≡ ∅ ↔ listset_car X = []. ...@@ -28,7 +28,7 @@ Lemma listset_empty_alt X : X ≡ ∅ ↔ listset_car X = [].
Proof. Proof.
destruct X as [l]; split; [|by intros; simplify_eq/=]. destruct X as [l]; split; [|by intros; simplify_eq/=].
rewrite elem_of_equiv_empty; intros Hl. rewrite elem_of_equiv_empty; intros Hl.
destruct l as [|x l]; [done|]. feed inversion (Hl x). left. destruct l as [|x l]; [done|]. oinversion Hl. left.
Qed. Qed.
Global Instance listset_empty_dec (X : listset A) : Decision (X ). Global Instance listset_empty_dec (X : listset A) : Decision (X ).
Proof. Proof.
......
...@@ -109,11 +109,9 @@ Definition mapset_map_with {A B} (f : bool → A → option B) ...@@ -109,11 +109,9 @@ Definition mapset_map_with {A B} (f : bool → A → option B)
match x, y with match x, y with
| Some _, Some a => f true a | None, Some a => f false a | _, None => None | Some _, Some a => f true a | None, Some a => f false a | _, None => None
end) mX. end) mX.
Definition mapset_dom_with {A} (f : A bool) (m : M A) : mapset M := Definition mapset_dom_with {A} (f : A bool) (m : M A) : mapset M :=
Mapset $ merge (λ x _, Mapset $ omap (λ a, if f a then Some () else None) m.
match x with
| Some a => if f a then Some () else None | None => None
end) m (@empty (M A) _).
Lemma lookup_mapset_map_with {A B} (f : bool A option B) X m i : Lemma lookup_mapset_map_with {A B} (f : bool A option B) X m i :
mapset_map_with f X m !! i = m !! i ≫= f (bool_decide (i X)). mapset_map_with f X m !! i = m !! i ≫= f (bool_decide (i X)).
...@@ -126,15 +124,18 @@ Lemma elem_of_mapset_dom_with {A} (f : A → bool) m i : ...@@ -126,15 +124,18 @@ Lemma elem_of_mapset_dom_with {A} (f : A → bool) m i :
i mapset_dom_with f m x, m !! i = Some x f x. i mapset_dom_with f m x, m !! i = Some x f x.
Proof. Proof.
unfold mapset_dom_with, elem_of, mapset_elem_of. unfold mapset_dom_with, elem_of, mapset_elem_of.
simpl. rewrite lookup_merge, lookup_empty. destruct (m !! i) as [a|]; simpl. simpl. rewrite lookup_omap. destruct (m !! i) as [a|]; simpl.
- destruct (Is_true_reflect (f a)); naive_solver. - destruct (Is_true_reflect (f a)); naive_solver.
- naive_solver. - naive_solver.
Qed. Qed.
Local Instance mapset_dom {A} : Dom (M A) (mapset M) := mapset_dom_with (λ _, true).
Local Instance mapset_dom {A} : Dom (M A) (mapset M) := λ m,
Mapset $ fmap (λ _, ()) m.
Local Instance mapset_dom_spec: FinMapDom K M (mapset M). Local Instance mapset_dom_spec: FinMapDom K M (mapset M).
Proof. Proof.
split; try apply _. intros. unfold dom, mapset_dom, is_Some. split; try apply _. intros A m i.
rewrite elem_of_mapset_dom_with; naive_solver. unfold dom, mapset_dom, is_Some, elem_of, mapset_elem_of; simpl.
rewrite lookup_fmap. destruct (m !! i); naive_solver.
Qed. Qed.
End mapset. End mapset.
......
...@@ -4,7 +4,7 @@ From stdpp Require Import options. ...@@ -4,7 +4,7 @@ From stdpp Require Import options.
Definition namespace := list positive. Definition namespace := list positive.
Global Instance namespace_eq_dec : EqDecision namespace := _. Global Instance namespace_eq_dec : EqDecision namespace := _.
Global Instance namespace_countable : Countable namespace := _. Global Instance namespace_countable : Countable namespace := _.
Typeclasses Opaque namespace. Global Typeclasses Opaque namespace.
Definition nroot : namespace := nil. Definition nroot : namespace := nil.
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
(** Coq configuration for std++ (not meant to leak to clients) *) (** Coq configuration for std++ (not meant to leak to clients).
If you are a user of std++, note that importing this file means
you are implicitly opting-in to every new option we will add here
in the future. We are *not* guaranteeing any kind of stability here.
Instead our advice is for you to have your own options file; then
you can re-export the std++ file there but if we ever add an option
you disagree with you can easily overwrite it in one central location. *)
(* Everything here should be [Export Set], which means when this (* Everything here should be [Export Set], which means when this
file is *imported*, the option will only apply on the import site file is *imported*, the option will only apply on the import site
but not transitively. *) but not transitively. *)
Export Set Default Proof Using "Type". (** Allow async proof-checking of sections. *)
#[export] Set Default Proof Using "Type".
(* FIXME: cannot enable this yet as some files disable 'Default Proof Using'. (* FIXME: cannot enable this yet as some files disable 'Default Proof Using'.
Export Set Suggest Proof Using. *) #[export] Set Suggest Proof Using. *)
Export Set Default Goal Selector "!".
(** Enforces that every tactic is executed with a single focused goal, meaning
that bullets and curly braces must be used to structure the proof. *)
#[export] Set Default Goal Selector "!".
(* "Fake" import to whitelist this file for the check that ensures we import (* "Fake" import to whitelist this file for the check that ensures we import
this file everywhere. this file everywhere.
......
This diff is collapsed.
...@@ -113,7 +113,7 @@ Proof. apply _. Qed. ...@@ -113,7 +113,7 @@ Proof. apply _. Qed.
Global Instance pretty_Z : Pretty Z := λ x, Global Instance pretty_Z : Pretty Z := λ x,
match x with match x with
| Z0 => "0" | Zpos x => pretty x | Zneg x => "-" +:+ pretty x | Z0 => "0" | Zpos x => pretty x | Zneg x => "-" +:+ pretty x
end%string. end.
Global Instance pretty_Z_inj : Inj (=@{Z}) (=) pretty. Global Instance pretty_Z_inj : Inj (=@{Z}) (=) pretty.
Proof. Proof.
unfold pretty, pretty_Z. unfold pretty, pretty_Z.
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -17,7 +17,7 @@ Let R {A} (s : string) (m : stringmap A) (n1 n2 : N) := ...@@ -17,7 +17,7 @@ Let R {A} (s : string) (m : stringmap A) (n1 n2 : N) :=
Lemma fresh_string_step {A} s (m : stringmap A) n x : Lemma fresh_string_step {A} s (m : stringmap A) n x :
m !! (s +:+ pretty n) = Some x R s m (1 + n) n. m !! (s +:+ pretty n) = Some x R s m (1 + n) n.
Proof. split; [lia|]. replace (1 + n - 1) with n by lia; eauto. Qed. Proof. split; [lia|]. replace (1 + n - 1) with n by lia; eauto. Qed.
Lemma fresh_string_R_wf {A} s (m : stringmap A) : wf (R s m). Lemma fresh_string_R_wf {A} s (m : stringmap A) : well_founded (R s m).
Proof. Proof.
induction (map_wf m) as [m _ IH]. intros n1; constructor; intros n2 [Hn Hs]. induction (map_wf m) as [m _ IH]. intros n1; constructor; intros n2 [Hn Hs].
specialize (IH _ (delete_subset m (s +:+ pretty (n2 - 1)) Hs) n2). specialize (IH _ (delete_subset m (s +:+ pretty (n2 - 1)) Hs) n2).
......
This diff is collapsed.
This diff is collapsed.