Skip to content

Commit

Permalink
[mono] Optimize Type.IsRuntimeImplemented (#55260)
Browse files Browse the repository at this point in the history
Avoid virtual call to Type.UnderlyingSystemType. This is same as coreclr.
  • Loading branch information
BrzVlad authored Jul 8, 2021
1 parent 5f689e2 commit a48a11b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/mono/System.Private.CoreLib/src/System/Type.Mono.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ internal IntPtr GetUnderlyingNativeHandle()
return _impl.Value;
}

internal bool IsRuntimeImplemented() => this.UnderlyingSystemType is RuntimeType;
internal bool IsRuntimeImplemented() => this is RuntimeType;

internal virtual bool IsTypeBuilder() => false;

Expand Down

0 comments on commit a48a11b

Please sign in to comment.