This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author schuppenies
Recipients amaury.forgeotdarc, benjamin.peterson, georg.brandl, pitrou, schuppenies
Date 2008-06-13.19:42:04
SpamBayes Score 0.00713104
Marked as misclassified No
Message-id <1213386126.17.0.363909754483.issue3098@psf.upfronthosting.co.za>
In-reply-to
Content
sys.maxunicode is well defined to be either 0xFFFF for UCS-2
or 0x10FFFF for UCS-4 (see PyUnicode_GetMax).

Py_UNICODE_SIZE is set in pyconfig.h to be either 2 or 4 during
configuration. When >= 4, Py_UNICODE_WIDE is set which again influences
sys.maxunicode.

Thus, it currently is possible to derive Py_UNICODE_SIZE from
sys.maxunicode. But it takes some indirections.

So here are 2 possible patches, one which exposes Py_UNICODE_SIZE via
_testcapi and one which assumes that sys.maxunicode reflects UCS-X
settings. Since I am a fairly new Python developer and the new
4-eyes-per-commit policy for the beta phase, please decide which patch
should be applied.
History
Date User Action Args
2008-06-13 19:42:06schuppeniessetspambayes_score: 0.00713104 -> 0.00713104
recipients: + schuppenies, georg.brandl, amaury.forgeotdarc, pitrou, benjamin.peterson
2008-06-13 19:42:06schuppeniessetspambayes_score: 0.00713104 -> 0.00713104
messageid: <1213386126.17.0.363909754483.issue3098@psf.upfronthosting.co.za>
2008-06-13 19:42:05schuppenieslinkissue3098 messages
2008-06-13 19:42:04schuppeniescreate