Skip to content

Commit

Permalink
Invoke both strict_eq and PartialEq as sanity check
Browse files Browse the repository at this point in the history
  • Loading branch information
null-dev committed Oct 21, 2024
1 parent 951326b commit d10995c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion jaq-core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,8 @@ impl<F: FilterT> Filter<F> {
impl <V: ValT> PartialEq for StrictEq<V> {
fn eq(&self, other: &Self) -> bool {
match (&self.0, &other.0) {
(Ok(a), Ok(b)) => a.strict_eq(b),
// Sanity check: invoke both strict_eq and PartialEq
(Ok(a), Ok(b)) => a == b && a.strict_eq(b),
(Err(a), Err(b)) => a == b,
_ => false,
}
Expand Down

0 comments on commit d10995c

Please sign in to comment.