Skip to content

Commit 12ad5a5

Browse files
committed
[Refractor] contradiction over ⊥-elim in ×-antisymmetric def
1 parent 5701c9d commit 12ad5a5

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

src/Data/Product/Relation/Binary/Lex/NonStrict.agda

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
module Data.Product.Relation.Binary.Lex.NonStrict where
1313

1414
open import Data.Product.Base using (_×_; _,_; proj₁; proj₂)
15+
open import Data.Product.Relation.Binary.Pointwise.NonDependent as Pointwise
16+
using (Pointwise)
17+
import Data.Product.Relation.Binary.Lex.Strict as Strict
1518
open import Data.Sum.Base using (inj₁; inj₂)
1619
open import Level using (Level)
1720
open import Relation.Binary.Core using (Rel; _⇒_)
@@ -24,9 +27,7 @@ open import Relation.Binary.Definitions
2427
; Irreflexive; Asymmetric; _Respects₂_; tri<; tri>; tri≈)
2528
open import Relation.Binary.Consequences
2629
import Relation.Binary.Construct.NonStrictToStrict as Conv
27-
open import Data.Product.Relation.Binary.Pointwise.NonDependent as Pointwise
28-
using (Pointwise)
29-
import Data.Product.Relation.Binary.Lex.Strict as Strict
30+
3031

3132
private
3233
variable

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

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,9 @@ open import Data.Product.Base
1515
open import Data.Product.Relation.Binary.Pointwise.NonDependent as Pointwise
1616
using (Pointwise)
1717
open import Data.Sum.Base using (inj₁; inj₂; _-⊎-_; [_,_])
18-
open import Data.Empty using (⊥-elim)
1918
open import Function.Base using (flip; _on_; _$_; _∘_)
2019
open import Induction.WellFounded using (Acc; acc; WfRec; WellFounded; Acc-resp-flip-≈)
2120
open import Level using (Level)
22-
open import Relation.Nullary.Decidable using (yes; no; _⊎-dec_; _×-dec_)
2321
open import Relation.Binary.Core using (Rel; _⇒_)
2422
open import Relation.Binary.Bundles
2523
using (Preorder; StrictPartialOrder; StrictTotalOrder)
@@ -31,6 +29,8 @@ open import Relation.Binary.Definitions
3129
; tri<; tri>; tri≈)
3230
open import Relation.Binary.Consequences using (asym⇒irr)
3331
open import Relation.Binary.PropositionalEquality.Core as ≡ using (_≡_)
32+
open import Relation.Nullary.Decidable using (yes; no; _⊎-dec_; _×-dec_)
33+
open import Relation.Nullary.Negation using (contradiction)
3434

3535
private
3636
variable
@@ -134,11 +134,11 @@ module _ {_≈₁_ : Rel A ℓ₁} {_<₁_ : Rel A ℓ₂}
134134
where
135135
antisym : Antisymmetric _≋_ _<ₗₑₓ_
136136
antisym (inj₁ x₁<y₁) (inj₁ y₁<x₁) =
137-
⊥-elim $ asym₁ x₁<y₁ y₁<x₁
137+
contradiction y₁<x₁ (asym₁ x₁<y₁)
138138
antisym (inj₁ x₁<y₁) (inj₂ y≈≤x) =
139-
⊥-elim $ irrefl₁ (sym₁ $ proj₁ y≈≤x) x₁<y₁
139+
contradiction x₁<y₁ (irrefl₁ (sym₁ $ proj₁ y≈≤x))
140140
antisym (inj₂ x≈≤y) (inj₁ y₁<x₁) =
141-
⊥-elim $ irrefl₁ (sym₁ $ proj₁ x≈≤y) y₁<x₁
141+
contradiction y₁<x₁ (irrefl₁ (sym₁ $ proj₁ x≈≤y))
142142
antisym (inj₂ x≈≤y) (inj₂ y≈≤x) =
143143
proj₁ x≈≤y , antisym₂ (proj₂ x≈≤y) (proj₂ y≈≤x)
144144

0 commit comments

Comments
 (0)