A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2000-December/011171.html below:

[Patches] [Patch #102955] bltinmodule.c warning fix

[Python-Dev] Re: [Patches] [Patch #102955] bltinmodule.c warning fixAndrew Kuchling akuchlin@mems-exchange.org
Thu, 21 Dec 2000 13:37:19 -0500
On Thu, Dec 21, 2000 at 02:44:19AM -0500, Tim Peters wrote:
>So we should say "8-bit string" or "Unicode string" when *only* one of those
>is allowable.  So

OK... how about this patch?

Index: bltinmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Python/bltinmodule.c,v
retrieving revision 2.185
diff -u -r2.185 bltinmodule.c
--- bltinmodule.c	2000/12/20 15:07:34	2.185
+++ bltinmodule.c	2000/12/21 18:36:54
@@ -1524,13 +1524,14 @@
 		}
 	} else {
 		PyErr_Format(PyExc_TypeError,
-			     "ord() expected string or Unicode character, " \
+			     "ord() expected string of length 1, but " \
 			     "%.200s found", obj->ob_type->tp_name);
 		return NULL;
 	}
 
 	PyErr_Format(PyExc_TypeError, 
-		     "ord() expected a character, length-%d string found",
+		     "ord() expected a character, "
+                     "but string of length %d found",
 		     size);
 	return NULL;
 }



RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4