Create _attr/_attrNS lazily.

This commit is contained in:
Martin v. Löwis 2012-02-19 20:55:05 +01:00
parent 14aa280de2
commit 7b77188e89
2 changed files with 34 additions and 9 deletions

View file

@ -760,6 +760,7 @@ class Namespaces:
del self._ns_ordered_prefixes[:]
if attributes:
node._ensure_attributes()
_attrs = node._attrs
_attrsNS = node._attrsNS
for i in range(0, len(attributes), 2):