mirror of
https://github.com/erg-lang/erg.git
synced 2025-10-02 21:44:34 +00:00
Fix if codegen bugs
This commit is contained in:
parent
cafdd8ac35
commit
08a92bbbc1
11 changed files with 101 additions and 50 deletions
|
@ -149,6 +149,10 @@ impl CommonOpcode {
|
|||
pub const fn take_arg(&self) -> bool {
|
||||
90 <= (*self as u8) && (*self as u8) < 220
|
||||
}
|
||||
|
||||
pub fn is_jump_op(op: u8) -> bool {
|
||||
[93, 110, 111, 112, 113, 114, 115, 140, 143, 175, 176].contains(&op)
|
||||
}
|
||||
}
|
||||
|
||||
impl_u8_enum! {CompareOp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue