diff --git a/ICSharpCode.Decompiler/CSharp/Syntax/TypeSystemAstBuilder.cs b/ICSharpCode.Decompiler/CSharp/Syntax/TypeSystemAstBuilder.cs index b4f187319..09af3f02c 100644 --- a/ICSharpCode.Decompiler/CSharp/Syntax/TypeSystemAstBuilder.cs +++ b/ICSharpCode.Decompiler/CSharp/Syntax/TypeSystemAstBuilder.cs @@ -928,8 +928,11 @@ namespace ICSharpCode.Decompiler.CSharp.Syntax } else { - if (IsSpecialConstant(underlyingType, constantValue, out var expr)) + if (!(PrintIntegralValuesAsHex && underlyingType.IsCSharpPrimitiveIntegerType()) + && IsSpecialConstant(underlyingType, constantValue, out var expr)) + { return expr; + } if (underlyingType.IsKnownType(KnownTypeCode.Double) || underlyingType.IsKnownType(KnownTypeCode.Single)) return ConvertFloatingPointLiteral(underlyingType, constantValue); IType literalType = underlyingType;