diff options
author | Leonard Richardson <leonard.richardson@canonical.com> | 2011-02-20 08:37:20 -0500 |
---|---|---|
committer | Leonard Richardson <leonard.richardson@canonical.com> | 2011-02-20 08:37:20 -0500 |
commit | a16883da6445710fcf69cfcc1842fb6883495b1c (patch) | |
tree | 6d9f8cacd7d65be56dec702b597d9a75b4e123fc /beautifulsoup/builder/lxml_builder.py | |
parent | 54f1fb0a0af88c408175cbcdf060d2d04040075d (diff) |
Tag.is_empty_element is determined dynamically, based on a) whether the builder used to create the tag had an explicit list of empty-element tags, and b) whether the tag actually contains anything.
Diffstat (limited to 'beautifulsoup/builder/lxml_builder.py')
-rw-r--r-- | beautifulsoup/builder/lxml_builder.py | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/beautifulsoup/builder/lxml_builder.py b/beautifulsoup/builder/lxml_builder.py index 5e053b1..0cc9e51 100644 --- a/beautifulsoup/builder/lxml_builder.py +++ b/beautifulsoup/builder/lxml_builder.py @@ -7,9 +7,6 @@ import types class LXMLTreeBuilderForXML(TreeBuilder): DEFAULT_PARSER_CLASS = etree.XMLParser - preserve_whitespace_tags = set() - self_closing_tags = set() - @property def default_parser(self): # This can either return a parser object or a class, which @@ -55,9 +52,6 @@ class LXMLTreeBuilderForXML(TreeBuilder): def end(self, name): self.soup.endData() completed_tag = self.soup.tagStack[-1] - if len(completed_tag.contents) == 0: - completed_tag.isSelfClosing = True - self.soup.handle_endtag(name) def pi(self, target, data): |