[Python-checkins] CVS: python/dist/src/Include unicodeobject.h,2.12,2.13

M.-A. Lemburg python-dev@python.org
Fri, 7 Jul 2000 02:01:44 -0700


Update of /cvsroot/python/python/dist/src/Include
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16506/Include

Modified Files:
	unicodeobject.h 
Log Message:
Bill Tutt: Added Py_UCS4 typedef to hold UCS4 values (these need
at least 32 bits as opposed to Py_UNICODE which rely on having
16 bits).

Index: unicodeobject.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/unicodeobject.h,v
retrieving revision 2.12
retrieving revision 2.13
diff -C2 -r2.12 -r2.13
*** unicodeobject.h	2000/07/05 09:45:59	2.12
--- unicodeobject.h	2000/07/07 09:01:41	2.13
***************
*** 108,111 ****
--- 108,122 ----
  #endif
  
+ /*
+  * Use this typedef when you need to represent a UTF-16 surrogate pair
+  * as single unsigned integer.
+  */
+ #if SIZEOF_INT >= 4 
+ typedef unsigned int Py_UCS4; 
+ #elif SIZEOF_LONG >= 4
+ typedef unsigned long Py_UCS4; 
+ #endif 
+ 
+ 
  /* --- Internal Unicode Operations ---------------------------------------- */