@@ -95,11 +95,8 @@ public class Runtime
95
95
96
96
public static readonly string PythonDLL = _PythonDll ;
97
97
98
- #if PYTHON_WITHOUT_ENABLE_SHARED && ! NETSTANDARD
98
+ // In Unity, the library is always loaded in-memory
99
99
internal const string _PythonDll = "__Internal" ;
100
- #else
101
- internal const string _PythonDll = dllBase + dllWithPyDebug + dllWithPyMalloc ;
102
- #endif
103
100
#if MONO_LINUX
104
101
internal const string dllDirectory = "Library/conda/lib/" ;
105
102
internal const string pythonlib = "python3.7m" ;
@@ -1045,7 +1042,10 @@ internal static int PyObject_Compare(IntPtr value1, IntPtr value2)
1045
1042
[ DllImport( _PythonDll, CallingConvention = CallingConvention. Cdecl) ]
1046
1043
internal static extern int PyCallable_Check( IntPtr pointer) ;
1047
1044
1048
- [ DllImport( _PythonDll, CallingConvention = CallingConvention. Cdecl) ]
1045
+ // [DllImport(_PythonDll, CallingConvention = CallingConvention.Cdecl, EntryPoint = "PyObject_IsTrue")]
1046
+ // internal static extern int _PyObject_IsTrue(IntPtr pointer);
1047
+ // internal static int PyObject_IsTrue(IntPtr ptr) => _PyObject_IsTrue(ptr);
1048
+ [ DllImport( _PythonDll, CallingConvention = CallingConvention. Cdecl, EntryPoint = "PyObject_IsTrue") ]
1049
1049
internal static extern int PyObject_IsTrue( IntPtr pointer) ;
1050
1050
1051
1051
[ DllImport( _PythonDll, CallingConvention = CallingConvention. Cdecl) ]
@@ -1058,7 +1058,6 @@ internal static long PyObject_Size(IntPtr pointer)
1058
1058
1059
1059
[ DllImport( _PythonDll, CallingConvention = CallingConvention. Cdecl, EntryPoint = "PyObject_Size") ]
1060
1060
private static extern IntPtr _PyObject_Size( IntPtr pointer) ;
1061
-
1062
1061
[ DllImport( _PythonDll, CallingConvention = CallingConvention. Cdecl) ]
1063
1062
internal static extern IntPtr PyObject_Hash( IntPtr op) ;
1064
1063
0 commit comments