Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
761aefb
Removed redundant suppressions from System.Private.CoreLib
jkurdek Aug 2, 2022
bbbc1e7
Removed redundant suppressions from System.Text.Json
jkurdek Aug 2, 2022
75abc6c
Removed redundant suppressions from System.Net.Http.Json
jkurdek Aug 2, 2022
060a478
Removed redundant suppressions from System.Private.DataContractSerial…
jkurdek Aug 2, 2022
0e6e96a
Removed redundant suppressions from System.Linq.Queryable
jkurdek Aug 2, 2022
8438461
Removed redundant suppressions from System.Reflection.DispatchProxy
jkurdek Aug 2, 2022
3d15fcc
Removed redundant suppressions from System.ComponentModel.TypeConverter
jkurdek Aug 2, 2022
e25790d
Removed redundant suppressions from System.Data.Common
jkurdek Aug 2, 2022
d6b594d
Removed redundant suppressions from Microsoft.CSharp
jkurdek Aug 2, 2022
32162d2
Removed redundant suppressions from Microsoft.VisualBasic.Core
jkurdek Aug 2, 2022
fc0e9d5
Removed redundant suppressions from System.Diagnostics.DiagnosticSource
jkurdek Aug 2, 2022
f3670c2
Apply suggestions from code review
jkurdek Aug 9, 2022
38b6f45
Suggestions from PR review
jkurdek Aug 9, 2022
5a6bb2e
removed omitted local function call
jkurdek Aug 9, 2022
e941d97
Enabled IL2121 in sfx
jkurdek Aug 12, 2022
bedf079
fix suppressions mono + X86
jkurdek Aug 18, 2022
393a6f2
Removed unnecessery suppressions around PInokes
jkurdek Aug 30, 2022
f8209e1
Fixed IL2121 warnings on Linux
jkurdek Aug 30, 2022
9cc221b
Apply suggestions from PR review
jkurdek Sep 6, 2022
d58df4f
Fix redundant suppression after dynamic code annotation
jkurdek Sep 6, 2022
9a0df91
Removed redundant suppressions NativeAot
jkurdek Sep 6, 2022
0c7165d
Reverted change in EventSource, put suppression in ifdef
jkurdek Sep 6, 2022
04dc831
Removed redundant suppressions found on mac/iOS
jkurdek Sep 7, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Reverted change in EventSource, put suppression in ifdef
  • Loading branch information
jkurdek committed Sep 6, 2022
commit 0c7165d5e0c32a86ad235231f3364870f362182c
Original file line number Diff line number Diff line change
Expand Up @@ -3606,6 +3606,13 @@ private static void DebugCheckEvent(ref Dictionary<string, string>? eventsByName
/// </summary>
/// <param name="method">The method to probe.</param>
/// <returns>The literal value or -1 if the value could not be determined. </returns>
#if !NATIVEAOT
[UnconditionalSuppressMessage("ReflectionAnalysis", "IL2026:RequiresUnreferencedCode",
Justification = "The method calls MethodBase.GetMethodBody. Trimming application can change IL of various methods" +
"which can lead to change of behavior. This method only uses this to validate usage of event source APIs." +
"In the worst case it will not be able to determine the value it's looking for and will not perform" +
"any validation.")]
#endif
private static int GetHelperCallFirstArg(MethodInfo method)
{
#if !NATIVEAOT
Expand All @@ -3620,7 +3627,7 @@ private static int GetHelperCallFirstArg(MethodInfo method)
// RET
//
// If we find this pattern we return the XXX. Otherwise we return -1.
byte[] instrs = GetMethodBodyLocal(method)!.GetILAsByteArray()!;
byte[] instrs = method.GetMethodBody()!.GetILAsByteArray()!;
int retVal = -1;
for (int idx = 0; idx < instrs.Length;)
{
Expand Down Expand Up @@ -3722,16 +3729,6 @@ private static int GetHelperCallFirstArg(MethodInfo method)
}
idx++;
}

[UnconditionalSuppressMessage("ReflectionAnalysis", "IL2026:RequiresUnreferencedCode",
Justification = "The method calls MethodBase.GetMethodBody. Trimming application can change IL of various methods" +
"which can lead to change of behavior. This method only uses this to validate usage of event source APIs." +
"In the worst case it will not be able to determine the value it's looking for and will not perform" +
"any validation.")]
static MethodBody? GetMethodBodyLocal(MethodInfo method)
{
return method.GetMethodBody();
}
#endif
return -1;
}
Expand Down