Skip to content

Commit

Permalink
Merge branch 'master' into lists
Browse files Browse the repository at this point in the history
  • Loading branch information
klinashka authored Dec 19, 2024
2 parents b692f2f + 70b331f commit 37eccfc
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 10 deletions.
13 changes: 4 additions & 9 deletions code/Decidability/DiscreteTypes.v
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
Require Import init.imports.
Require Import UniMath.Combinatorics.Lists.
Require Import UniMath.Combinatorics.MoreLists.
Require Import Inductive.Option.

Section EqualityDeciders.

Expand Down Expand Up @@ -138,12 +141,4 @@ Section ClosureProperties.
* exact inr.
Qed.




End ClosureProperties.


Section ChoiceFunction.

End ChoiceFunction.
End ClosureProperties.
22 changes: 21 additions & 1 deletion code/Inductive/Option.v
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
(* Definition of an option as the coproduct of a type X with the unit type *)

(* Definition of an option as the coproduct of a type X with the unit type *)
Require Import init.imports.

Section Option.
Expand All @@ -10,3 +10,23 @@ Section Option.
Definition none {X : UU} : @option X := (ii2 tt).

End Option.

Section PathProperties.

Lemma nopathssomenone {X : UU} (x : X) : ¬ ((some x) = none).
Proof.
apply negpathsii1ii2.
Qed.

Lemma nopathsnonesome {X : UU} (x : X) : ¬ (none = (some x)).
Proof.
apply negpathsii2ii1.
Qed.

Lemma some_injectivity {X : UU} (x y : X) : (some x = some y) → x = y.
Proof.
apply ii1_injectivity.
Qed.


End PathProperties.
2 changes: 2 additions & 0 deletions code/_CoqProject
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,13 @@ COQC = coqc
COQDEP = coqdep
-R . "sem"


-arg "-w -notation-overridden -type-in-type -noinit"

init/imports.v
init/all.v


Inductive/ListProperties.v
Inductive/Option.v

Expand Down

0 comments on commit 37eccfc

Please sign in to comment.