mirror of
https://github.com/DioxusLabs/dioxus
synced 2024-12-19 00:53:12 +00:00
21 lines
389 B
Rust
21 lines
389 B
Rust
use std::hash::Hash;
|
|
|
|
use crate::ScopeId;
|
|
|
|
#[derive(Debug, Clone, Eq, PartialOrd, Ord)]
|
|
pub struct DirtyScope {
|
|
pub height: u32,
|
|
pub id: ScopeId,
|
|
}
|
|
|
|
impl PartialEq for DirtyScope {
|
|
fn eq(&self, other: &Self) -> bool {
|
|
self.id == other.id
|
|
}
|
|
}
|
|
|
|
impl Hash for DirtyScope {
|
|
fn hash<H: std::hash::Hasher>(&self, state: &mut H) {
|
|
self.id.hash(state);
|
|
}
|
|
}
|