@@ -1121,13 +1121,7 @@ internal static int PyObject_Compare(IntPtr value1, IntPtr value2)
1121
1121
1122
1122
internal static int PyObject_Not ( IntPtr pointer ) => Delegates . PyObject_Not ( pointer ) ;
1123
1123
1124
- internal static long PyObject_Size ( IntPtr pointer )
1125
- {
1126
- return ( long ) _PyObject_Size ( pointer ) ;
1127
- }
1128
-
1129
-
1130
- private static IntPtr _PyObject_Size ( IntPtr pointer ) => Delegates . _PyObject_Size ( pointer ) ;
1124
+ internal static nint PyObject_Size ( BorrowedReference pointer ) => Delegates . PyObject_Size ( pointer ) ;
1131
1125
1132
1126
1133
1127
internal static nint PyObject_Hash ( IntPtr op ) => Delegates . PyObject_Hash ( op ) ;
@@ -2028,9 +2022,8 @@ internal static IntPtr PyType_GenericAlloc(IntPtr type, long n)
2028
2022
2029
2023
internal static int PyObject_GenericSetAttr ( IntPtr obj , IntPtr name , IntPtr value ) => Delegates . PyObject_GenericSetAttr ( obj , name , value ) ;
2030
2024
2031
-
2032
- internal static BorrowedReference * _PyObject_GetDictPtr ( BorrowedReference obj ) => Delegates . _PyObject_GetDictPtr ( obj ) ;
2033
-
2025
+ internal static NewReference PyObject_GenericGetDict ( BorrowedReference o ) => PyObject_GenericGetDict ( o , IntPtr . Zero ) ;
2026
+ internal static NewReference PyObject_GenericGetDict ( BorrowedReference o , IntPtr context ) => Delegates . PyObject_GenericGetDict ( o , context ) ;
2034
2027
2035
2028
internal static void PyObject_GC_Del ( IntPtr tp ) => Delegates . PyObject_GC_Del ( tp ) ;
2036
2029
@@ -2323,7 +2316,7 @@ static Delegates()
2323
2316
PyCallable_Check = ( delegate * unmanaged[ Cdecl] < IntPtr , int > ) GetFunctionByName ( nameof ( PyCallable_Check ) , GetUnmanagedDll ( _PythonDll ) ) ;
2324
2317
PyObject_IsTrue = ( delegate * unmanaged[ Cdecl] < BorrowedReference , int > ) GetFunctionByName ( nameof ( PyObject_IsTrue ) , GetUnmanagedDll ( _PythonDll ) ) ;
2325
2318
PyObject_Not = ( delegate * unmanaged[ Cdecl] < IntPtr , int > ) GetFunctionByName ( nameof ( PyObject_Not ) , GetUnmanagedDll ( _PythonDll ) ) ;
2326
- _PyObject_Size = ( delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > ) GetFunctionByName ( "PyObject_Size" , GetUnmanagedDll ( _PythonDll ) ) ;
2319
+ PyObject_Size = ( delegate * unmanaged[ Cdecl] < BorrowedReference , nint > ) GetFunctionByName ( "PyObject_Size" , GetUnmanagedDll ( _PythonDll ) ) ;
2327
2320
PyObject_Hash = ( delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > ) GetFunctionByName ( nameof ( PyObject_Hash ) , GetUnmanagedDll ( _PythonDll ) ) ;
2328
2321
PyObject_Repr = ( delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > ) GetFunctionByName ( nameof ( PyObject_Repr ) , GetUnmanagedDll ( _PythonDll ) ) ;
2329
2322
PyObject_Str = ( delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > ) GetFunctionByName ( nameof ( PyObject_Str ) , GetUnmanagedDll ( _PythonDll ) ) ;
@@ -2478,8 +2471,8 @@ static Delegates()
2478
2471
PyType_Ready = ( delegate * unmanaged[ Cdecl] < IntPtr , int > ) GetFunctionByName ( nameof ( PyType_Ready ) , GetUnmanagedDll ( _PythonDll ) ) ;
2479
2472
_PyType_Lookup = ( delegate * unmanaged[ Cdecl] < IntPtr , IntPtr , IntPtr > ) GetFunctionByName ( nameof ( _PyType_Lookup ) , GetUnmanagedDll ( _PythonDll ) ) ;
2480
2473
PyObject_GenericGetAttr = ( delegate * unmanaged[ Cdecl] < IntPtr , IntPtr , IntPtr > ) GetFunctionByName ( nameof ( PyObject_GenericGetAttr ) , GetUnmanagedDll ( _PythonDll ) ) ;
2474
+ PyObject_GenericGetDict = ( delegate * unmanaged[ Cdecl] < BorrowedReference , IntPtr , NewReference > ) GetFunctionByName ( nameof ( PyObject_GenericGetDict ) , GetUnmanagedDll ( PythonDLL ) ) ;
2481
2475
PyObject_GenericSetAttr = ( delegate * unmanaged[ Cdecl] < IntPtr , IntPtr , IntPtr , int > ) GetFunctionByName ( nameof ( PyObject_GenericSetAttr ) , GetUnmanagedDll ( _PythonDll ) ) ;
2482
- _PyObject_GetDictPtr = ( delegate * unmanaged[ Cdecl] < BorrowedReference , BorrowedReference * > ) GetFunctionByName ( nameof ( _PyObject_GetDictPtr ) , GetUnmanagedDll ( _PythonDll ) ) ;
2483
2476
PyObject_GC_Del = ( delegate * unmanaged[ Cdecl] < IntPtr , void > ) GetFunctionByName ( nameof ( PyObject_GC_Del ) , GetUnmanagedDll ( _PythonDll ) ) ;
2484
2477
PyObject_GC_Track = ( delegate * unmanaged[ Cdecl] < IntPtr , void > ) GetFunctionByName ( nameof ( PyObject_GC_Track ) , GetUnmanagedDll ( _PythonDll ) ) ;
2485
2478
PyObject_GC_UnTrack = ( delegate * unmanaged[ Cdecl] < IntPtr , void > ) GetFunctionByName ( nameof ( PyObject_GC_UnTrack ) , GetUnmanagedDll ( _PythonDll ) ) ;
@@ -2595,7 +2588,7 @@ static Delegates()
2595
2588
internal static delegate * unmanaged[ Cdecl] < IntPtr , int > PyCallable_Check { get ; }
2596
2589
internal static delegate * unmanaged[ Cdecl] < BorrowedReference , int > PyObject_IsTrue { get ; }
2597
2590
internal static delegate * unmanaged[ Cdecl] < IntPtr , int > PyObject_Not { get ; }
2598
- internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > _PyObject_Size { get ; }
2591
+ internal static delegate * unmanaged[ Cdecl] < BorrowedReference , nint > PyObject_Size { get ; }
2599
2592
internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > PyObject_Hash { get ; }
2600
2593
internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > PyObject_Repr { get ; }
2601
2594
internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr > PyObject_Str { get ; }
@@ -2744,7 +2737,6 @@ static Delegates()
2744
2737
internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr , IntPtr > _PyType_Lookup { get ; }
2745
2738
internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr , IntPtr > PyObject_GenericGetAttr { get ; }
2746
2739
internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr , IntPtr , int > PyObject_GenericSetAttr { get ; }
2747
- internal static delegate * unmanaged[ Cdecl] < BorrowedReference , BorrowedReference * > _PyObject_GetDictPtr { get ; }
2748
2740
internal static delegate * unmanaged[ Cdecl] < IntPtr , void > PyObject_GC_Del { get ; }
2749
2741
internal static delegate * unmanaged[ Cdecl] < IntPtr , void > PyObject_GC_Track { get ; }
2750
2742
internal static delegate * unmanaged[ Cdecl] < IntPtr , void > PyObject_GC_UnTrack { get ; }
@@ -2781,6 +2773,7 @@ static Delegates()
2781
2773
internal static delegate * unmanaged[ Cdecl] < IntPtr , IntPtr , void > PyException_SetCause { get ; }
2782
2774
internal static delegate * unmanaged[ Cdecl] < uint , IntPtr , int > PyThreadState_SetAsyncExcLLP64 { get ; }
2783
2775
internal static delegate * unmanaged[ Cdecl] < ulong , IntPtr , int > PyThreadState_SetAsyncExcLP64 { get ; }
2776
+ internal static delegate * unmanaged[ Cdecl] < BorrowedReference , IntPtr , NewReference > PyObject_GenericGetDict { get ; }
2784
2777
}
2785
2778
}
2786
2779