From 251f8c5a849137553651430f6fd1ff18d82b0b68 Mon Sep 17 00:00:00 2001 From: Daniel Grunwald Date: Sat, 24 Aug 2019 02:11:59 +0200 Subject: [PATCH] Fix flags+ILRange in ProxyCallReplacer. --- ICSharpCode.Decompiler/IL/Transforms/ProxyCallReplacer.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ICSharpCode.Decompiler/IL/Transforms/ProxyCallReplacer.cs b/ICSharpCode.Decompiler/IL/Transforms/ProxyCallReplacer.cs index 899e383f5..13c87c56b 100644 --- a/ICSharpCode.Decompiler/IL/Transforms/ProxyCallReplacer.cs +++ b/ICSharpCode.Decompiler/IL/Transforms/ProxyCallReplacer.cs @@ -84,10 +84,10 @@ namespace ICSharpCode.Decompiler.IL.Transforms Call newInst = new Call(call.Method.Specialize(inst.Method.Substitution)); // copy flags newInst.ConstrainedTo = call.ConstrainedTo; - newInst.ILStackWasEmpty = call.ILStackWasEmpty; - newInst.IsTail = call.IsTail; + newInst.ILStackWasEmpty = inst.ILStackWasEmpty; + newInst.IsTail = call.IsTail & inst.IsTail; // copy IL ranges - newInst.AddILRange(call); + newInst.AddILRange(inst); newInst.Arguments.ReplaceList(inst.Arguments); inst.ReplaceWith(newInst); }