mirror of
https://github.com/boostorg/python.git
synced 2026-01-21 17:12:22 +00:00
Add from/to_python for signed char and unsigned char
[SVN r8130]
This commit is contained in:
20
py.cpp
20
py.cpp
@@ -170,6 +170,26 @@ unsigned short from_python(PyObject* p, py::Type<unsigned short> type)
|
||||
return integer_from_python(p, type);
|
||||
}
|
||||
|
||||
PyObject* to_python(unsigned char i)
|
||||
{
|
||||
return integer_to_python(i);
|
||||
}
|
||||
|
||||
unsigned char from_python(PyObject* p, py::Type<unsigned char> type)
|
||||
{
|
||||
return integer_from_python(p, type);
|
||||
}
|
||||
|
||||
PyObject* to_python(signed char i)
|
||||
{
|
||||
return integer_to_python(i);
|
||||
}
|
||||
|
||||
signed char from_python(PyObject* p, py::Type<signed char> type)
|
||||
{
|
||||
return integer_from_python(p, type);
|
||||
}
|
||||
|
||||
PyObject* to_python(unsigned long x)
|
||||
{
|
||||
return integer_to_python(x);
|
||||
|
||||
Reference in New Issue
Block a user