From: Finn B. <bc...@us...> - 2001-03-04 18:57:08
|
Update of /cvsroot/jython/jython/org/python/core In directory usw-pr-cvs1:/tmp/cvs-serv3790 Modified Files: PyString.java Log Message: StringFormatter.format(): Make exception text match CPython. Index: PyString.java =================================================================== RCS file: /cvsroot/jython/jython/org/python/core/PyString.java,v retrieving revision 2.42 retrieving revision 2.43 diff -C2 -r2.42 -r2.43 *** PyString.java 2001/03/04 18:12:33 2.42 --- PyString.java 2001/03/04 18:58:40 2.43 *************** *** 2225,2229 **** default: ! throw Py.ValueError("unsupported format character '"+c+"'"); } int length = string.length(); --- 2225,2232 ---- default: ! throw Py.ValueError("unsupported format character '" + ! codecs.encode(Py.newString(c), null, "replace") + ! "' (0x" + Integer.toHexString(c) + ") at index " + ! (index-1)); } int length = string.length(); |