annotate DEPENDENCIES/mingw32/Python27/include/boolobject.h @ 118:770eb830ec19 emscripten

Typo fix
author Chris Cannam
date Wed, 18 May 2016 16:14:08 +0100
parents 2a2c65a20a8b
children
rev   line source
Chris@87 1 /* Boolean object interface */
Chris@87 2
Chris@87 3 #ifndef Py_BOOLOBJECT_H
Chris@87 4 #define Py_BOOLOBJECT_H
Chris@87 5 #ifdef __cplusplus
Chris@87 6 extern "C" {
Chris@87 7 #endif
Chris@87 8
Chris@87 9
Chris@87 10 typedef PyIntObject PyBoolObject;
Chris@87 11
Chris@87 12 PyAPI_DATA(PyTypeObject) PyBool_Type;
Chris@87 13
Chris@87 14 #define PyBool_Check(x) (Py_TYPE(x) == &PyBool_Type)
Chris@87 15
Chris@87 16 /* Py_False and Py_True are the only two bools in existence.
Chris@87 17 Don't forget to apply Py_INCREF() when returning either!!! */
Chris@87 18
Chris@87 19 /* Don't use these directly */
Chris@87 20 PyAPI_DATA(PyIntObject) _Py_ZeroStruct, _Py_TrueStruct;
Chris@87 21
Chris@87 22 /* Use these macros */
Chris@87 23 #define Py_False ((PyObject *) &_Py_ZeroStruct)
Chris@87 24 #define Py_True ((PyObject *) &_Py_TrueStruct)
Chris@87 25
Chris@87 26 /* Macros for returning Py_True or Py_False, respectively */
Chris@87 27 #define Py_RETURN_TRUE return Py_INCREF(Py_True), Py_True
Chris@87 28 #define Py_RETURN_FALSE return Py_INCREF(Py_False), Py_False
Chris@87 29
Chris@87 30 /* Function to return a bool from a C long */
Chris@87 31 PyAPI_FUNC(PyObject *) PyBool_FromLong(long);
Chris@87 32
Chris@87 33 #ifdef __cplusplus
Chris@87 34 }
Chris@87 35 #endif
Chris@87 36 #endif /* !Py_BOOLOBJECT_H */