fix: Nat.and_distrib_right -> Nat.and_or_distrib_right (#10649)

This PR renames `Nat.and_distrib_right` to `Nat.and_or_distrib_right`.
This is to make the name consistent with other theorems in the same file
(e.g. `Nat.and_or_distrib_left`).
This commit is contained in:
François G. Dorais 2025-10-07 08:57:46 -04:00 committed by GitHub
parent 8655f7706f
commit 8cebe691a2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -591,10 +591,13 @@ theorem and_or_distrib_left (x y z : Nat) : x &&& (y ||| z) = (x &&& y) ||| (x &
simp [Bool.and_or_distrib_left]
@[grind =]
theorem and_distrib_right (x y z : Nat) : (x ||| y) &&& z = (x &&& z) ||| (y &&& z) := by
theorem and_or_distrib_right (x y z : Nat) : (x ||| y) &&& z = (x &&& z) ||| (y &&& z) := by
apply Nat.eq_of_testBit_eq
simp [Bool.and_or_distrib_right]
@[deprecated and_or_distrib_right (since := "2025-10-02")]
abbrev and_distrib_right := and_or_distrib_right
theorem or_and_distrib_left (x y z : Nat) : x ||| (y &&& z) = (x ||| y) &&& (x ||| z) := by
apply Nat.eq_of_testBit_eq
simp [Bool.or_and_distrib_left]