diff Python/formatter_unicode.c @ 51032:551257c8058a legacy-trunk

fix building the core with --disable-unicode I changed some bytearray methods to use strings instead of unicode like bytes_repr Also, bytearray.fromhex() can take strings as well as unicode
author Benjamin Peterson <benjamin@python.org>
date Sun, 25 Jan 2009 17:15:10 +0000
parents 47ef9a806ce9
children 34e7c1b14495
line wrap: on
line diff
--- a/Python/formatter_unicode.c	Sun Jan 25 10:39:15 2009 +0000
+++ b/Python/formatter_unicode.c	Sun Jan 25 17:15:10 2009 +0000
@@ -2,6 +2,9 @@
    built-in formatter for unicode.  That is, unicode.__format__(). */
 
 #include "Python.h"
+
+#ifdef Py_USING_UNICODE
+
 #include "../Objects/stringlib/unicodedefs.h"
 
 #define FORMAT_STRING _PyUnicode_FormatAdvanced
@@ -11,3 +14,5 @@
    will convert them to unicode. */
 
 #include "../Objects/stringlib/formatter.h"
+
+#endif