From 56f6908020ae5ceba3ff5ec4e4d4cd887606bdba Mon Sep 17 00:00:00 2001 From: Benjamin Bouvier Date: Thu, 4 Jul 2019 17:48:55 +0200 Subject: [PATCH] [meta] Legalization: Don't generate a variable for replaced instructions; (since they're unused) --- cranelift/codegen/meta/src/gen_legalizer.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cranelift/codegen/meta/src/gen_legalizer.rs b/cranelift/codegen/meta/src/gen_legalizer.rs index 554ae13e22..b09a06a333 100644 --- a/cranelift/codegen/meta/src/gen_legalizer.rs +++ b/cranelift/codegen/meta/src/gen_legalizer.rs @@ -290,8 +290,7 @@ fn emit_dst_inst(def: &Def, def_pool: &DefPool, var_pool: &VarPool, fmt: &mut Fo // Unwrapping would have left the results intact. Replace the whole instruction. fmtln!( fmt, - "let {} = pos.func.dfg.replace(inst).{};", - defined_vars, + "pos.func.dfg.replace(inst).{};", def.apply.rust_builder(&def.defined_vars, var_pool) );