We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 302a325 commit 414fc4eCopy full SHA for 414fc4e
1 file changed
libcc2rs/src/rc.rs
@@ -1076,7 +1076,10 @@ where
1076
}
1077
1078
fn equals(&self, other: &dyn ErasedPtr) -> bool {
1079
- other.as_any().downcast_ref::<Ptr<T>>() == Some(self)
+ if let Some(o) = other.as_any().downcast_ref::<Ptr<T>>() {
1080
+ return o == self;
1081
+ }
1082
+ self.as_bytes() == other.as_bytes()
1083
1084
1085
fn is_null(&self) -> bool {
0 commit comments