Skip to content

Commit

Permalink
Add Eq trait to bit vectors (#17)
Browse files Browse the repository at this point in the history
For other vector types, you are unable to have Eq because they would be comparing floating point numbers. Bit vectors don't have this problem though and should allow for Eq comparisons.
  • Loading branch information
KolCrooks authored Jul 16, 2024
1 parent 4fa232b commit 8eca023
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/bit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use crate::diesel_ext::bit::BitType;
use diesel::{deserialize::FromSqlRow, expression::AsExpression};

/// A bit string.
#[derive(Clone, Debug, PartialEq)]
#[derive(Clone, Debug, PartialEq, Eq)]
#[cfg_attr(feature = "diesel", derive(FromSqlRow, AsExpression))]
#[cfg_attr(feature = "diesel", diesel(sql_type = BitType))]
pub struct Bit {
Expand Down

0 comments on commit 8eca023

Please sign in to comment.