Skip to content

Commit 70f3f0f

Browse files
Revert "[ refactor ] fix #2865 for v2.4 (#2954)" (#2973)
This reverts commit 7847620.
1 parent 760b08e commit 70f3f0f

3 files changed

Lines changed: 8 additions & 37 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -104,11 +104,6 @@ Deprecated names
104104
witness ↦ satisfiable
105105
```
106106

107-
* In `Data.List.Relation.Unary.Any`:
108-
```agda
109-
satisfiable ↦ satisfiable⁺
110-
```
111-
112107
* In `Data.Rational.Properties`:
113108
```agda
114109
nonPos*nonPos⇒nonPos ↦ nonPos*nonPos⇒nonNeg
@@ -333,7 +328,7 @@ Additions to existing modules
333328

334329
* In `Data.List.NonEmpty.Relation.Unary.All`:
335330
```
336-
map : P ⊆ Q → All P All Q
331+
map : P ⊆ Q → All P xs → All Q xs
337332
```
338333

339334
* In `Data.List.Properties`:
@@ -343,11 +338,6 @@ Additions to existing modules
343338
filter-swap : filter P? ∘ filter Q? ≗ filter Q? ∘ filter P?
344339
```
345340

346-
* In `Data.List.Relation.Unary.Any`:
347-
```agda
348-
satisfiable⁻ : Satisfiable (Any P) → Satisfiable P
349-
```
350-
351341
* In `Data.Nat.Divisibility`:
352342
```agda
353343
m∣n⇒m^o∣n^o : ∀ o → m ∣ n → m ^ o ∣ n ^ o

src/Data/List/NonEmpty/Relation/Unary/Any.agda

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,6 @@ map g (there pxs) = there (List.map g pxs)
4242
------------------------------------------------------------------------
4343
-- Predicates
4444

45-
satisfiable : Any P xs Satisfiable P
46-
satisfiable (here px) = _ , px
47-
satisfiable (there pxs) = List.satisfied pxs
45+
satisfied : Any P xs Satisfiable P
46+
satisfied (here px) = _ , px
47+
satisfied (there pxs) = List.satisfied pxs

src/Data/List/Relation/Unary/Any.agda

Lines changed: 4 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,7 @@ infixl 4 _─_
6969
_─_ : {P : Pred A p} xs Any P xs List A
7070
xs ─ x∈xs = removeAt xs (index x∈xs)
7171

72-
-- If any element satisfies P, then P is satisfiable.
73-
74-
-- v2.4 `satisfied` is being retained for compatibility reasons,
75-
-- while `satisfiable` below is renamed to `satisfiable⁺`
76-
-- v3.0 `satisfied` will be renamed to `satisfiable`
72+
-- If any element satisfies P, then P is satisfied.
7773

7874
satisfied : Any P xs Satisfiable P
7975
satisfied (here px) = _ , px
@@ -94,16 +90,12 @@ any? : Decidable P → Decidable (Any P)
9490
any? P? [] = no λ()
9591
any? P? (x ∷ xs) = Dec.map′ fromSum toSum (P? x ⊎? any? P? xs)
9692

97-
satisfiable⁺ : Satisfiable P Satisfiable (Any P)
98-
satisfiable⁺ (x , Px) = [ x ] , here Px
99-
100-
satisfiable⁻ : Satisfiable (Any P) Satisfiable P
101-
satisfiable⁻ (x ∷ _ , here px) = x , px
102-
satisfiable⁻ (_ ∷ xs , there pxs) = satisfiable⁻ (xs , pxs)
93+
satisfiable : Satisfiable P Satisfiable (Any P)
94+
satisfiable (x , Px) = [ x ] , here Px
10395

10496

10597
------------------------------------------------------------------------
106-
-- DEPRECATED NAMES
98+
-- DEPRECATED
10799
------------------------------------------------------------------------
108100
-- Please use the new names as continuing support for the old names is
109101
-- not guaranteed.
@@ -115,14 +107,3 @@ any = any?
115107
"Warning: any was deprecated in v1.4.
116108
Please use any? instead."
117109
#-}
118-
119-
-- Version 2.4
120-
121-
satisfiable = satisfiable⁺
122-
{-# WARNING_ON_USAGE satisfiable
123-
"Warning: satisfiable was deprecated in v2.4.
124-
Please use satisfiable⁺ instead. Moreover,
125-
the name satisfied will be renamed in v3.0
126-
to satisfiable, so users should refactor
127-
as soon as they can."
128-
#-}

0 commit comments

Comments
 (0)