mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
simplify logic of Entry.is_valid
This commit is contained in:
@@ -40,17 +40,15 @@ mod compat {
|
||||
}
|
||||
|
||||
fn is_valid(&self) -> bool {
|
||||
if self.expected.is_none() {
|
||||
return true;
|
||||
}
|
||||
if let Some(expected_bgl) = self.expected.as_ref() {
|
||||
if let Some(assigned_bgl) = self.assigned.as_ref() {
|
||||
if expected_bgl.is_equal(assigned_bgl) {
|
||||
return true;
|
||||
}
|
||||
expected_bgl.is_equal(assigned_bgl)
|
||||
} else {
|
||||
false
|
||||
}
|
||||
} else {
|
||||
true
|
||||
}
|
||||
false
|
||||
}
|
||||
|
||||
fn is_incompatible(&self) -> bool {
|
||||
|
||||
Reference in New Issue
Block a user