[Python-checkins] r57067 - python/branches/decimal-branch/Lib/decimal.py
facundo.batista
python-checkins at python.org
Wed Aug 15 17:08:47 CEST 2007
Author: facundo.batista
Date: Wed Aug 15 17:08:46 2007
New Revision: 57067
Modified:
python/branches/decimal-branch/Lib/decimal.py
Log:
When passed a bad formed literal to Decimal, now we have a
better error message, more descriptive. (bug #1770009)
Modified: python/branches/decimal-branch/Lib/decimal.py
==============================================================================
--- python/branches/decimal-branch/Lib/decimal.py (original)
+++ python/branches/decimal-branch/Lib/decimal.py Wed Aug 15 17:08:46 2007
@@ -628,7 +628,7 @@
except ValueError:
self._is_special = True
return context._raise_error(ConversionSyntax,
- "non parseable string")
+ "Invalid literal for Decimal: %r" % value)
return self
raise TypeError("Cannot convert %r to Decimal" % value)
More information about the Python-checkins
mailing list