diff --git a/src/compile.rs b/src/compile.rs index 838afe3..3cdcd18 100644 --- a/src/compile.rs +++ b/src/compile.rs @@ -672,7 +672,7 @@ impl Compiler { )); self.enter_scope(); - let mut flags = bytecode::FunctionOpArg::empty(); + let mut flags = bytecode::FunctionOpArg::default(); if have_defaults { flags |= bytecode::FunctionOpArg::HAS_DEFAULTS; } @@ -992,7 +992,7 @@ impl Compiler { // Turn code object into function object: self.emit(Instruction::MakeFunction { - flags: bytecode::FunctionOpArg::NO_NEW_LOCALS, + flags: bytecode::FunctionOpArg::default() & !bytecode::FunctionOpArg::NEW_LOCALS, }); self.emit(Instruction::LoadConst { @@ -1929,7 +1929,7 @@ impl Compiler { // Turn code object into function object: self.emit(Instruction::MakeFunction { - flags: bytecode::FunctionOpArg::empty(), + flags: bytecode::FunctionOpArg::default(), }); // Evaluate iterated item: