mirror of
https://github.com/RustPython/Parser.git
synced 2025-07-16 09:35:19 +00:00
Fix some minor things required for unittest
This commit is contained in:
parent
f9fe1c0423
commit
a251109090
1 changed files with 3 additions and 1 deletions
|
@ -479,7 +479,9 @@ impl<O: OutputStream> Compiler<O> {
|
|||
|
||||
self.compile_statements(body)?;
|
||||
|
||||
for end_label in end_labels {
|
||||
// sort of "stack up" the layers of with blocks:
|
||||
// with a, b: body -> start_with(a) start_with(b) body() end_with(b) end_with(a)
|
||||
for end_label in end_labels.into_iter().rev() {
|
||||
self.emit(Instruction::PopBlock);
|
||||
self.emit(Instruction::EnterFinally);
|
||||
self.set_label(end_label);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue