From f0dbb50eca72dce16bd85b5dccaa2c0c9243bd21 Mon Sep 17 00:00:00 2001 From: Benedikt Reinartz Date: Thu, 23 Dec 2021 23:42:04 +0100 Subject: [PATCH] Fix the PyGILState_STATE type CPython uses a bare `enum` here, both of .NET and C default to `int` enums, so this should be closer to the truth if no special compile options are used. --- src/runtime/native/PyGILState.cs | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/runtime/native/PyGILState.cs b/src/runtime/native/PyGILState.cs index 35fe6c983..2e7f61029 100644 --- a/src/runtime/native/PyGILState.cs +++ b/src/runtime/native/PyGILState.cs @@ -1,11 +1,8 @@ -using System; -using System.Runtime.InteropServices; - namespace Python.Runtime.Native; /// PyGILState_STATE -[StructLayout(LayoutKind.Sequential)] -struct PyGILState +enum PyGILState { - IntPtr handle; + PyGILState_LOCKED, + PyGILState_UNLOCKED } pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy