File tree 2 files changed +10
-0
lines changed
src/Data/List/Relation/Unary/First
2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -448,6 +448,11 @@ Other minor additions
448
448
all-upTo : All (_< n) (upTo n)
449
449
```
450
450
451
+ * Added new proof in ` Data.List.Relation.Unary.First.Properties ` :
452
+ ``` agda
453
+ cofirst? : Decidable P → Decidable (First (∁ P) P)
454
+ ```
455
+
451
456
* Added new operations in ` Data.List.Relation.Unary.Linked ` :
452
457
``` agda
453
458
head′ : Linked R (x ∷ xs) → Connected R (just x) (head xs)
Original file line number Diff line number Diff line change @@ -85,6 +85,11 @@ module _ {a p} {A : Set a} {P : Pred A p} where
85
85
$ Sum.map₂ (All⇒¬First contradiction)
86
86
$ first (Sum.fromDec ∘ P?) xs
87
87
88
+ cofirst? : Decidable P → Decidable (First (∁ P) P)
89
+ cofirst? P? xs = Sum.toDec
90
+ $ Sum.map₂ (All⇒¬First id)
91
+ $ first (Sum.swap ∘ Sum.fromDec ∘ P?) xs
92
+
88
93
------------------------------------------------------------------------
89
94
-- Conversion to Any
90
95
You can’t perform that action at this time.
0 commit comments