diff options
author | Mike Gilbert <floppym@gentoo.org> | 2014-04-01 04:47:48 +0000 |
---|---|---|
committer | Mike Gilbert <floppym@gentoo.org> | 2014-04-01 04:47:48 +0000 |
commit | bef4f014f3506b49c43ba880f96802efc6d93556 (patch) | |
tree | a10766440e776e203a7fd03cea0725497edabdaa /dev-python/docutils/files | |
parent | Restore python3.2, though it fails a few tests. (diff) | |
download | gentoo-2-bef4f014f3506b49c43ba880f96802efc6d93556.tar.gz gentoo-2-bef4f014f3506b49c43ba880f96802efc6d93556.tar.bz2 gentoo-2-bef4f014f3506b49c43ba880f96802efc6d93556.zip |
Version bump, add python3.4.
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key 0BBEEA1FEA4843A4)
Diffstat (limited to 'dev-python/docutils/files')
-rw-r--r-- | dev-python/docutils/files/docutils-0.11-python3.3-odt-writer.patch | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/dev-python/docutils/files/docutils-0.11-python3.3-odt-writer.patch b/dev-python/docutils/files/docutils-0.11-python3.3-odt-writer.patch new file mode 100644 index 000000000000..e84256f3dc43 --- /dev/null +++ b/dev-python/docutils/files/docutils-0.11-python3.3-odt-writer.patch @@ -0,0 +1,30 @@ +--- a/docutils/writers/odf_odt/__init__.py ++++ b/docutils/writers/odf_odt/__init__.py +@@ -88,16 +88,20 @@ + # that support for the ability to get the parent of an element. + # + if WhichElementTree == 'elementtree': +- class _ElementInterfaceWrapper(etree._ElementInterface): ++ import weakref ++ _parents = weakref.WeakKeyDictionary() ++ if isinstance(etree.Element, type): ++ _ElementInterface = etree.Element ++ else: ++ _ElementInterface = etree._ElementInterface ++ class _ElementInterfaceWrapper(_ElementInterface): + def __init__(self, tag, attrib=None): +- etree._ElementInterface.__init__(self, tag, attrib) +- if attrib is None: +- attrib = {} +- self.parent = None ++ _ElementInterface.__init__(self, tag, attrib) ++ _parents[self] = None + def setparent(self, parent): +- self.parent = parent ++ _parents[self] = parent + def getparent(self): +- return self.parent ++ return _parents[self] + + + # |