File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
graalpython/com.oracle.graal.python.cext/src Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -185,14 +185,12 @@ inline void* native_to_java(PyObject* obj) {
185
185
186
186
__attribute__((always_inline ))
187
187
inline void * native_type_to_java (PyTypeObject * type ) {
188
- PyObject * obj = (PyObject * )type ;
189
- void * refcnt = obj -> ob_refcnt ;
190
- if (!truffle_cannot_be_handle (refcnt )) {
191
- return resolve_handle (cache , refcnt );
192
- } else if (IS_POINTER (refcnt )) {
193
- return refcnt ;
188
+ if (IS_POINTER (((PyObject * )type )-> ob_refcnt )) {
189
+ return (void * )((PyObject * )type )-> ob_refcnt ;
190
+ } else if (!truffle_cannot_be_handle (((PyObject * )type )-> ob_refcnt )) {
191
+ return resolve_handle (cache , ((PyObject * )type )-> ob_refcnt );
194
192
}
195
- return obj ;
193
+ return ( void * ) type ;
196
194
}
197
195
198
196
extern void * to_java (PyObject * obj );
You can’t perform that action at this time.
0 commit comments