source
theorem Array.isEqv_iff_rel {α : Type u_1} {xs ys : Array α} {r : α → α → Bool} :
xs.isEqv ys r = true ↔ ∃ (h : xs.size = ys.size), ∀ (i : Nat) (h' : i < xs.size), r xs[i] ys[i] = true
source
theorem Array.isEqv_eq_decide {α : Type u_1} (xs ys : Array α) (r : α → α → Bool) :
xs.isEqv ys r = if h : xs.size = ys.size then decide (∀ (i : Nat) (h' : i < xs.size), r xs[i] ys[i] = true) else false
source
@[simp]
theorem Array.isEqv_toList {α : Type u_1} {r : α → α → Bool} [BEq α] (xs ys : Array α) :
xs.toList.isEqv ys.toList r = xs.isEqv ys r
source
theorem Array.eq_of_isEqv {α : Type u_1} [DecidableEq α] (xs ys : Array α) (h : (xs.isEqv ys fun (x y : α) => decide (x = y)) = true) :
xs = ys
source
theorem Array.isEqv_self_beq {α : Type u_1} [BEq α] [ReflBEq α] (xs : Array α) :
(xs.isEqv xs fun (x1 x2 : α) => x1 == x2) = true
source
theorem Array.isEqv_self {α : Type u_1} [DecidableEq α] (xs : Array α) :
(xs.isEqv xs fun (x1 x2 : α) => decide (x1 = x2)) = true
source
instance Array.instDecidableEq {α : Type u_1} [DecidableEq α] :
DecidableEq (Array α)
Equations

- xs.instDecidableEq ys = match h : xs.isEqv ys fun (a b : α) => decide (a = b) with | true => isTrue ⋯ | false => isFalse ⋯

source
theorem Array.beq_eq_decide {α : Type u_1} [BEq α] (xs ys : Array α) :
(xs == ys) = if h : xs.size = ys.size then decide (∀ (i : Nat) (h' : i < xs.size), (xs[i] == ys[i]) = true) else false
source
@[simp]
theorem Array.beq_toList {α : Type u_1} [BEq α] (xs ys : Array α) :
(xs.toList == ys.toList) = (xs == ys)
source
@[simp]
theorem List.isEqv_toArray {α : Type u_1} {r : α → α → Bool} [BEq α] (as bs : List α) :
as.toArray.isEqv bs.toArray r = as.isEqv bs r
source
@[simp]
theorem List.beq_toArray {α : Type u_1} [BEq α] (as bs : List α) :
(as.toArray == bs.toArray) = (as == bs)
source
instance Array.instReflBEq {α : Type u_1} [BEq α] [ReflBEq α] :
ReflBEq (Array α)
source
instance Array.instLawfulBEq {α : Type u_1} [BEq α] [LawfulBEq α] :
LawfulBEq (Array α)