Author: Armin Rigo <[email protected]>
Branch: enum-as-int
Changeset: r1148:affd8586b17f
Date: 2013-02-12 18:18 +0100
http://bitbucket.org/cffi/cffi/changeset/affd8586b17f/
Log: Document
diff --git a/doc/source/index.rst b/doc/source/index.rst
--- a/doc/source/index.rst
+++ b/doc/source/index.rst
@@ -1194,15 +1194,16 @@
length 0, allocating a ``char[]`` of the correct size, and casting
it to a struct pointer)
-* Enum types are always ``int``. GCC supports enums containing
- larger constants (``unsigned int``, or ``long long``) as an extension
- to the C standard, but CFFI does not. Use
- ``typedef <exact type> my_enum;`` and then some ``#define foo <value>``.
-
.. versionadded:: 0.4
Now supported: the common GCC extension of anonymous nested
structs/unions inside structs/unions.
+.. versionadded:: 0.6
+ Enum types follow the GCC rules: they are defined as the first of
+ ``unsigned int``, ``int``, ``unsigned long`` or ``long`` that fits
+ all numeric values. Note that the first choice is unsigned. In CFFI
+ 0.5 and before, it was always ``int``.
+
Debugging dlopen'ed C libraries
-------------------------------
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit