Skip to content

Commit fceac19

Browse files
authored
Making (more) arguments implicit in lexicographic ordering lemmas
1 parent c8df3c4 commit fceac19

File tree

3 files changed

+11
-8
lines changed

3 files changed

+11
-8
lines changed

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -784,6 +784,9 @@ Non-backwards compatible changes
784784
properties about the orderings themselves the second index must be provided
785785
explicitly.
786786

787+
* The argument `xs` in `xs≮[]` in `Data.{List|Vec}.Relation.Binary.Lex.Strict`
788+
introduced in PRs #1648 and #1672 has now been made implicit.
789+
787790
* Issue #2075 (Johannes Waldmann): wellfoundedness of the lexicographic ordering
788791
on products, defined in `Data.Product.Relation.Binary.Lex.Strict`, no longer
789792
requires the assumption of symmetry for the first equality relation `_≈₁_`,
@@ -2705,7 +2708,7 @@ Other minor changes
27052708

27062709
* Added new proofs in `Data.Vec.Relation.Binary.Lex.Strict`:
27072710
```agda
2708-
xs≮[] : ∀ {n} (xs : Vec A n) → ¬ xs < []
2711+
xs≮[] : {xs : Vec A n} → ¬ xs < []
27092712
<-respectsˡ : IsPartialEquivalence _≈_ → _≺_ Respectsˡ _≈_ →
27102713
∀ {m n} → _Respectsˡ_ (_<_ {m} {n}) _≋_
27112714
<-respectsʳ : IsPartialEquivalence _≈_ → _≺_ Respectsʳ _≈_ →

src/Data/List/Relation/Binary/Lex/Strict.agda

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,11 +51,11 @@ module _ {a ℓ₁ ℓ₂} {A : Set a} where
5151
_≋_ = Pointwise _≈_
5252
_<_ = Lex-< _≈_ _≺_
5353

54-
xs≮[] : xs ¬ xs < []
55-
xs≮[] _ (base ())
54+
xs≮[] : {xs} ¬ xs < []
55+
xs≮[] (base ())
5656

5757
¬[]<[] : ¬ [] < []
58-
¬[]<[] = xs≮[] []
58+
¬[]<[] = xs≮[]
5959

6060
<-irreflexive : Irreflexive _≈_ _≺_ Irreflexive _≋_ _<_
6161
<-irreflexive irr (x≈y ∷ xs≋ys) (this x<y) = irr x≈y x<y

src/Data/Vec/Relation/Binary/Lex/Strict.agda

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,11 @@ module _ {_≈_ : Rel A ℓ₁} {_≺_ : Rel A ℓ₂} where
6969
_≋_ = Pointwise _≈_
7070
_<_ = Lex-< _≈_ _≺_
7171

72-
xs≮[] : {n} (xs : Vec A n) ¬ xs < []
73-
xs≮[] _ (base ())
72+
xs≮[] : {n} {xs : Vec A n} ¬ xs < []
73+
xs≮[] (base ())
7474

7575
¬[]<[] : ¬ [] < []
76-
¬[]<[] = xs≮[] []
76+
¬[]<[] = xs≮[]
7777

7878
module _ (≺-irrefl : Irreflexive _≈_ _≺_) where
7979

@@ -134,7 +134,7 @@ module _ {_≈_ : Rel A ℓ₁} {_≺_ : Rel A ℓ₂} where
134134
where
135135

136136
<-wellFounded : {n} WellFounded (_<_ {n})
137-
<-wellFounded {0} [] = acc λ ys ys<[] ⊥-elim (xs≮[] ys ys<[])
137+
<-wellFounded {0} [] = acc λ ys ys<[] ⊥-elim (xs≮[] ys<[])
138138
<-wellFounded {suc n} xs = Subrelation.wellFounded <⇒uncons-Lex uncons-Lex-wellFounded xs
139139
where
140140
<⇒uncons-Lex : {xs ys : Vec A (suc n)} xs < ys (×-Lex _≈_ _≺_ _<_ on uncons) xs ys

0 commit comments

Comments
 (0)