mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-19 14:01:08 +01:00
[msl] clean up emitted expressions at the end of a block
This commit is contained in:
1 parent
62fe72be2e
commit
cf3a6da3ce
1 file changed
+10
@@ -969,6 +969,16 @@ impl<W: Write> Writer<W> {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// un-emit expressions
|
||||
//TODO: take care of loop/continuing?
|
||||
for statement in statements {
|
||||
if let crate::Statement::Emit(ref range) = *statement {
|
||||
for handle in range.clone() {
|
||||
self.named_expressions.remove(handle.index());
|
||||
}
|
||||
}
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user