Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
c4839d1
Add [RequiresUnsafe] to all LibraryImport/extern methods in CoreLib, …
Copilot Mar 21, 2026
7aeb028
Add Directory.Build.targets polyfill for RequiresUnsafeAttribute; add…
Copilot Mar 21, 2026
805e61a
Fix duplicate RequiresUnsafeAttribute inclusion: remove from Microsof…
Copilot Mar 21, 2026
d5e10fb
Split ExternMethodMissingRequiresUnsafe (IL5005) into IL5005 for exte…
Copilot Mar 21, 2026
bce5280
Update LibraryImportGenerator to emit [RequiresUnsafe] on generated _…
Copilot Mar 21, 2026
3833b0a
Fix CI: exclude shim/facade/ref assemblies from RequiresUnsafeAttribu…
Copilot Mar 22, 2026
fd88b2e
Update UnsafeMethodMissingRequiresUnsafeAnalyzer.cs
EgorBo Mar 22, 2026
56e5847
Refactor GetExternOrLibraryImportRule into IsExtern and IsLibraryImpo…
Copilot Mar 22, 2026
e30d96f
Address PR feedback: fix EventLogMessages CI, title casing, PNSE cond…
Copilot Mar 22, 2026
e4ae889
Enable RequiresUnsafe analyzer for all libraries, promote IL5005/IL50…
Copilot Mar 24, 2026
7bf7a8a
Update test expectations for IL5005/IL5006 Warning severity
Copilot Mar 24, 2026
58d03f9
Fix CI: add missing using directives, fix preprocessor placement, ann…
Copilot Mar 24, 2026
67578d5
Fix CI: comprehensive annotation fixes, remove duplicates, fix polyfi…
Copilot Mar 24, 2026
ed2f14d
Fix remaining CI issues: remove parameter-level attributes, fix dupli…
Copilot Mar 24, 2026
c6e1b84
Merge branch 'main' into copilot/handle-pr-125880-feedback
EgorBo Mar 24, 2026
52c1b38
Fix CI: remove duplicate using/attribute, remove [RequiresUnsafe] fro…
Copilot Mar 25, 2026
2e3a396
Fix System.Runtime GenFacades type forwarder conflict with RequiresUn…
Copilot Mar 26, 2026
156578b
placeholder
Copilot Mar 26, 2026
1939f6c
Fix CI: restore public RequiresUnsafeAttribute from main, add to Syst…
Copilot Mar 26, 2026
6214e58
Merge branch 'main' into copilot/handle-pr-125880-feedback
EgorBo Mar 26, 2026
4c08c6c
Merge branch 'main' into copilot/handle-pr-125880-feedback
EgorBo Mar 27, 2026
57b1e36
Add [RequiresUnsafe] to non-InternalCall extern methods in NativeAOT …
Copilot Mar 28, 2026
f78ee99
Add [RequiresUnsafe] to MethodTable.Of<T>() extern in NativeAOT Common
Copilot Mar 28, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 4 additions & 0 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,10 @@
<WarningsNotAsErrors Condition="'$(OfficialBuild)' != 'true' OR '$(NuGetAuditWarnNotError)' == 'true'">$(WarningsNotAsErrors);NU1901;NU1902;NU1903;NU1904</WarningsNotAsErrors>
<!-- Warnings to always disable -->
<NoWarn>$(NoWarn);CS8500;CS8969</NoWarn>

<!-- Temporarily suppress ILLink RequiresUnsafe call-site and annotation-mismatch diagnostics for the entire repo. -->
<NoWarn>$(NoWarn);IL5000;IL5001</NoWarn>

<!-- Suppress "CS1591 - Missing XML comment for publicly visible type or member" compiler errors for private assemblies. -->
<NoWarn Condition="'$(IsPrivateAssembly)' == 'true'">$(NoWarn);CS1591</NoWarn>
<!-- Always pass portable to override arcade sdk which uses embedded for local builds -->
Expand Down
3 changes: 3 additions & 0 deletions eng/Analyzers.targets
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@
'$(EnableSingleFileAnalyzer)' == '' and
'$(TargetFrameworkIdentifier)' == '.NETCoreApp' and
'$(IsSourceProject)' == 'true'">true</EnableSingleFileAnalyzer>
<EnableUnsafeAnalyzer Condition="
'$(EnableUnsafeAnalyzer)' == '' and
'$(IsSourceProject)' == 'true'">true</EnableUnsafeAnalyzer>
</PropertyGroup>
<ItemGroup Condition="'$(RunAnalyzers)' != 'false'">
<EditorConfigFiles Include="$(MSBuildThisFileDirectory)CodeAnalysis.src.globalconfig" />
Expand Down
1 change: 1 addition & 0 deletions eng/ApiCompatExcludeAttributes.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
T:System.Diagnostics.CodeAnalysis.MemberNotNullAttribute
T:System.Diagnostics.CodeAnalysis.RequiresUnsafeAttribute
T:System.Diagnostics.DebuggerGuidedStepThroughAttribute
T:System.Runtime.CompilerServices.EagerStaticClassConstructionAttribute
T:System.Runtime.CompilerServices.NativeIntegerAttribute
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ namespace Internal.Runtime.CompilerHelpers
{
internal static unsafe partial class ThrowHelpers
{
[RequiresUnsafe]
[DoesNotReturn]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ExceptionNative_ThrowAmbiguousResolutionException")]
[RequiresUnsafe]
private static partial void ThrowAmbiguousResolutionException(MethodTable* targetType, MethodTable* interfaceType, void* methodDesc);

[DoesNotReturn]
Expand All @@ -26,9 +26,9 @@ internal static void ThrowAmbiguousResolutionException(
ThrowAmbiguousResolutionException((MethodTable*)targetType, (MethodTable*)interfaceType, method);
}

[RequiresUnsafe]
[DoesNotReturn]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ExceptionNative_ThrowEntryPointNotFoundException")]
[RequiresUnsafe]
private static partial void ThrowEntryPointNotFoundException(MethodTable* targetType, MethodTable* interfaceType, void* methodDesc);

[DoesNotReturn]
Expand All @@ -42,9 +42,9 @@ internal static void ThrowEntryPointNotFoundException(
ThrowEntryPointNotFoundException((MethodTable*)targetType, (MethodTable*)interfaceType, method);
}

[RequiresUnsafe]
[DoesNotReturn]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ExceptionNative_ThrowMethodAccessException")]
[RequiresUnsafe]
private static partial void ThrowMethodAccessExceptionInternal(void* caller, void* callee);

// implementation of CORINFO_HELP_METHOD_ACCESS_EXCEPTION
Expand All @@ -58,9 +58,9 @@ internal static void ThrowMethodAccessException(
ThrowMethodAccessExceptionInternal(caller, callee);
}

[RequiresUnsafe]
[DoesNotReturn]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ExceptionNative_ThrowFieldAccessException")]
[RequiresUnsafe]
private static partial void ThrowFieldAccessExceptionInternal(void* caller, void* callee);

// implementation of CORINFO_HELP_FIELD_ACCESS_EXCEPTION
Expand All @@ -74,9 +74,9 @@ internal static void ThrowFieldAccessException(
ThrowFieldAccessExceptionInternal(caller, callee);
}

[RequiresUnsafe]
[DoesNotReturn]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ExceptionNative_ThrowClassAccessException")]
[RequiresUnsafe]
private static partial void ThrowClassAccessExceptionInternal(void* caller, void* callee);

// implementation of CORINFO_HELP_CLASS_ACCESS_EXCEPTION
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -710,12 +710,14 @@ internal sealed class LicenseInteropProxy
private object? _licContext;
private Type? _targetRcwType;

[RequiresUnsafe]
[UnsafeAccessor(UnsafeAccessorKind.Method)]
private static extern void SetSavedLicenseKey(
[UnsafeAccessorType(LicenseContextTypeName)] object licContext,
Type type,
string key);

[RequiresUnsafe]
[UnconditionalSuppressMessage("Trimming", "IL2111", Justification = "Manually validated that the annotations are kept in sync.")]
[UnsafeAccessor(UnsafeAccessorKind.StaticMethod)]
private static extern object? CreateWithContext(
Expand All @@ -724,6 +726,7 @@ private static extern void SetSavedLicenseKey(
[UnsafeAccessorType(LicenseContextTypeName)] object licContext
);

[RequiresUnsafe]
[UnsafeAccessor(UnsafeAccessorKind.StaticMethod)]
private static extern bool ValidateAndRetrieveLicenseDetails(
[UnsafeAccessorType(LicenseInteropHelperTypeName)] object? licInteropHelper,
Expand All @@ -732,6 +735,7 @@ private static extern bool ValidateAndRetrieveLicenseDetails(
[UnsafeAccessorType(LicenseRefTypeName)] out object? license,
out string? licenseKey);

[RequiresUnsafe]
[UnsafeAccessor(UnsafeAccessorKind.StaticMethod)]
[return: UnsafeAccessorType(LicenseContextTypeName)]
private static extern object? GetCurrentContextInfo(
Expand All @@ -740,23 +744,27 @@ private static extern bool ValidateAndRetrieveLicenseDetails(
out bool isDesignTime,
out string? key);

[RequiresUnsafe]
[UnsafeAccessor(UnsafeAccessorKind.StaticMethod)]
[return: UnsafeAccessorType(CLRLicenseContextTypeName)]
private static extern object CreateDesignContext(
[UnsafeAccessorType(CLRLicenseContextTypeName)] object? context,
Type type);

[RequiresUnsafe]
[UnsafeAccessor(UnsafeAccessorKind.StaticMethod)]
[return: UnsafeAccessorType(CLRLicenseContextTypeName)]
private static extern object CreateRuntimeContext(
[UnsafeAccessorType(CLRLicenseContextTypeName)] object? context,
Type type,
string? key);

[RequiresUnsafe]
[UnsafeAccessor(UnsafeAccessorKind.Constructor)]
[return:UnsafeAccessorType(LicInfoHelperLicenseContextTypeName)]
private static extern object CreateLicInfoHelperLicenseContext();

[RequiresUnsafe]
[UnsafeAccessor(UnsafeAccessorKind.Method)]
private static extern bool Contains(
[UnsafeAccessorType(LicInfoHelperLicenseContextTypeName)] object? licInfoHelperContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
// The .NET Foundation licenses this file to you under the MIT license.

using System;
using System.Diagnostics.CodeAnalysis;
using System.Reflection.Metadata;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
Expand All @@ -13,6 +14,7 @@ namespace Internal
/// </summary>
internal static partial class VersionResilientHashCode
{
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "VersionResilientHashCode_TypeHashCode")]
private static partial int TypeHashCode(QCallTypeHandle typeHandle);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ internal static unsafe void OnFirstChanceException(Exception* pException, Except
internal static void SetFirstChanceExceptionHandler()
=> SetFirstChanceExceptionHandlerInternal();

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "AppContext_SetFirstChanceExceptionHandler")]
[SuppressGCTransition]
private static partial void SetFirstChanceExceptionHandlerInternal();
Expand Down
5 changes: 5 additions & 0 deletions src/coreclr/System.Private.CoreLib/src/System/ArgIterator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ public ArgIterator(RuntimeArgumentHandle arglist)
Init(ThisPtr, cookie);
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ArgIterator_Init")]
private static partial void Init(ArgIterator* thisPtr, IntPtr cookie);

Expand All @@ -57,6 +58,7 @@ public ArgIterator(RuntimeArgumentHandle arglist, void* ptr)
Init(ThisPtr, cookie, ptr);
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ArgIterator_Init2")]
private static partial void Init(ArgIterator* thisPtr, IntPtr cookie, void* ptr);

Expand All @@ -83,6 +85,7 @@ public TypedReference GetNextArg()
return result;
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ArgIterator_GetNextArg")]
private static partial void GetNextArg(ArgIterator* thisPtr, TypedReference* pResult);

Expand Down Expand Up @@ -118,6 +121,7 @@ public TypedReference GetNextArg(RuntimeTypeHandle rth)
return result;
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ArgIterator_GetNextArg2")]
private static partial void GetNextArg(ArgIterator* thisPtr, QCallTypeHandle rth, TypedReference* pResult);

Expand All @@ -143,6 +147,7 @@ public RuntimeTypeHandle GetNextArgType()
return RuntimeTypeHandle.FromIntPtr(GetNextArgType(ThisPtr));
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ArgIterator_GetNextArgType")]
private static partial IntPtr GetNextArgType(ArgIterator* thisPtr);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ namespace System
// IList<U> and IReadOnlyList<U>, where T : U dynamically. See the SZArrayHelper class for details.
public abstract partial class Array : ICloneable, IList, IStructuralComparable, IStructuralEquatable
{
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Array_CreateInstance")]
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Array_CreateInstance")]
private static unsafe partial void InternalCreate(QCallTypeHandle type, int rank, int* pLengths, int* pLowerBounds,
[MarshalAs(UnmanagedType.Bool)] bool fromArrayType, ObjectHandleOnStack retArray);

Expand All @@ -38,8 +38,8 @@ private static unsafe Array InternalCreateFromArrayType(RuntimeType arrayType, i
return retArray!;
}

[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Array_Ctor")]
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Array_Ctor")]
private static unsafe partial void Ctor(MethodTable* pArrayMT, uint dwNumArgs, int* pArgList, ObjectHandleOnStack retArray);

// implementation of CORINFO_HELP_NEW_MDARR and CORINFO_HELP_NEW_MDARR_RARE.
Expand Down Expand Up @@ -355,8 +355,8 @@ internal sealed unsafe partial class ArrayInitializeCache : RuntimeType.IGeneric
{
internal readonly delegate*<ref byte, void> ConstructorEntrypoint;

[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Array_GetElementConstructorEntrypoint")]
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Array_GetElementConstructorEntrypoint")]
private static partial delegate*<ref byte, void> GetElementConstructorEntrypoint(QCallTypeHandle arrayType);

[RequiresUnsafe]
Expand Down
2 changes: 2 additions & 0 deletions src/coreclr/System.Private.CoreLib/src/System/CLRConfig.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using System.Diagnostics.CodeAnalysis;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

Expand All @@ -15,6 +16,7 @@ internal static bool GetBoolValue(string switchName, out bool exist)
return GetConfigBoolValue(switchName, out exist);
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ClrConfig_GetConfigBoolValue", StringMarshalling = StringMarshalling.Utf16)]
[return: MarshalAs(UnmanagedType.Bool)]
private static partial bool GetConfigBoolValue(string configSwitchName, [MarshalAs(UnmanagedType.Bool)] out bool exist);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using System.Diagnostics.CodeAnalysis;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

Expand All @@ -9,6 +10,7 @@ namespace System
{
internal sealed partial class ComAwareWeakReference
{
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ComWeakRefToObject")]
private static partial void ComWeakRefToObject(IntPtr pComWeakRef, ObjectHandleOnStack retRcw);

Expand Down Expand Up @@ -38,6 +40,7 @@ internal static bool PossiblyComObject(object target)
#endif // FEATURE_COMINTEROP
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "ObjectToComWeakRef")]
private static partial IntPtr ObjectToComWeakRef(ObjectHandleOnStack retRcw);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -415,6 +415,7 @@ private bool BindToMethodName(object? target, [DynamicallyAccessedMembers(Dynami
new QCallTypeHandle(ref methodType), method, flags);
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_BindToMethodName", StringMarshalling = StringMarshalling.Utf8)]
[return: MarshalAs(UnmanagedType.Bool)]
private static partial bool BindToMethodName(ObjectHandleOnStack d, ObjectHandleOnStack target, QCallTypeHandle methodType, string method, DelegateBindingFlags flags);
Expand All @@ -428,6 +429,7 @@ private bool BindToMethodInfo(object? target, IRuntimeMethodInfo method, Runtime
return ret;
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_BindToMethodInfo")]
[return: MarshalAs(UnmanagedType.Bool)]
private static partial bool BindToMethodInfo(ObjectHandleOnStack d, ObjectHandleOnStack target, RuntimeMethodHandleInternal method, QCallTypeHandle methodType, DelegateBindingFlags flags);
Expand Down Expand Up @@ -479,15 +481,16 @@ private void DelegateConstruct(object target, IntPtr method)
Construct(ObjectHandleOnStack.Create(ref _this), ObjectHandleOnStack.Create(ref target), method);
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_Construct")]
private static partial void Construct(ObjectHandleOnStack _this, ObjectHandleOnStack target, IntPtr method);

[MethodImpl(MethodImplOptions.InternalCall)]
[RequiresUnsafe]
private static extern unsafe void* GetMulticastInvoke(MethodTable* pMT);

[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_GetMulticastInvokeSlow")]
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_GetMulticastInvokeSlow")]
private static unsafe partial void* GetMulticastInvokeSlow(MethodTable* pMT);

internal unsafe IntPtr GetMulticastInvoke()
Expand Down Expand Up @@ -524,6 +527,7 @@ internal IRuntimeMethodInfo FindMethodHandle()
return methodInfo!;
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_FindMethodHandle")]
private static partial void FindMethodHandle(ObjectHandleOnStack d, ObjectHandleOnStack retMethodInfo);

Expand All @@ -532,6 +536,7 @@ private static bool InternalEqualMethodHandles(Delegate left, Delegate right)
return InternalEqualMethodHandles(ObjectHandleOnStack.Create(ref left), ObjectHandleOnStack.Create(ref right));
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_InternalEqualMethodHandles")]
[return: MarshalAs(UnmanagedType.Bool)]
private static partial bool InternalEqualMethodHandles(ObjectHandleOnStack left, ObjectHandleOnStack right);
Expand All @@ -541,6 +546,7 @@ internal static IntPtr AdjustTarget(object target, IntPtr methodPtr)
return AdjustTarget(ObjectHandleOnStack.Create(ref target), methodPtr);
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_AdjustTarget")]
private static partial IntPtr AdjustTarget(ObjectHandleOnStack target, IntPtr methodPtr);

Expand All @@ -550,6 +556,7 @@ internal void InitializeVirtualCallStub(IntPtr methodPtr)
InitializeVirtualCallStub(ObjectHandleOnStack.Create(ref d), methodPtr);
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "Delegate_InitializeVirtualCallStub")]
private static partial void InitializeVirtualCallStub(ObjectHandleOnStack d, IntPtr methodPtr);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@
// The Debugger class is a part of the System.Diagnostics package
// and is used for communicating with a debugger.

using System.Diagnostics.CodeAnalysis;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

namespace System.Diagnostics
{
public static partial class Debugger
{
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "DebugDebugger_Break")]
private static partial void BreakInternal();

Expand Down Expand Up @@ -54,13 +56,15 @@ static void NotifyOfCrossThreadDependencySlow()
}
}

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "DebugDebugger_Launch")]
[return: MarshalAs(UnmanagedType.Bool)]
private static partial bool LaunchInternal();

// Returns whether or not a managed debugger is attached to the process.
public static bool IsAttached => IsManagedDebuggerAttached() != 0;

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "DebugDebugger_IsManagedDebuggerAttached")]
[SuppressGCTransition]
private static partial int IsManagedDebuggerAttached();
Expand All @@ -70,19 +74,22 @@ static void NotifyOfCrossThreadDependencySlow()
// report the message depending on its settings.
public static void Log(int level, string? category, string? message) => LogInternal(level, category, message);

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "DebugDebugger_Log", StringMarshalling = StringMarshalling.Utf16)]
private static partial void LogInternal(int level, string? category, string? message);

// Checks to see if an attached debugger has logging enabled
public static bool IsLogging() => IsLoggingInternal() != 0;

[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "DebugDebugger_IsLoggingHelper")]
[SuppressGCTransition]
private static partial int IsLoggingInternal();

// Posts a custom notification for the attached debugger. If there is no
// debugger attached, has no effect. The debugger may or may not
// report the notification depending on its settings.
[RequiresUnsafe]
[LibraryImport(RuntimeHelpers.QCall, EntryPoint = "DebugDebugger_CustomNotification")]
private static partial void CustomNotification(ObjectHandleOnStack data);

Expand Down
Loading
Loading