Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c890691

Browse files
committed
Remove unneeded unsafe keyword
1 parent 67b3181 commit c890691

File tree

2 files changed

+262
-263
lines changed

2 files changed

+262
-263
lines changed

src/runtime/exceptions.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
using System.Reflection;
33
using System.Runtime.InteropServices;
44

5-
65
namespace Python.Runtime
76
{
87
/// <summary>
@@ -171,7 +170,7 @@ internal static void SetArgsAndCause(IntPtr ob)
171170
/// Shortcut for (pointer == NULL) -&gt; throw PythonException
172171
/// </summary>
173172
/// <param name="pointer">Pointer to a Python object</param>
174-
internal static unsafe void ErrorCheck(IntPtr pointer)
173+
internal static void ErrorCheck(IntPtr pointer)
175174
{
176175
if (pointer == IntPtr.Zero)
177176
{
@@ -182,7 +181,7 @@ internal static unsafe void ErrorCheck(IntPtr pointer)
182181
/// <summary>
183182
/// Shortcut for (pointer == NULL or ErrorOccurred()) -&gt; throw PythonException
184183
/// </summary>
185-
internal static unsafe void ErrorOccurredCheck(IntPtr pointer)
184+
internal static void ErrorOccurredCheck(IntPtr pointer)
186185
{
187186
if (pointer == IntPtr.Zero || ErrorOccurred())
188187
{

0 commit comments

Comments
 (0)