Skip to content

Commit d917dbc

Browse files
committed
Clippy
1 parent 1c6a0fc commit d917dbc

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

crates/codegen/src/compile.rs

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -236,12 +236,6 @@ pub fn compile_expression(
236236
}
237237

238238
macro_rules! emit {
239-
($c:expr, Instruction::$op:ident { $arg:ident$(,)? }$(,)?) => {
240-
$c.emit_arg($arg, |x| Instruction::$op { $arg: x })
241-
};
242-
($c:expr, Instruction::$op:ident { $arg:ident : $arg_val:expr $(,)? }$(,)?) => {
243-
$c.emit_arg($arg_val, |x| Instruction::$op { $arg: x })
244-
};
245239
($c:expr, Instruction::$op:ident( $arg_val:expr $(,)? )$(,)?) => {
246240
$c.emit_arg($arg_val, Instruction::$op)
247241
};
@@ -5127,12 +5121,12 @@ impl Compiler {
51275121

51285122
fn emit_load_const(&mut self, constant: ConstantData) {
51295123
let idx = self.arg_constant(constant);
5130-
self.emit_arg(idx, |idx| Instruction::LoadConst(idx))
5124+
self.emit_arg(idx, Instruction::LoadConst)
51315125
}
51325126

51335127
fn emit_return_const(&mut self, constant: ConstantData) {
51345128
let idx = self.arg_constant(constant);
5135-
self.emit_arg(idx, |idx| Instruction::ReturnConst(idx))
5129+
self.emit_arg(idx, Instruction::ReturnConst)
51365130
}
51375131

51385132
fn emit_return_value(&mut self) {

0 commit comments

Comments
 (0)