Missing Py*_Check Methods in JavaCPP Preset for CPython
mmanco opened this issue · 1 comments
mmanco commented
I am currently working on a project using the JavaCPP Preset for CPython. I am trying to check the type of a PyObject
, but it appears that the Py*_Check
methods (such as PyLong_Check
, PyFloat_Check
, etc.) are not available in the preset.
These methods are integral to the Python C API and are commonly used to ascertain the type of a PyObject
. They are essential for my project as I need to handle different types of PyObjects
differently.
Currently, I am using the following workaround, but the presence of those check macros would be beneficial and would ensure the completeness of the preset:
PyType_IsSubtype(Py_TYPE(value), PyFloat_Type())
Preset used: org.bytedeco:cpython-platform:3.12.1-1.5.10
saudet commented
Contributions are welcome!