summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew M. Kuchling <amk@amk.ca>2004-07-10 21:49:45 (GMT)
committerAndrew M. Kuchling <amk@amk.ca>2004-07-10 21:49:45 (GMT)
commitf027ca816741fcea6267c6e8ea33ae43edfb7447 (patch)
tree7097854ef9f9c67abff44e003b5e39c4fe833991
parent3e377decefafa80c6266b54e1e02c4699be7f785 (diff)
downloadcpython-f027ca816741fcea6267c6e8ea33ae43edfb7447.zip
cpython-f027ca816741fcea6267c6e8ea33ae43edfb7447.tar.gz
cpython-f027ca816741fcea6267c6e8ea33ae43edfb7447.tar.bz2
[Patch #965175] Incorporate a suggestion for a better error message
-rw-r--r--Lib/markupbase.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/markupbase.py b/Lib/markupbase.py
index c1e5acd..b8d8d5d 100644
--- a/Lib/markupbase.py
+++ b/Lib/markupbase.py
@@ -375,7 +375,8 @@ class ParserBase:
return name.lower(), m.end()
else:
self.updatepos(declstartpos, i)
- self.error("expected name token")
+ self.error("expected name token at %r"
+ % rawdata[declstartpos:declstartpos+20])
# To be overridden -- handlers for unknown objects
def unknown_decl(self, data):