summaryrefslogtreecommitdiff
path: root/_dbus_bindings/bytes.c
Commit message (Collapse)AuthorAgeFilesLines
* Add INTORLONG_CHECK macro so we don't have to conditionalize PyInt_CheckSimon McVittie2012-01-111-6/+2
|
* Use native 'int' (whatever that means) for variant_level etc.Simon McVittie2012-01-111-2/+2
| | | | | This reverts the Python 2 API to be in terms of PyInt, leaving the Python 3 API in terms of PyLong (which is called 'int' in Python code).
* Do not allow Byte(unicode(x)) (i.e. Byte(str(x)) in Python 3)Simon McVittie2012-01-111-14/+0
| | | | | Unicode strings aren't bytestrings, so there's no obvious meaning for the byte value of a Unicode string of length 1.
* Use better names for the superclasses of Byte and ByteArraySimon McVittie2012-01-111-9/+9
| | | | | | | | Strictly speaking, DBUS_FOO is libdbus' namespace, not ours. Use DBUS_PY_FOO. DBUS_BYTES_BASE was misleading: it's the base class for a single byte, so call it DBUS_PY_BYTE_BASE.
* Consistency; clean-up.Barry Warsaw2011-12-151-4/+4
|
* This is the big one; it adds Python 3 support.Barry Warsaw2011-12-151-11/+48
|
* First round of PyInt -> PyLong changes. These are only compatible with PythonBarry Warsaw2011-12-141-8/+26
| | | | | | | 2, since there are still some unconditional PyInt calls, which are not valid in Python 3. However, it lays the framework for conditionalizing on Python 3 and using only PyLong in that case. Where it doesn't matter, PyLong is used unconditionally.
* In preparation for Python 3 support, use the Python 2 PyBytes aliases for theBarry Warsaw2011-12-141-4/+4
| | | | | PyString API. This makes the code compilable in Python 2.x (x >= 6) and Python 3.
* - Add a few missing Py_TYPE() changes for Python 3 compatibility.Barry Warsaw2011-12-131-1/+1
| | | | - De-tabbify a few instances that "make check" complains about.
* Use PyVarObject_HEAD_INIT to initialize typesBarry Warsaw2011-12-131-4/+2
| | | | | | Part of a patch for Python 3 compatibility. Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
* Use Py_TYPE() rather than thing->ob_type, for Python 3 portabilitySimon McVittie2011-12-131-1/+1
| | | | | | Based on part of a patch from Barry Warsaw. Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
* fd.o #23831: make sure to ref types passed to PyModule_AddObjectSimon McVittie2010-12-021-0/+1
| | | | | | | This avoids these static types wrongly being deallocated. Python implements static types as having one initial reference, which is never meant to be released, but if you get your refcounting wrong they'll be "deallocated" (causing a crash) during Py_Finalize.
* Use Py_CLEAR for greater robustnessSimon McVittie2010-12-021-4/+2
|
* Relicense Collabora code under the MIT/X11 license proposed for dbus core, ↵Simon McVittie2007-09-271-15/+18
| | | | removing all references to the LGPL as a result
* Actually commit the numerous copyright-statement changes.Simon McVittie2007-02-071-7/+7
|
* dbus, _dbus_bindings, _dbus_glib_bindings: remove accidentally duplicated ↵Simon McVittie2007-01-251-2/+0
| | | | lines in license statement
* bytes.c, string.c: Don't mention get_object_by_unique_name in docstrings, it ↵Simon McVittie2007-01-161-1/+1
| | | | no longer exists
* Subscripting a ByteArray now gives 1-character strings again (for least ↵Simon McVittie2007-01-091-57/+18
| | | | astonishment). Also document how to get a ByteArray from the API
* Improve various type docstringsSimon McVittie2006-12-211-7/+21
|
* Separate out remaining types (abstract, bytes, containers, int, float, ↵Simon McVittie2006-12-111-0/+291
signature, string) into separate translation units