Skip to content

Commit 62566af

Browse files
authored
deprecate: names for deMorgan lemmas (#2837)
1 parent 7d269ca commit 62566af

File tree

2 files changed

+25
-6
lines changed

2 files changed

+25
-6
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,12 @@ Deprecated names
5353
interchange ↦ medial
5454
```
5555

56+
* In `Data.Fin.Properties`:
57+
```agda
58+
¬∀⟶∃¬-smallest ↦ ¬∀⇒∃¬-smallest
59+
¬∀⟶∃¬- ↦ ¬∀⇒∃¬
60+
```
61+
5662
* In `Relation.Nullary.Negation`:
5763
```agda
5864
∃⟶¬∀¬ ↦ ∃⇒¬∀¬

src/Data/Fin/Properties.agda

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1052,20 +1052,20 @@ private
10521052
-- If a decidable predicate P over a finite set is sometimes false,
10531053
-- then we can find the smallest value for which this is the case.
10541054

1055-
¬∀∃¬-smallest : n {p} (P : Pred (Fin n) p) Decidable P
1055+
¬∀∃¬-smallest : n {p} (P : Pred (Fin n) p) Decidable P
10561056
¬ ( i P i) λ i ¬ P i × ((j : Fin′ i) P (inject j))
1057-
¬∀∃¬-smallest zero P P? ¬∀P = contradiction (λ()) ¬∀P
1058-
¬∀∃¬-smallest (suc n) P P? ¬∀P with P? zero
1057+
¬∀∃¬-smallest zero P P? ¬∀P = contradiction (λ()) ¬∀P
1058+
¬∀∃¬-smallest (suc n) P P? ¬∀P with P? zero
10591059
... | false because [¬P₀] = (zero , invert [¬P₀] , λ ())
10601060
... | true because [P₀] = map suc (map id (∀-cons (invert [P₀])))
1061-
(¬∀∃¬-smallest n (P ∘ suc) (P? ∘ suc) (¬∀P ∘ (∀-cons (invert [P₀]))))
1061+
(¬∀∃¬-smallest n (P ∘ suc) (P? ∘ suc) (¬∀P ∘ (∀-cons (invert [P₀]))))
10621062

10631063
-- When P is a decidable predicate over a finite set the following
10641064
-- lemma can be proved.
10651065

1066-
¬∀∃¬ : n {p} (P : Pred (Fin n) p) Decidable P
1066+
¬∀∃¬ : n {p} (P : Pred (Fin n) p) Decidable P
10671067
¬ ( i P i) (∃ λ i ¬ P i)
1068-
¬∀∃¬ n P P? ¬P = map id proj₁ (¬∀∃¬-smallest n P P? ¬P)
1068+
¬∀∃¬ n P P? ¬P = map id proj₁ (¬∀∃¬-smallest n P P? ¬P)
10691069

10701070
------------------------------------------------------------------------
10711071
-- Properties of functions to and from Fin
@@ -1277,3 +1277,16 @@ Please use <⇒<′ instead."
12771277
"Warning: <′⇒≺ was deprecated in v2.0.
12781278
Please use <′⇒< instead."
12791279
#-}
1280+
1281+
-- Version 2.4
1282+
1283+
¬∀⟶∃¬-smallest = ¬∀⇒∃¬-smallest
1284+
{-# WARNING_ON_USAGE ¬∀⟶∃¬-smallest
1285+
"Warning: ¬∀⟶∃¬-smallest was deprecated in v2.4.
1286+
Please use ¬∀⇒∃¬-smallest instead."
1287+
#-}
1288+
¬∀⟶∃¬ = ¬∀⇒∃¬
1289+
{-# WARNING_ON_USAGE ¬∀⟶∃¬
1290+
"Warning: ¬∀⟶∃¬ was deprecated in v2.4.
1291+
Please use ¬∀⇒∃¬ instead."
1292+
#-}

0 commit comments

Comments
 (0)