Skip to content

Commit

Permalink
Switch __ObservableValidatorHelper to [UnconditionalSuppressMessage]
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergio0694 committed Aug 2, 2022
1 parent c80930f commit 321fc50
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ public static class __ObservableValidatorHelper
/// <param name="propertyName">The name of the property to validate.</param>
[EditorBrowsable(EditorBrowsableState.Never)]
[Obsolete("This method is not intended to be called directly by user code")]
[RequiresUnreferencedCode("The type of the current instance cannot be statically discovered.")]
[UnconditionalSuppressMessage(
"ReflectionAnalysis",
"IL2026:RequiresUnreferencedCode",
Justification = "This helper is called by generated code from public APIs that have the proper annotations already (and we don't want generated code to produce warnings that developers cannot fix).")]
public static void ValidateProperty(ObservableValidator instance, object? value, string propertyName)
{
instance.ValidateProperty(value, propertyName);
Expand Down

0 comments on commit 321fc50

Please sign in to comment.