diff options
author | Fred Drake <fdrake@acm.org> | 1999-08-26 17:50:26 (GMT) |
---|---|---|
committer | Fred Drake <fdrake@acm.org> | 1999-08-26 17:50:26 (GMT) |
commit | 53eae8e81bfc72754f9be607203c558e0cedee90 (patch) | |
tree | 2fc9c1bbee2cae9ff3d3fa991eedd5d318955400 /Doc/tools | |
parent | 762e206706b5fbf4d541006b8f2b0ca17cac6240 (diff) | |
download | cpython-53eae8e81bfc72754f9be607203c558e0cedee90.zip cpython-53eae8e81bfc72754f9be607203c558e0cedee90.tar.gz cpython-53eae8e81bfc72754f9be607203c558e0cedee90.tar.bz2 |
convert(): Add support for ESIS '&' lines, and make sure we don't
silently ignore unrecognized lines.
Diffstat (limited to 'Doc/tools')
-rwxr-xr-x | Doc/tools/sgmlconv/esis2sgml.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Doc/tools/sgmlconv/esis2sgml.py b/Doc/tools/sgmlconv/esis2sgml.py index 38866ce..adb8873 100755 --- a/Doc/tools/sgmlconv/esis2sgml.py +++ b/Doc/tools/sgmlconv/esis2sgml.py @@ -146,6 +146,11 @@ def convert(ifp, ofp, xml=0, autoclose=(), verbatims=()): attrs[name] = esistools.decode(value) elif type == "e": knownempty = 1 + elif type == "&": + ofp.write("&%s;" % data) + knownempty = 0 + else: + raise RuntimeError, "unrecognized ESIS event type: '%s'" % type if LIST_EMPTIES: dump_empty_element_names(knownempties) |