Commit ac1af809 authored by Fred Drake's avatar Fred Drake

Handle PEP references the same way RFC references.

parent 0d68246f
...@@ -759,9 +759,9 @@ def skip_leading_nodes(children, start=0): ...@@ -759,9 +759,9 @@ def skip_leading_nodes(children, start=0):
def fixup_rfc_references(doc, fragment): def fixup_rfc_references(doc, fragment):
for rfcnode in find_all_elements(fragment, "rfc"): for rfcnode in find_all_elements_from_set(fragment, ("pep", "rfc")):
rfcnode.appendChild(doc.createTextNode( rfcnode.appendChild(doc.createTextNode(
"RFC " + rfcnode.getAttribute("num"))) rfcnode.tagName.upper() + " " + rfcnode.getAttribute("num")))
def fixup_signatures(doc, fragment): def fixup_signatures(doc, fragment):
...@@ -1026,10 +1026,9 @@ def convert(ifp, ofp): ...@@ -1026,10 +1026,9 @@ def convert(ifp, ofp):
d = {} d = {}
for gi in events.parser.get_empties(): for gi in events.parser.get_empties():
d[gi] = gi d[gi] = gi
if d.has_key("author"): for key in ("author", "pep", "rfc"):
del d["author"] if d.has_key(key):
if d.has_key("rfc"): del d[key]
del d["rfc"]
knownempty = d.has_key knownempty = d.has_key
# #
try: try:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment