py3: Base: files R-Z ported to python3

issue 0000995
This commit is contained in:
Yorik van Havre
2017-05-21 12:35:41 +02:00
committed by wmayer
parent 1ec3e5da82
commit 0e9e49cbcc
5 changed files with 67 additions and 7 deletions
+8
View File
@@ -194,11 +194,13 @@ int UnitPy::setCustomAttributes(const char* /*attr*/, PyObject* /*obj*/)
return 0;
}
#if PY_MAJOR_VERSION < 3
PyObject * UnitPy::number_divide_handler (PyObject* /*self*/, PyObject* /*other*/)
{
PyErr_SetString(PyExc_NotImplementedError, "Not implemented");
return 0;
}
#endif
PyObject * UnitPy::number_remainder_handler (PyObject* /*self*/, PyObject* /*other*/)
{
@@ -277,10 +279,12 @@ PyObject * UnitPy::number_or_handler (PyObject* /*self*/, PyObject* /*other*/)
return 0;
}
#if PY_MAJOR_VERSION < 3
int UnitPy::number_coerce_handler (PyObject** /*self*/, PyObject** /*other*/)
{
return 1;
}
#endif
PyObject * UnitPy::number_int_handler (PyObject* /*self*/)
{
@@ -288,11 +292,13 @@ PyObject * UnitPy::number_int_handler (PyObject* /*self*/)
return 0;
}
#if PY_MAJOR_VERSION < 3
PyObject * UnitPy::number_long_handler (PyObject* /*self*/)
{
PyErr_SetString(PyExc_NotImplementedError, "Not implemented");
return 0;
}
#endif
PyObject * UnitPy::number_float_handler (PyObject* /*self*/)
{
@@ -300,6 +306,7 @@ PyObject * UnitPy::number_float_handler (PyObject* /*self*/)
return 0;
}
#if PY_MAJOR_VERSION < 3
PyObject * UnitPy::number_oct_handler (PyObject* /*self*/)
{
PyErr_SetString(PyExc_NotImplementedError, "Not implemented");
@@ -311,3 +318,4 @@ PyObject * UnitPy::number_hex_handler (PyObject* /*self*/)
PyErr_SetString(PyExc_NotImplementedError, "Not implemented");
return 0;
}
#endif