diff --git a/dnSpy/dnSpy.Decompiler/CSharp/CSharpFormatter.cs b/dnSpy/dnSpy.Decompiler/CSharp/CSharpFormatter.cs index 7bd1e1f093..1b9f5c7f0b 100644 --- a/dnSpy/dnSpy.Decompiler/CSharp/CSharpFormatter.cs +++ b/dnSpy/dnSpy.Decompiler/CSharp/CSharpFormatter.cs @@ -1306,6 +1306,10 @@ public void WriteToolTip(ISourceVariable? variable) { OutputWrite(isLocal ? dnSpy_Decompiler_Resources.ToolTip_Local : dnSpy_Decompiler_Resources.ToolTip_Parameter, BoxedTextColor.Text); OutputWrite(DescriptionParenClose, BoxedTextColor.Punctuation); WriteSpace(); + if (pd is not null && pd.CustomAttributes.IsDefined("System.ParamArrayAttribute")) { + OutputWrite(Keyword_params, BoxedTextColor.Keyword); + WriteSpace(); + } Write(variable.Type, !isLocal ? pd : null, null, null, forceReadOnly: (variable.Flags & SourceVariableFlags.ReadOnlyReference) != 0, attributeProvider: pd); WriteSpace(); WriteIdentifier(TypeFormatterUtils.GetName(variable), isLocal ? BoxedTextColor.Local : BoxedTextColor.Parameter); diff --git a/dnSpy/dnSpy.Decompiler/VisualBasic/VisualBasicFormatter.cs b/dnSpy/dnSpy.Decompiler/VisualBasic/VisualBasicFormatter.cs index 2e1d9c1a5a..556df3c52d 100644 --- a/dnSpy/dnSpy.Decompiler/VisualBasic/VisualBasicFormatter.cs +++ b/dnSpy/dnSpy.Decompiler/VisualBasic/VisualBasicFormatter.cs @@ -1106,6 +1106,10 @@ public void WriteToolTip(ISourceVariable? variable) { OutputWrite(Keyword_ByRef, BoxedTextColor.Keyword); WriteSpace(); } + if (pd is not null && pd.CustomAttributes.IsDefined("System.ParamArrayAttribute")) { + OutputWrite(Keyword_params, BoxedTextColor.Keyword); + WriteSpace(); + } WriteIdentifier(TypeFormatterUtils.GetName(variable), isLocal ? BoxedTextColor.Local : BoxedTextColor.Parameter); if (pd is not null) WriteToken(pd);