Skip to content

Commit

Permalink
feat: add Bitvec notation for and/or/xor/not (#5340)
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiasgrosser committed Jun 21, 2023
1 parent 862226b commit 236422b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Mathlib/Data/Bitvec/Defs.lean
Expand Up @@ -131,6 +131,18 @@ protected def xor : Bitvec n → Bitvec n → Bitvec n :=
map₂ xor
#align bitvec.xor Bitvec.xor

instance : Complement (Bitvec n) :=
⟨Bitvec.not⟩

instance : AndOp (Bitvec n) :=
⟨Bitvec.and⟩

instance : OrOp (Bitvec n) :=
⟨Bitvec.or⟩

instance : Xor (Bitvec n) :=
⟨Bitvec.xor⟩

end Bitwise

/-! ### Arithmetic operators -/
Expand Down

0 comments on commit 236422b

Please sign in to comment.