From 437d8fe2d21262a91454126375d5e2013119b140 Mon Sep 17 00:00:00 2001 From: Daniel Grunwald Date: Sun, 30 Aug 2026 23:19:21 +0200 Subject: [PATCH] Remove the value type special case from the expression builder's variable-type-replacement. With the recent improvements, value type variables are guaranteed to already have the correct type in the ILAst, so we no longer need these hacks. --- ICSharpCode.Decompiler/CSharp/ExpressionBuilder.cs | 2 -- 1 file changed, 2 deletions(-) diff --git a/ICSharpCode.Decompiler/CSharp/ExpressionBuilder.cs b/ICSharpCode.Decompiler/CSharp/ExpressionBuilder.cs index deab86cdb..15e4e3057 100644 --- a/ICSharpCode.Decompiler/CSharp/ExpressionBuilder.cs +++ b/ICSharpCode.Decompiler/CSharp/ExpressionBuilder.cs @@ -907,8 +907,6 @@ namespace ICSharpCode.Decompiler.CSharp bool CanUseTypeForStackSlot(ILVariable v, IType type) { return v.IsSingleDefinition - || IsOtherValueType(type) - || v.StackType == StackType.Ref || AllStoresUseConsistentType(v.StoreInstructions, type); }