Merge pull request #840 from mirkootter/master

This commit is contained in:
Jon Kelley 2023-02-22 12:40:06 -08:00 committed by GitHub
commit 133e2b4d05
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View file

@ -108,6 +108,12 @@ impl<T> Coroutine<T> {
}
}
impl<T> PartialEq for Coroutine<T> {
fn eq(&self, other: &Self) -> bool {
self.task == other.task
}
}
#[cfg(test)]
mod tests {
#![allow(unused)]

View file

@ -329,7 +329,7 @@ impl PartialEq<bool> for &UseState<bool> {
}
}
impl<T: PartialEq> PartialEq<UseState<T>> for UseState<T> {
impl<T> PartialEq<UseState<T>> for UseState<T> {
fn eq(&self, other: &UseState<T>) -> bool {
Rc::ptr_eq(&self.current_val, &other.current_val)
}