mirror of
https://github.com/erg-lang/erg.git
synced 2025-09-29 04:24:43 +00:00
Update codegen.rs
This commit is contained in:
parent
357d687324
commit
26d0258d5e
1 changed files with 5 additions and 0 deletions
|
@ -951,6 +951,11 @@ impl CodeGenerator {
|
|||
}
|
||||
TokenKind::LeftOpen | TokenKind::Closed | TokenKind::Open => todo!(),
|
||||
TokenKind::InOp => {
|
||||
// if no-std, always `x in y == True`
|
||||
if self.cfg.no_std {
|
||||
self.emit_load_const(true);
|
||||
return;
|
||||
}
|
||||
if !self.in_op_loaded {
|
||||
self.emit_global_import_items(
|
||||
Identifier::public("_erg_std_prelude"),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue