cpython/Include/internal/pycore_list.h
Victor Stinner c45dbe93b7
bpo-41078: Add pycore_list.h internal header file (GH-21057)
* Move _PyList_ITEMS() to pycore_list.h.
* The C extension "_heapq" is now built with Py_BUILD_CORE_MODULE
  macro defined to access the internal C API.
2020-06-22 17:39:32 +02:00

20 lines
350 B
C

#ifndef Py_INTERNAL_LIST_H
#define Py_INTERNAL_LIST_H
#ifdef __cplusplus
extern "C" {
#endif
#ifndef Py_BUILD_CORE
# error "this header requires Py_BUILD_CORE define"
#endif
#include "listobject.h" // _PyList_CAST()
#define _PyList_ITEMS(op) (_PyList_CAST(op)->ob_item)
#ifdef __cplusplus
}
#endif
#endif /* !Py_INTERNAL_LIST_H */