Skip to content

Commit

Permalink
Add EditorBrowsableState.Never to the specific AccessTools.IsStatic m…
Browse files Browse the repository at this point in the history
…ethods so that only MemberInfo overload should show up in IDEs by default
  • Loading branch information
lbmaian committed Aug 9, 2020
1 parent 1b67e4b commit 9be1fb0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Harmony/Tools/AccessTools.cs
Expand Up @@ -2,6 +2,7 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics;
using System.Linq;
using System.Reflection;
Expand Down Expand Up @@ -1861,6 +1862,7 @@ public static bool IsStatic(MemberInfo member)
/// <param name="type">The type</param>
/// <returns>True if the type is static</returns>
///
[EditorBrowsable(EditorBrowsableState.Never)]
public static bool IsStatic(Type type)
{
if (type is null)
Expand All @@ -1872,6 +1874,7 @@ public static bool IsStatic(Type type)
/// <param name="propertyInfo">The property</param>
/// <returns>True if the property is static</returns>
///
[EditorBrowsable(EditorBrowsableState.Never)]
public static bool IsStatic(PropertyInfo propertyInfo)
{
if (propertyInfo is null)
Expand All @@ -1883,6 +1886,7 @@ public static bool IsStatic(PropertyInfo propertyInfo)
/// <param name="eventInfo">The event</param>
/// <returns>True if the event is static</returns>
///
[EditorBrowsable(EditorBrowsableState.Never)]
public static bool IsStatic(EventInfo eventInfo)
{
if (eventInfo is null)
Expand Down

0 comments on commit 9be1fb0

Please sign in to comment.