mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-04 15:45:25 +00:00
LibJS: Add bytecode ops for &, | and ^
This commit is contained in:
@@ -79,6 +79,15 @@ Optional<Bytecode::Register> BinaryExpression::generate_bytecode(Bytecode::Gener
|
||||
case BinaryOp::AbstractEquals:
|
||||
generator.emit<Bytecode::Op::AbstractEquals>(dst_reg, *lhs_reg, *rhs_reg);
|
||||
return dst_reg;
|
||||
case BinaryOp::BitwiseAnd:
|
||||
generator.emit<Bytecode::Op::BitwiseAnd>(dst_reg, *lhs_reg, *rhs_reg);
|
||||
return dst_reg;
|
||||
case BinaryOp::BitwiseOr:
|
||||
generator.emit<Bytecode::Op::BitwiseOr>(dst_reg, *lhs_reg, *rhs_reg);
|
||||
return dst_reg;
|
||||
case BinaryOp::BitwiseXor:
|
||||
generator.emit<Bytecode::Op::BitwiseXor>(dst_reg, *lhs_reg, *rhs_reg);
|
||||
return dst_reg;
|
||||
default:
|
||||
TODO();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user