lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-40', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-41" class="py-name"><a title="lxml.etree.XPath" class="py-name" href="#" onclick="return doclink('link-41', 'XPath', 'link-19');">XPath</a></tt><tt class="py-op">(</tt><tt class="py-string">"//label[@for=$id]|//x:label[@for=$id]"</tt><tt class="py-op">,</tt> </tt>
<a name="L102"></a><tt class="py-lineno"> 102</tt> <tt class="py-line"> <tt class="py-name">namespaces</tt><tt class="py-op">=</tt><tt class="py-op">{</tt><tt class="py-string">'x'</tt><tt class="py-op">:</tt><tt id="link-42" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-42', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">}</tt><tt class="py-op">)</tt> </tt>
<a name="L103"></a><tt class="py-lineno"> 103</tt> <tt class="py-line"><tt id="link-43" class="py-name" targets="Variable lxml.html._archive_re=lxml.html-module.html#_archive_re"><a title="lxml.html._archive_re" class="py-name" href="#" onclick="return doclink('link-43', '_archive_re', 'link-43');">_archive_re</a></tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt><tt class="py-string">r'[^ ]+'</tt><tt class="py-op">)</tt> </tt>
-<a name="L104"></a><tt class="py-lineno"> 104</tt> <tt class="py-line"> </tt>
-<a name="_unquote_match"></a><div id="_unquote_match-def"><a name="L105"></a><tt class="py-lineno"> 105</tt> <a class="py-toggle" href="#" id="_unquote_match-toggle" onclick="return toggle('_unquote_match');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_unquote_match">_unquote_match</a><tt class="py-op">(</tt><tt class="py-param">s</tt><tt class="py-op">,</tt> <tt class="py-param">pos</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_unquote_match-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_unquote_match-expanded"><a name="L106"></a><tt class="py-lineno"> 106</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'"'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'"'</tt> <tt class="py-keyword">or</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">"'"</tt> <tt class="py-keyword">and</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">"'"</tt><tt class="py-op">:</tt> </tt>
-<a name="L107"></a><tt class="py-lineno"> 107</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt><tt class="py-op">+</tt><tt class="py-number">1</tt> </tt>
-<a name="L108"></a><tt class="py-lineno"> 108</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L109"></a><tt class="py-lineno"> 109</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">s</tt><tt class="py-op">,</tt><tt class="py-name">pos</tt> </tt>
-</div><a name="L110"></a><tt class="py-lineno"> 110</tt> <tt class="py-line"> </tt>
-<a name="_transform_result"></a><div id="_transform_result-def"><a name="L111"></a><tt class="py-lineno"> 111</tt> <a class="py-toggle" href="#" id="_transform_result-toggle" onclick="return toggle('_transform_result');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_transform_result">_transform_result</a><tt class="py-op">(</tt><tt class="py-param">typ</tt><tt class="py-op">,</tt> <tt class="py-param">result</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_transform_result-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_transform_result-expanded"><a name="L112"></a><tt class="py-lineno"> 112</tt> <tt class="py-line"> <tt class="py-docstring">"""Convert the result back into the input type.</tt> </tt>
-<a name="L113"></a><tt class="py-lineno"> 113</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L114"></a><tt class="py-lineno"> 114</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">issubclass</tt><tt class="py-op">(</tt><tt class="py-name">typ</tt><tt class="py-op">,</tt> <tt class="py-name">bytes</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L115"></a><tt class="py-lineno"> 115</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-44" class="py-name" targets="Method lxml.etree.XSLT.tostring()=lxml.etree.XSLT-class.html#tostring,Function lxml.etree.tostring()=lxml.etree-module.html#tostring"><a title="lxml.etree.XSLT.tostring
-lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-44', 'tostring', 'link-44');">tostring</a></tt><tt class="py-op">(</tt><tt class="py-name">result</tt><tt class="py-op">,</tt> <tt id="link-45" class="py-name" targets="Variable lxml.etree.DocInfo.encoding=lxml.etree.DocInfo-class.html#encoding"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-45', 'encoding', 'link-45');">encoding</a></tt><tt class="py-op">=</tt><tt class="py-string">'utf-8'</tt><tt class="py-op">)</tt> </tt>
-<a name="L116"></a><tt class="py-lineno"> 116</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">issubclass</tt><tt class="py-op">(</tt><tt class="py-name">typ</tt><tt class="py-op">,</tt> <tt class="py-name">unicode</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L117"></a><tt class="py-lineno"> 117</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-46" class="py-name"><a title="lxml.etree.XSLT.tostring
-lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-46', 'tostring', 'link-44');">tostring</a></tt><tt class="py-op">(</tt><tt class="py-name">result</tt><tt class="py-op">,</tt> <tt id="link-47" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-47', 'encoding', 'link-45');">encoding</a></tt><tt class="py-op">=</tt><tt class="py-string">'unicode'</tt><tt class="py-op">)</tt> </tt>
-<a name="L118"></a><tt class="py-lineno"> 118</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L119"></a><tt class="py-lineno"> 119</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">result</tt> </tt>
-</div><a name="L120"></a><tt class="py-lineno"> 120</tt> <tt class="py-line"> </tt>
-<a name="_nons"></a><div id="_nons-def"><a name="L121"></a><tt class="py-lineno"> 121</tt> <a class="py-toggle" href="#" id="_nons-toggle" onclick="return toggle('_nons');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_nons">_nons</a><tt class="py-op">(</tt><tt class="py-param">tag</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_nons-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_nons-expanded"><a name="L122"></a><tt class="py-lineno"> 122</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-48" class="py-name" targets="Variable lxml.etree._Comment.tag=lxml.etree._Comment-class.html#tag,Variable lxml.etree._Element.tag=lxml.etree._Element-class.html#tag,Variable lxml.etree._Entity.tag=lxml.etree._Entity-class.html#tag,Variable lxml.etree._ProcessingInstruction.tag=lxml.etree._ProcessingInstruction-class.html#tag,Function lxml.tests.test_xpathevaluator.tag()=lxml.tests.test_xpathevaluator-module.html#tag,Variable xml.etree.ElementTree.Element.tag=xml.etree.ElementTree.Element-class.html#tag"><a title="lxml.etree._Comment.tag
+<a name="L104"></a><tt class="py-lineno"> 104</tt> <tt class="py-line"><tt class="py-name">_parse_meta_refresh_url</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
+<a name="L105"></a><tt class="py-lineno"> 105</tt> <tt class="py-line"> <tt class="py-string">r'[^;=]*;\s*(?:url\s*=\s*)?(?P<url>.*)$'</tt><tt class="py-op">,</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt id="link-44" class="py-name"><a title="lxml.html.builder.I" class="py-name" href="#" onclick="return doclink('link-44', 'I', 'link-38');">I</a></tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">search</tt> </tt>
+<a name="L106"></a><tt class="py-lineno"> 106</tt> <tt class="py-line"> </tt>
+<a name="L107"></a><tt class="py-lineno"> 107</tt> <tt class="py-line"> </tt>
+<a name="_unquote_match"></a><div id="_unquote_match-def"><a name="L108"></a><tt class="py-lineno"> 108</tt> <a class="py-toggle" href="#" id="_unquote_match-toggle" onclick="return toggle('_unquote_match');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_unquote_match">_unquote_match</a><tt class="py-op">(</tt><tt class="py-param">s</tt><tt class="py-op">,</tt> <tt class="py-param">pos</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_unquote_match-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_unquote_match-expanded"><a name="L109"></a><tt class="py-lineno"> 109</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'"'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'"'</tt> <tt class="py-keyword">or</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">"'"</tt> <tt class="py-keyword">and</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">"'"</tt><tt class="py-op">:</tt> </tt>
+<a name="L110"></a><tt class="py-lineno"> 110</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">s</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt><tt class="py-op">+</tt><tt class="py-number">1</tt> </tt>
+<a name="L111"></a><tt class="py-lineno"> 111</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L112"></a><tt class="py-lineno"> 112</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">s</tt><tt class="py-op">,</tt><tt class="py-name">pos</tt> </tt>
+</div><a name="L113"></a><tt class="py-lineno"> 113</tt> <tt class="py-line"> </tt>
+<a name="_transform_result"></a><div id="_transform_result-def"><a name="L114"></a><tt class="py-lineno"> 114</tt> <a class="py-toggle" href="#" id="_transform_result-toggle" onclick="return toggle('_transform_result');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_transform_result">_transform_result</a><tt class="py-op">(</tt><tt class="py-param">typ</tt><tt class="py-op">,</tt> <tt class="py-param">result</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_transform_result-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_transform_result-expanded"><a name="L115"></a><tt class="py-lineno"> 115</tt> <tt class="py-line"> <tt class="py-docstring">"""Convert the result back into the input type.</tt> </tt>
+<a name="L116"></a><tt class="py-lineno"> 116</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L117"></a><tt class="py-lineno"> 117</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">issubclass</tt><tt class="py-op">(</tt><tt class="py-name">typ</tt><tt class="py-op">,</tt> <tt class="py-name">bytes</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L118"></a><tt class="py-lineno"> 118</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-45" class="py-name" targets="Method lxml.etree.XSLT.tostring()=lxml.etree.XSLT-class.html#tostring,Function lxml.etree.tostring()=lxml.etree-module.html#tostring"><a title="lxml.etree.XSLT.tostring
+lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-45', 'tostring', 'link-45');">tostring</a></tt><tt class="py-op">(</tt><tt class="py-name">result</tt><tt class="py-op">,</tt> <tt id="link-46" class="py-name" targets="Variable lxml.etree.DocInfo.encoding=lxml.etree.DocInfo-class.html#encoding"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-46', 'encoding', 'link-46');">encoding</a></tt><tt class="py-op">=</tt><tt class="py-string">'utf-8'</tt><tt class="py-op">)</tt> </tt>
+<a name="L119"></a><tt class="py-lineno"> 119</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">issubclass</tt><tt class="py-op">(</tt><tt class="py-name">typ</tt><tt class="py-op">,</tt> <tt class="py-name">unicode</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L120"></a><tt class="py-lineno"> 120</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-47" class="py-name"><a title="lxml.etree.XSLT.tostring
+lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-47', 'tostring', 'link-45');">tostring</a></tt><tt class="py-op">(</tt><tt class="py-name">result</tt><tt class="py-op">,</tt> <tt id="link-48" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-48', 'encoding', 'link-46');">encoding</a></tt><tt class="py-op">=</tt><tt class="py-string">'unicode'</tt><tt class="py-op">)</tt> </tt>
+<a name="L121"></a><tt class="py-lineno"> 121</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L122"></a><tt class="py-lineno"> 122</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">result</tt> </tt>
+</div><a name="L123"></a><tt class="py-lineno"> 123</tt> <tt class="py-line"> </tt>
+<a name="_nons"></a><div id="_nons-def"><a name="L124"></a><tt class="py-lineno"> 124</tt> <a class="py-toggle" href="#" id="_nons-toggle" onclick="return toggle('_nons');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_nons">_nons</a><tt class="py-op">(</tt><tt class="py-param">tag</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_nons-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_nons-expanded"><a name="L125"></a><tt class="py-lineno"> 125</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-49" class="py-name" targets="Variable lxml.etree._Comment.tag=lxml.etree._Comment-class.html#tag,Variable lxml.etree._Element.tag=lxml.etree._Element-class.html#tag,Variable lxml.etree._Entity.tag=lxml.etree._Entity-class.html#tag,Variable lxml.etree._ProcessingInstruction.tag=lxml.etree._ProcessingInstruction-class.html#tag,Function lxml.tests.test_xpathevaluator.tag()=lxml.tests.test_xpathevaluator-module.html#tag,Variable xml.etree.ElementTree.Element.tag=xml.etree.ElementTree.Element-class.html#tag"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-48', 'tag', 'link-48');">tag</a></tt><tt class="py-op">,</tt> <tt id="link-49" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-49', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L123"></a><tt class="py-lineno"> 123</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-50" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-49', 'tag', 'link-49');">tag</a></tt><tt class="py-op">,</tt> <tt id="link-50" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-50', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L126"></a><tt class="py-lineno"> 126</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-51" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-50', 'tag', 'link-48');">tag</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'{'</tt> <tt class="py-keyword">and</tt> <tt id="link-51" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-51', 'tag', 'link-49');">tag</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt class="py-string">'{'</tt> <tt class="py-keyword">and</tt> <tt id="link-52" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-51', 'tag', 'link-48');">tag</a></tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-52" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-52', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt><tt class="py-op">+</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt id="link-53" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-53', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L124"></a><tt class="py-lineno"> 124</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-54" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-52', 'tag', 'link-49');">tag</a></tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-53" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-53', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt><tt class="py-op">+</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">==</tt> <tt id="link-54" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-54', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L127"></a><tt class="py-lineno"> 127</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-55" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-54', 'tag', 'link-48');">tag</a></tt><tt class="py-op">.</tt><tt class="py-name">split</tt><tt class="py-op">(</tt><tt class="py-string">'}'</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> </tt>
-<a name="L125"></a><tt class="py-lineno"> 125</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-55" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-55', 'tag', 'link-49');">tag</a></tt><tt class="py-op">.</tt><tt class="py-name">split</tt><tt class="py-op">(</tt><tt class="py-string">'}'</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> </tt>
+<a name="L128"></a><tt class="py-lineno"> 128</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-56" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-55', 'tag', 'link-48');">tag</a></tt> </tt>
-</div><a name="L126"></a><tt class="py-lineno"> 126</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin"></a><div id="HtmlMixin-def"><a name="L127"></a><tt class="py-lineno"> 127</tt> <a class="py-toggle" href="#" id="HtmlMixin-toggle" onclick="return toggle('HtmlMixin');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html">HtmlMixin</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlMixin-expanded"><a name="L128"></a><tt class="py-lineno"> 128</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.base_url"></a><div id="HtmlMixin.base_url-def"><a name="L129"></a><tt class="py-lineno"> 129</tt> <a class="py-toggle" href="#" id="HtmlMixin.base_url-toggle" onclick="return toggle('HtmlMixin.base_url');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#base_url">base_url</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.base_url-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.base_url-expanded"><a name="L130"></a><tt class="py-lineno"> 130</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L131"></a><tt class="py-lineno"> 131</tt> <tt class="py-line"><tt class="py-docstring"> Returns the base URL, given when the page was parsed.</tt> </tt>
-<a name="L132"></a><tt class="py-lineno"> 132</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L133"></a><tt class="py-lineno"> 133</tt> <tt class="py-line"><tt class="py-docstring"> Use with ``urlparse.urljoin(el.base_url, href)`` to get</tt> </tt>
-<a name="L134"></a><tt class="py-lineno"> 134</tt> <tt class="py-line"><tt class="py-docstring"> absolute URLs.</tt> </tt>
-<a name="L135"></a><tt class="py-lineno"> 135</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L136"></a><tt class="py-lineno"> 136</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-56" class="py-name" targets="Method lxml.etree._Element.getroottree()=lxml.etree._Element-class.html#getroottree"><a title="lxml.etree._Element.getroottree" class="py-name" href="#" onclick="return doclink('link-56', 'getroottree', 'link-56');">getroottree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-57" class="py-name" targets="Variable lxml.etree._ElementTree.docinfo=lxml.etree._ElementTree-class.html#docinfo"><a title="lxml.etree._ElementTree.docinfo" class="py-name" href="#" onclick="return doclink('link-57', 'docinfo', 'link-57');">docinfo</a></tt><tt class="py-op">.</tt><tt id="link-58" class="py-name" targets="Variable lxml.etree.DocInfo.URL=lxml.etree.DocInfo-class.html#URL"><a title="lxml.etree.DocInfo.URL" class="py-name" href="#" onclick="return doclink('link-58', 'URL', 'link-58');">URL</a></tt> </tt>
-</div><a name="L137"></a><tt class="py-lineno"> 137</tt> <tt class="py-line"> <tt id="link-59" class="py-name" targets="Variable lxml.html.HtmlMixin.base_url=lxml.html.HtmlMixin-class.html#base_url"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-59', 'base_url', 'link-59');">base_url</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-60" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-60', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-61" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-61', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">.</tt><tt id="link-62" class="py-name" targets="Variable lxml.html.ElementSoup.__doc__=lxml.html.ElementSoup-module.html#__doc__,Variable lxml.html.soupparser.__doc__=lxml.html.soupparser-module.html#__doc__"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-62', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L138"></a><tt class="py-lineno"> 138</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.forms"></a><div id="HtmlMixin.forms-def"><a name="L139"></a><tt class="py-lineno"> 139</tt> <a class="py-toggle" href="#" id="HtmlMixin.forms-toggle" onclick="return toggle('HtmlMixin.forms');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#forms">forms</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.forms-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.forms-expanded"><a name="L140"></a><tt class="py-lineno"> 140</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L141"></a><tt class="py-lineno"> 141</tt> <tt class="py-line"><tt class="py-docstring"> Return a list of all the forms</tt> </tt>
-<a name="L142"></a><tt class="py-lineno"> 142</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L143"></a><tt class="py-lineno"> 143</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-63" class="py-name"><a title="lxml.html._forms_xpath" class="py-name" href="#" onclick="return doclink('link-63', '_forms_xpath', 'link-25');">_forms_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L144"></a><tt class="py-lineno"> 144</tt> <tt class="py-line"> <tt id="link-64" class="py-name" targets="Variable lxml.html.HtmlMixin.forms=lxml.html.HtmlMixin-class.html#forms,Variable lxml.html.clean.Cleaner.forms=lxml.html.clean.Cleaner-class.html#forms"><a title="lxml.html.HtmlMixin.forms
-lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-64', 'forms', 'link-64');">forms</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-65" class="py-name"><a title="lxml.html.HtmlMixin.forms
-lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-65', 'forms', 'link-64');">forms</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-66" class="py-name"><a title="lxml.html.HtmlMixin.forms
-lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-66', 'forms', 'link-64');">forms</a></tt><tt class="py-op">.</tt><tt id="link-67" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-67', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L145"></a><tt class="py-lineno"> 145</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.body"></a><div id="HtmlMixin.body-def"><a name="L146"></a><tt class="py-lineno"> 146</tt> <a class="py-toggle" href="#" id="HtmlMixin.body-toggle" onclick="return toggle('HtmlMixin.body');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#body">body</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.body-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.body-expanded"><a name="L147"></a><tt class="py-lineno"> 147</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L148"></a><tt class="py-lineno"> 148</tt> <tt class="py-line"><tt class="py-docstring"> Return the <body> element. Can be called from a child element</tt> </tt>
-<a name="L149"></a><tt class="py-lineno"> 149</tt> <tt class="py-line"><tt class="py-docstring"> to get the document's head.</tt> </tt>
-<a name="L150"></a><tt class="py-lineno"> 150</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L151"></a><tt class="py-lineno"> 151</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-68" class="py-name" targets="Method lxml.etree._Element.xpath()=lxml.etree._Element-class.html#xpath,Method lxml.etree._ElementTree.xpath()=lxml.etree._ElementTree-class.html#xpath,Function lxml.tests.test_xpathevaluator.xpath()=lxml.tests.test_xpathevaluator-module.html#xpath"><a title="lxml.etree._Element.xpath
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-56', 'tag', 'link-49');">tag</a></tt> </tt>
+</div><a name="L129"></a><tt class="py-lineno"> 129</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin"></a><div id="HtmlMixin-def"><a name="L130"></a><tt class="py-lineno"> 130</tt> <a class="py-toggle" href="#" id="HtmlMixin-toggle" onclick="return toggle('HtmlMixin');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html">HtmlMixin</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlMixin-expanded"><a name="L131"></a><tt class="py-lineno"> 131</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.base_url"></a><div id="HtmlMixin.base_url-def"><a name="L132"></a><tt class="py-lineno"> 132</tt> <a class="py-toggle" href="#" id="HtmlMixin.base_url-toggle" onclick="return toggle('HtmlMixin.base_url');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#base_url">base_url</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.base_url-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.base_url-expanded"><a name="L133"></a><tt class="py-lineno"> 133</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L134"></a><tt class="py-lineno"> 134</tt> <tt class="py-line"><tt class="py-docstring"> Returns the base URL, given when the page was parsed.</tt> </tt>
+<a name="L135"></a><tt class="py-lineno"> 135</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L136"></a><tt class="py-lineno"> 136</tt> <tt class="py-line"><tt class="py-docstring"> Use with ``urlparse.urljoin(el.base_url, href)`` to get</tt> </tt>
+<a name="L137"></a><tt class="py-lineno"> 137</tt> <tt class="py-line"><tt class="py-docstring"> absolute URLs.</tt> </tt>
+<a name="L138"></a><tt class="py-lineno"> 138</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L139"></a><tt class="py-lineno"> 139</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-57" class="py-name" targets="Method lxml.etree._Element.getroottree()=lxml.etree._Element-class.html#getroottree"><a title="lxml.etree._Element.getroottree" class="py-name" href="#" onclick="return doclink('link-57', 'getroottree', 'link-57');">getroottree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-58" class="py-name" targets="Variable lxml.etree._ElementTree.docinfo=lxml.etree._ElementTree-class.html#docinfo"><a title="lxml.etree._ElementTree.docinfo" class="py-name" href="#" onclick="return doclink('link-58', 'docinfo', 'link-58');">docinfo</a></tt><tt class="py-op">.</tt><tt id="link-59" class="py-name" targets="Variable lxml.etree.DocInfo.URL=lxml.etree.DocInfo-class.html#URL"><a title="lxml.etree.DocInfo.URL" class="py-name" href="#" onclick="return doclink('link-59', 'URL', 'link-59');">URL</a></tt> </tt>
+</div><a name="L140"></a><tt class="py-lineno"> 140</tt> <tt class="py-line"> <tt id="link-60" class="py-name" targets="Variable lxml.html.HtmlMixin.base_url=lxml.html.HtmlMixin-class.html#base_url"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-60', 'base_url', 'link-60');">base_url</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-61" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-61', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-62" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-62', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">.</tt><tt id="link-63" class="py-name" targets="Variable lxml.html.ElementSoup.__doc__=lxml.html.ElementSoup-module.html#__doc__,Variable lxml.html.soupparser.__doc__=lxml.html.soupparser-module.html#__doc__"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-63', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L141"></a><tt class="py-lineno"> 141</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.forms"></a><div id="HtmlMixin.forms-def"><a name="L142"></a><tt class="py-lineno"> 142</tt> <a class="py-toggle" href="#" id="HtmlMixin.forms-toggle" onclick="return toggle('HtmlMixin.forms');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#forms">forms</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.forms-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.forms-expanded"><a name="L143"></a><tt class="py-lineno"> 143</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L144"></a><tt class="py-lineno"> 144</tt> <tt class="py-line"><tt class="py-docstring"> Return a list of all the forms</tt> </tt>
+<a name="L145"></a><tt class="py-lineno"> 145</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L146"></a><tt class="py-lineno"> 146</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-64" class="py-name"><a title="lxml.html._forms_xpath" class="py-name" href="#" onclick="return doclink('link-64', '_forms_xpath', 'link-25');">_forms_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L147"></a><tt class="py-lineno"> 147</tt> <tt class="py-line"> <tt id="link-65" class="py-name" targets="Variable lxml.html.HtmlMixin.forms=lxml.html.HtmlMixin-class.html#forms,Variable lxml.html.clean.Cleaner.forms=lxml.html.clean.Cleaner-class.html#forms"><a title="lxml.html.HtmlMixin.forms
+lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-65', 'forms', 'link-65');">forms</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-66" class="py-name"><a title="lxml.html.HtmlMixin.forms
+lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-66', 'forms', 'link-65');">forms</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-67" class="py-name"><a title="lxml.html.HtmlMixin.forms
+lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-67', 'forms', 'link-65');">forms</a></tt><tt class="py-op">.</tt><tt id="link-68" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-68', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L148"></a><tt class="py-lineno"> 148</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.body"></a><div id="HtmlMixin.body-def"><a name="L149"></a><tt class="py-lineno"> 149</tt> <a class="py-toggle" href="#" id="HtmlMixin.body-toggle" onclick="return toggle('HtmlMixin.body');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#body">body</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.body-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.body-expanded"><a name="L150"></a><tt class="py-lineno"> 150</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L151"></a><tt class="py-lineno"> 151</tt> <tt class="py-line"><tt class="py-docstring"> Return the <body> element. Can be called from a child element</tt> </tt>
+<a name="L152"></a><tt class="py-lineno"> 152</tt> <tt class="py-line"><tt class="py-docstring"> to get the document's head.</tt> </tt>
+<a name="L153"></a><tt class="py-lineno"> 153</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L154"></a><tt class="py-lineno"> 154</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-69" class="py-name" targets="Method lxml.etree._Element.xpath()=lxml.etree._Element-class.html#xpath,Method lxml.etree._ElementTree.xpath()=lxml.etree._ElementTree-class.html#xpath,Function lxml.tests.test_xpathevaluator.xpath()=lxml.tests.test_xpathevaluator-module.html#xpath"><a title="lxml.etree._Element.xpath
lxml.etree._ElementTree.xpath
-lxml.tests.test_xpathevaluator.xpath" class="py-name" href="#" onclick="return doclink('link-68', 'xpath', 'link-68');">xpath</a></tt><tt class="py-op">(</tt><tt class="py-string">'//body|//x:body'</tt><tt class="py-op">,</tt> <tt class="py-name">namespaces</tt><tt class="py-op">=</tt><tt class="py-op">{</tt><tt class="py-string">'x'</tt><tt class="py-op">:</tt><tt id="link-69" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-69', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">}</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L152"></a><tt class="py-lineno"> 152</tt> <tt class="py-line"> <tt id="link-70" class="py-name" targets="Variable lxml.html.HtmlMixin.body=lxml.html.HtmlMixin-class.html#body"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-70', 'body', 'link-70');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-71" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-71', 'body', 'link-70');">body</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-72" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-72', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-73" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-73', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L153"></a><tt class="py-lineno"> 153</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.head"></a><div id="HtmlMixin.head-def"><a name="L154"></a><tt class="py-lineno"> 154</tt> <a class="py-toggle" href="#" id="HtmlMixin.head-toggle" onclick="return toggle('HtmlMixin.head');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#head">head</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.head-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.head-expanded"><a name="L155"></a><tt class="py-lineno"> 155</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L156"></a><tt class="py-lineno"> 156</tt> <tt class="py-line"><tt class="py-docstring"> Returns the <head> element. Can be called from a child</tt> </tt>
-<a name="L157"></a><tt class="py-lineno"> 157</tt> <tt class="py-line"><tt class="py-docstring"> element to get the document's head.</tt> </tt>
-<a name="L158"></a><tt class="py-lineno"> 158</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L159"></a><tt class="py-lineno"> 159</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-74" class="py-name"><a title="lxml.etree._Element.xpath
+lxml.tests.test_xpathevaluator.xpath" class="py-name" href="#" onclick="return doclink('link-69', 'xpath', 'link-69');">xpath</a></tt><tt class="py-op">(</tt><tt class="py-string">'//body|//x:body'</tt><tt class="py-op">,</tt> <tt class="py-name">namespaces</tt><tt class="py-op">=</tt><tt class="py-op">{</tt><tt class="py-string">'x'</tt><tt class="py-op">:</tt><tt id="link-70" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-70', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">}</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L155"></a><tt class="py-lineno"> 155</tt> <tt class="py-line"> <tt id="link-71" class="py-name" targets="Variable lxml.html.HtmlMixin.body=lxml.html.HtmlMixin-class.html#body"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-71', 'body', 'link-71');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-72" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-72', 'body', 'link-71');">body</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-73" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-73', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-74" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-74', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L156"></a><tt class="py-lineno"> 156</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.head"></a><div id="HtmlMixin.head-def"><a name="L157"></a><tt class="py-lineno"> 157</tt> <a class="py-toggle" href="#" id="HtmlMixin.head-toggle" onclick="return toggle('HtmlMixin.head');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#head">head</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.head-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.head-expanded"><a name="L158"></a><tt class="py-lineno"> 158</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L159"></a><tt class="py-lineno"> 159</tt> <tt class="py-line"><tt class="py-docstring"> Returns the <head> element. Can be called from a child</tt> </tt>
+<a name="L160"></a><tt class="py-lineno"> 160</tt> <tt class="py-line"><tt class="py-docstring"> element to get the document's head.</tt> </tt>
+<a name="L161"></a><tt class="py-lineno"> 161</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L162"></a><tt class="py-lineno"> 162</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-75" class="py-name"><a title="lxml.etree._Element.xpath
lxml.etree._ElementTree.xpath
-lxml.tests.test_xpathevaluator.xpath" class="py-name" href="#" onclick="return doclink('link-74', 'xpath', 'link-68');">xpath</a></tt><tt class="py-op">(</tt><tt class="py-string">'//head|//x:head'</tt><tt class="py-op">,</tt> <tt class="py-name">namespaces</tt><tt class="py-op">=</tt><tt class="py-op">{</tt><tt class="py-string">'x'</tt><tt class="py-op">:</tt><tt id="link-75" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-75', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">}</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L160"></a><tt class="py-lineno"> 160</tt> <tt class="py-line"> <tt id="link-76" class="py-name" targets="Variable lxml.html.HtmlMixin.head=lxml.html.HtmlMixin-class.html#head"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-76', 'head', 'link-76');">head</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-77" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-77', 'head', 'link-76');">head</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-78" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-78', 'head', 'link-76');">head</a></tt><tt class="py-op">.</tt><tt id="link-79" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-79', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L161"></a><tt class="py-lineno"> 161</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin._label__get"></a><div id="HtmlMixin._label__get-def"><a name="L162"></a><tt class="py-lineno"> 162</tt> <a class="py-toggle" href="#" id="HtmlMixin._label__get-toggle" onclick="return toggle('HtmlMixin._label__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#_label__get">_label__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin._label__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin._label__get-expanded"><a name="L163"></a><tt class="py-lineno"> 163</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L164"></a><tt class="py-lineno"> 164</tt> <tt class="py-line"><tt class="py-docstring"> Get or set any <label> element associated with this element.</tt> </tt>
-<a name="L165"></a><tt class="py-lineno"> 165</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L166"></a><tt class="py-lineno"> 166</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-80" class="py-name" targets="Method lxml.etree._Attrib.get()=lxml.etree._Attrib-class.html#get,Method lxml.etree._Element.get()=lxml.etree._Element-class.html#get,Method lxml.etree._IDDict.get()=lxml.etree._IDDict-class.html#get,Method lxml.etree._ProcessingInstruction.get()=lxml.etree._ProcessingInstruction-class.html#get"><a title="lxml.etree._Attrib.get
+lxml.tests.test_xpathevaluator.xpath" class="py-name" href="#" onclick="return doclink('link-75', 'xpath', 'link-69');">xpath</a></tt><tt class="py-op">(</tt><tt class="py-string">'//head|//x:head'</tt><tt class="py-op">,</tt> <tt class="py-name">namespaces</tt><tt class="py-op">=</tt><tt class="py-op">{</tt><tt class="py-string">'x'</tt><tt class="py-op">:</tt><tt id="link-76" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-76', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">}</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L163"></a><tt class="py-lineno"> 163</tt> <tt class="py-line"> <tt id="link-77" class="py-name" targets="Variable lxml.html.HtmlMixin.head=lxml.html.HtmlMixin-class.html#head"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-77', 'head', 'link-77');">head</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-78" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-78', 'head', 'link-77');">head</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-79" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-79', 'head', 'link-77');">head</a></tt><tt class="py-op">.</tt><tt id="link-80" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-80', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L164"></a><tt class="py-lineno"> 164</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin._label__get"></a><div id="HtmlMixin._label__get-def"><a name="L165"></a><tt class="py-lineno"> 165</tt> <a class="py-toggle" href="#" id="HtmlMixin._label__get-toggle" onclick="return toggle('HtmlMixin._label__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#_label__get">_label__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin._label__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin._label__get-expanded"><a name="L166"></a><tt class="py-lineno"> 166</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L167"></a><tt class="py-lineno"> 167</tt> <tt class="py-line"><tt class="py-docstring"> Get or set any <label> element associated with this element.</tt> </tt>
+<a name="L168"></a><tt class="py-lineno"> 168</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L169"></a><tt class="py-lineno"> 169</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-81" class="py-name" targets="Method lxml.etree._Attrib.get()=lxml.etree._Attrib-class.html#get,Method lxml.etree._Element.get()=lxml.etree._Element-class.html#get,Method lxml.etree._IDDict.get()=lxml.etree._IDDict-class.html#get,Method lxml.etree._ProcessingInstruction.get()=lxml.etree._ProcessingInstruction-class.html#get"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-80', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
-<a name="L167"></a><tt class="py-lineno"> 167</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
-<a name="L168"></a><tt class="py-lineno"> 168</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-<a name="L169"></a><tt class="py-lineno"> 169</tt> <tt class="py-line"> <tt class="py-name">result</tt> <tt class="py-op">=</tt> <tt id="link-81" class="py-name"><a title="lxml.html._label_xpath" class="py-name" href="#" onclick="return doclink('link-81', '_label_xpath', 'link-39');">_label_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">=</tt><tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
-<a name="L170"></a><tt class="py-lineno"> 170</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">result</tt><tt class="py-op">:</tt> </tt>
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-81', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
+<a name="L170"></a><tt class="py-lineno"> 170</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
<a name="L171"></a><tt class="py-lineno"> 171</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-<a name="L172"></a><tt class="py-lineno"> 172</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L173"></a><tt class="py-lineno"> 173</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">result</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-</div><a name="HtmlMixin._label__set"></a><div id="HtmlMixin._label__set-def"><a name="L174"></a><tt class="py-lineno"> 174</tt> <a class="py-toggle" href="#" id="HtmlMixin._label__set-toggle" onclick="return toggle('HtmlMixin._label__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#_label__set">_label__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">label</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin._label__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin._label__set-expanded"><a name="L175"></a><tt class="py-lineno"> 175</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-82" class="py-name"><a title="lxml.etree._Attrib.get
+<a name="L172"></a><tt class="py-lineno"> 172</tt> <tt class="py-line"> <tt class="py-name">result</tt> <tt class="py-op">=</tt> <tt id="link-82" class="py-name"><a title="lxml.html._label_xpath" class="py-name" href="#" onclick="return doclink('link-82', '_label_xpath', 'link-39');">_label_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">=</tt><tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
+<a name="L173"></a><tt class="py-lineno"> 173</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">result</tt><tt class="py-op">:</tt> </tt>
+<a name="L174"></a><tt class="py-lineno"> 174</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
+<a name="L175"></a><tt class="py-lineno"> 175</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L176"></a><tt class="py-lineno"> 176</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">result</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+</div><a name="HtmlMixin._label__set"></a><div id="HtmlMixin._label__set-def"><a name="L177"></a><tt class="py-lineno"> 177</tt> <a class="py-toggle" href="#" id="HtmlMixin._label__set-toggle" onclick="return toggle('HtmlMixin._label__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#_label__set">_label__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">label</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin._label__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin._label__set-expanded"><a name="L178"></a><tt class="py-lineno"> 178</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-83" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-82', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
-<a name="L176"></a><tt class="py-lineno"> 176</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
-<a name="L177"></a><tt class="py-lineno"> 177</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
-<a name="L178"></a><tt class="py-lineno"> 178</tt> <tt class="py-line"> <tt class="py-string">"You cannot set a label for an element (%r) that has no id"</tt> </tt>
-<a name="L179"></a><tt class="py-lineno"> 179</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-<a name="L180"></a><tt class="py-lineno"> 180</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt id="link-83" class="py-name" targets="Variable lxml.html.HtmlMixin.label=lxml.html.HtmlMixin-class.html#label"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-83', 'label', 'link-83');">label</a></tt><tt class="py-op">.</tt><tt id="link-84" class="py-name"><a title="lxml.etree._Comment.tag
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-83', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
+<a name="L179"></a><tt class="py-lineno"> 179</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
+<a name="L180"></a><tt class="py-lineno"> 180</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
+<a name="L181"></a><tt class="py-lineno"> 181</tt> <tt class="py-line"> <tt class="py-string">"You cannot set a label for an element (%r) that has no id"</tt> </tt>
+<a name="L182"></a><tt class="py-lineno"> 182</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+<a name="L183"></a><tt class="py-lineno"> 183</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt id="link-84" class="py-name" targets="Variable lxml.html.HtmlMixin.label=lxml.html.HtmlMixin-class.html#label"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-84', 'label', 'link-84');">label</a></tt><tt class="py-op">.</tt><tt id="link-85" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-84', 'tag', 'link-48');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-string">'label'</tt><tt class="py-op">:</tt> </tt>
-<a name="L181"></a><tt class="py-lineno"> 181</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
-<a name="L182"></a><tt class="py-lineno"> 182</tt> <tt class="py-line"> <tt class="py-string">"You can only assign label to a label element (not %r)"</tt> </tt>
-<a name="L183"></a><tt class="py-lineno"> 183</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt id="link-85" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-85', 'label', 'link-83');">label</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L184"></a><tt class="py-lineno"> 184</tt> <tt class="py-line"> <tt id="link-86" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-86', 'label', 'link-83');">label</a></tt><tt class="py-op">.</tt><tt id="link-87" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-87', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'for'</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
-</div><a name="HtmlMixin._label__del"></a><div id="HtmlMixin._label__del-def"><a name="L185"></a><tt class="py-lineno"> 185</tt> <a class="py-toggle" href="#" id="HtmlMixin._label__del-toggle" onclick="return toggle('HtmlMixin._label__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#_label__del">_label__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin._label__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin._label__del-expanded"><a name="L186"></a><tt class="py-lineno"> 186</tt> <tt class="py-line"> <tt id="link-88" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-88', 'label', 'link-83');">label</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-89" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-89', 'label', 'link-83');">label</a></tt> </tt>
-<a name="L187"></a><tt class="py-lineno"> 187</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-90" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-90', 'label', 'link-83');">label</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L188"></a><tt class="py-lineno"> 188</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt id="link-91" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-91', 'label', 'link-83');">label</a></tt><tt class="py-op">.</tt><tt id="link-92" class="py-name" targets="Variable lxml.etree._Element.attrib=lxml.etree._Element-class.html#attrib,Variable lxml.etree._ProcessingInstruction.attrib=lxml.etree._ProcessingInstruction-class.html#attrib,Variable xml.etree.ElementTree.Element.attrib=xml.etree.ElementTree.Element-class.html#attrib"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-85', 'tag', 'link-49');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-op">!=</tt> <tt class="py-string">'label'</tt><tt class="py-op">:</tt> </tt>
+<a name="L184"></a><tt class="py-lineno"> 184</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
+<a name="L185"></a><tt class="py-lineno"> 185</tt> <tt class="py-line"> <tt class="py-string">"You can only assign label to a label element (not %r)"</tt> </tt>
+<a name="L186"></a><tt class="py-lineno"> 186</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt id="link-86" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-86', 'label', 'link-84');">label</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L187"></a><tt class="py-lineno"> 187</tt> <tt class="py-line"> <tt id="link-87" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-87', 'label', 'link-84');">label</a></tt><tt class="py-op">.</tt><tt id="link-88" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-88', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'for'</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
+</div><a name="HtmlMixin._label__del"></a><div id="HtmlMixin._label__del-def"><a name="L188"></a><tt class="py-lineno"> 188</tt> <a class="py-toggle" href="#" id="HtmlMixin._label__del-toggle" onclick="return toggle('HtmlMixin._label__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#_label__del">_label__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin._label__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin._label__del-expanded"><a name="L189"></a><tt class="py-lineno"> 189</tt> <tt class="py-line"> <tt id="link-89" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-89', 'label', 'link-84');">label</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-90" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-90', 'label', 'link-84');">label</a></tt> </tt>
+<a name="L190"></a><tt class="py-lineno"> 190</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-91" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-91', 'label', 'link-84');">label</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L191"></a><tt class="py-lineno"> 191</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt id="link-92" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-92', 'label', 'link-84');">label</a></tt><tt class="py-op">.</tt><tt id="link-93" class="py-name" targets="Variable lxml.etree._Element.attrib=lxml.etree._Element-class.html#attrib,Variable lxml.etree._ProcessingInstruction.attrib=lxml.etree._ProcessingInstruction-class.html#attrib,Variable xml.etree.ElementTree.Element.attrib=xml.etree.ElementTree.Element-class.html#attrib"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-92', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'for'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L189"></a><tt class="py-lineno"> 189</tt> <tt class="py-line"> <tt id="link-93" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-93', 'label', 'link-83');">label</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-94" class="py-name" targets="Method lxml.html.HtmlMixin._label__get()=lxml.html.HtmlMixin-class.html#_label__get"><a title="lxml.html.HtmlMixin._label__get" class="py-name" href="#" onclick="return doclink('link-94', '_label__get', 'link-94');">_label__get</a></tt><tt class="py-op">,</tt> <tt id="link-95" class="py-name" targets="Method lxml.html.HtmlMixin._label__set()=lxml.html.HtmlMixin-class.html#_label__set"><a title="lxml.html.HtmlMixin._label__set" class="py-name" href="#" onclick="return doclink('link-95', '_label__set', 'link-95');">_label__set</a></tt><tt class="py-op">,</tt> <tt id="link-96" class="py-name" targets="Method lxml.html.HtmlMixin._label__del()=lxml.html.HtmlMixin-class.html#_label__del"><a title="lxml.html.HtmlMixin._label__del" class="py-name" href="#" onclick="return doclink('link-96', '_label__del', 'link-96');">_label__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-97" class="py-name"><a title="lxml.html.HtmlMixin._label__get" class="py-name" href="#" onclick="return doclink('link-97', '_label__get', 'link-94');">_label__get</a></tt><tt class="py-op">.</tt><tt id="link-98" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-98', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L190"></a><tt class="py-lineno"> 190</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.drop_tree"></a><div id="HtmlMixin.drop_tree-def"><a name="L191"></a><tt class="py-lineno"> 191</tt> <a class="py-toggle" href="#" id="HtmlMixin.drop_tree-toggle" onclick="return toggle('HtmlMixin.drop_tree');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#drop_tree">drop_tree</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.drop_tree-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.drop_tree-expanded"><a name="L192"></a><tt class="py-lineno"> 192</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L193"></a><tt class="py-lineno"> 193</tt> <tt class="py-line"><tt class="py-docstring"> Removes this element from the tree, including its children and</tt> </tt>
-<a name="L194"></a><tt class="py-lineno"> 194</tt> <tt class="py-line"><tt class="py-docstring"> text. The tail text is joined to the previous element or</tt> </tt>
-<a name="L195"></a><tt class="py-lineno"> 195</tt> <tt class="py-line"><tt class="py-docstring"> parent.</tt> </tt>
-<a name="L196"></a><tt class="py-lineno"> 196</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L197"></a><tt class="py-lineno"> 197</tt> <tt class="py-line"> <tt class="py-name">parent</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-99" class="py-name" targets="Method lxml.etree._Element.getparent()=lxml.etree._Element-class.html#getparent,Method lxml.etree._ElementStringResult.getparent()=lxml.etree._ElementStringResult-class.html#getparent,Method lxml.etree._ElementUnicodeResult.getparent()=lxml.etree._ElementUnicodeResult-class.html#getparent"><a title="lxml.etree._Element.getparent
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-93', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'for'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L192"></a><tt class="py-lineno"> 192</tt> <tt class="py-line"> <tt id="link-94" class="py-name"><a title="lxml.html.HtmlMixin.label" class="py-name" href="#" onclick="return doclink('link-94', 'label', 'link-84');">label</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-95" class="py-name" targets="Method lxml.html.HtmlMixin._label__get()=lxml.html.HtmlMixin-class.html#_label__get"><a title="lxml.html.HtmlMixin._label__get" class="py-name" href="#" onclick="return doclink('link-95', '_label__get', 'link-95');">_label__get</a></tt><tt class="py-op">,</tt> <tt id="link-96" class="py-name" targets="Method lxml.html.HtmlMixin._label__set()=lxml.html.HtmlMixin-class.html#_label__set"><a title="lxml.html.HtmlMixin._label__set" class="py-name" href="#" onclick="return doclink('link-96', '_label__set', 'link-96');">_label__set</a></tt><tt class="py-op">,</tt> <tt id="link-97" class="py-name" targets="Method lxml.html.HtmlMixin._label__del()=lxml.html.HtmlMixin-class.html#_label__del"><a title="lxml.html.HtmlMixin._label__del" class="py-name" href="#" onclick="return doclink('link-97', '_label__del', 'link-97');">_label__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-98" class="py-name"><a title="lxml.html.HtmlMixin._label__get" class="py-name" href="#" onclick="return doclink('link-98', '_label__get', 'link-95');">_label__get</a></tt><tt class="py-op">.</tt><tt id="link-99" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-99', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L193"></a><tt class="py-lineno"> 193</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.drop_tree"></a><div id="HtmlMixin.drop_tree-def"><a name="L194"></a><tt class="py-lineno"> 194</tt> <a class="py-toggle" href="#" id="HtmlMixin.drop_tree-toggle" onclick="return toggle('HtmlMixin.drop_tree');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#drop_tree">drop_tree</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.drop_tree-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.drop_tree-expanded"><a name="L195"></a><tt class="py-lineno"> 195</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L196"></a><tt class="py-lineno"> 196</tt> <tt class="py-line"><tt class="py-docstring"> Removes this element from the tree, including its children and</tt> </tt>
+<a name="L197"></a><tt class="py-lineno"> 197</tt> <tt class="py-line"><tt class="py-docstring"> text. The tail text is joined to the previous element or</tt> </tt>
+<a name="L198"></a><tt class="py-lineno"> 198</tt> <tt class="py-line"><tt class="py-docstring"> parent.</tt> </tt>
+<a name="L199"></a><tt class="py-lineno"> 199</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L200"></a><tt class="py-lineno"> 200</tt> <tt class="py-line"> <tt class="py-name">parent</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-100" class="py-name" targets="Method lxml.etree._Element.getparent()=lxml.etree._Element-class.html#getparent,Method lxml.etree._ElementStringResult.getparent()=lxml.etree._ElementStringResult-class.html#getparent,Method lxml.etree._ElementUnicodeResult.getparent()=lxml.etree._ElementUnicodeResult-class.html#getparent"><a title="lxml.etree._Element.getparent
lxml.etree._ElementStringResult.getparent
-lxml.etree._ElementUnicodeResult.getparent" class="py-name" href="#" onclick="return doclink('link-99', 'getparent', 'link-99');">getparent</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L198"></a><tt class="py-lineno"> 198</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">parent</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt> </tt>
-<a name="L199"></a><tt class="py-lineno"> 199</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-100" class="py-name" targets="Variable lxml.etree._Element.tail=lxml.etree._Element-class.html#tail,Variable xml.etree.ElementTree.Element.tail=xml.etree.ElementTree.Element-class.html#tail"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-100', 'tail', 'link-100');">tail</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L200"></a><tt class="py-lineno"> 200</tt> <tt class="py-line"> <tt class="py-name">previous</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-101" class="py-name" targets="Method lxml.etree._Element.getprevious()=lxml.etree._Element-class.html#getprevious"><a title="lxml.etree._Element.getprevious" class="py-name" href="#" onclick="return doclink('link-101', 'getprevious', 'link-101');">getprevious</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L201"></a><tt class="py-lineno"> 201</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">previous</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L202"></a><tt class="py-lineno"> 202</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-102" class="py-name" targets="Variable lxml.etree.QName.text=lxml.etree.QName-class.html#text,Variable lxml.etree._Element.text=lxml.etree._Element-class.html#text,Variable lxml.etree._Entity.text=lxml.etree._Entity-class.html#text,Variable lxml.objectify.ObjectifiedElement.text=lxml.objectify.ObjectifiedElement-class.html#text,Variable xml.etree.ElementTree.Element.text=xml.etree.ElementTree.Element-class.html#text"><a title="lxml.etree.QName.text
+lxml.etree._ElementUnicodeResult.getparent" class="py-name" href="#" onclick="return doclink('link-100', 'getparent', 'link-100');">getparent</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L201"></a><tt class="py-lineno"> 201</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">parent</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt> </tt>
+<a name="L202"></a><tt class="py-lineno"> 202</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-101" class="py-name" targets="Variable lxml.etree._Element.tail=lxml.etree._Element-class.html#tail,Variable xml.etree.ElementTree.Element.tail=xml.etree.ElementTree.Element-class.html#tail"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-101', 'tail', 'link-101');">tail</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L203"></a><tt class="py-lineno"> 203</tt> <tt class="py-line"> <tt class="py-name">previous</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-102" class="py-name" targets="Method lxml.etree._Element.getprevious()=lxml.etree._Element-class.html#getprevious"><a title="lxml.etree._Element.getprevious" class="py-name" href="#" onclick="return doclink('link-102', 'getprevious', 'link-102');">getprevious</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L204"></a><tt class="py-lineno"> 204</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">previous</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L205"></a><tt class="py-lineno"> 205</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-103" class="py-name" targets="Variable lxml.etree.QName.text=lxml.etree.QName-class.html#text,Variable lxml.etree._Element.text=lxml.etree._Element-class.html#text,Variable lxml.etree._Entity.text=lxml.etree._Entity-class.html#text,Variable lxml.objectify.ObjectifiedElement.text=lxml.objectify.ObjectifiedElement-class.html#text,Variable xml.etree.ElementTree.Element.text=xml.etree.ElementTree.Element-class.html#text"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-102', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-103" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-103', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-104" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-103', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-104" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-104', 'tail', 'link-100');">tail</a></tt> </tt>
-<a name="L203"></a><tt class="py-lineno"> 203</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L204"></a><tt class="py-lineno"> 204</tt> <tt class="py-line"> <tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-105" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-105', 'tail', 'link-100');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-106" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-106', 'tail', 'link-100');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-107" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-107', 'tail', 'link-100');">tail</a></tt> </tt>
-<a name="L205"></a><tt class="py-lineno"> 205</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-108" class="py-name" targets="Method lxml.etree._Element.remove()=lxml.etree._Element-class.html#remove,Method lxml.html.CheckboxValues.remove()=lxml.html.CheckboxValues-class.html#remove,Method lxml.html.MultipleSelectOptions.remove()=lxml.html.MultipleSelectOptions-class.html#remove"><a title="lxml.etree._Element.remove
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-104', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-105" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-105', 'tail', 'link-101');">tail</a></tt> </tt>
+<a name="L206"></a><tt class="py-lineno"> 206</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L207"></a><tt class="py-lineno"> 207</tt> <tt class="py-line"> <tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-106" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-106', 'tail', 'link-101');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-107" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-107', 'tail', 'link-101');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-108" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-108', 'tail', 'link-101');">tail</a></tt> </tt>
+<a name="L208"></a><tt class="py-lineno"> 208</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-109" class="py-name" targets="Method lxml.etree._Element.remove()=lxml.etree._Element-class.html#remove,Method lxml.html.CheckboxValues.remove()=lxml.html.CheckboxValues-class.html#remove,Method lxml.html.MultipleSelectOptions.remove()=lxml.html.MultipleSelectOptions-class.html#remove"><a title="lxml.etree._Element.remove
lxml.html.CheckboxValues.remove
-lxml.html.MultipleSelectOptions.remove" class="py-name" href="#" onclick="return doclink('link-108', 'remove', 'link-108');">remove</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L206"></a><tt class="py-lineno"> 206</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.drop_tag"></a><div id="HtmlMixin.drop_tag-def"><a name="L207"></a><tt class="py-lineno"> 207</tt> <a class="py-toggle" href="#" id="HtmlMixin.drop_tag-toggle" onclick="return toggle('HtmlMixin.drop_tag');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#drop_tag">drop_tag</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.drop_tag-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.drop_tag-expanded"><a name="L208"></a><tt class="py-lineno"> 208</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L209"></a><tt class="py-lineno"> 209</tt> <tt class="py-line"><tt class="py-docstring"> Remove the tag, but not its children or text. The children and text</tt> </tt>
-<a name="L210"></a><tt class="py-lineno"> 210</tt> <tt class="py-line"><tt class="py-docstring"> are merged into the parent.</tt> </tt>
-<a name="L211"></a><tt class="py-lineno"> 211</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L212"></a><tt class="py-lineno"> 212</tt> <tt class="py-line"><tt class="py-docstring"> Example::</tt> </tt>
-<a name="L213"></a><tt class="py-lineno"> 213</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L214"></a><tt class="py-lineno"> 214</tt> <tt class="py-line"><tt class="py-docstring"> >>> h = fragment_fromstring('<div>Hello <b>World!</b></div>')</tt> </tt>
-<a name="L215"></a><tt class="py-lineno"> 215</tt> <tt class="py-line"><tt class="py-docstring"> >>> h.find('.//b').drop_tag()</tt> </tt>
-<a name="L216"></a><tt class="py-lineno"> 216</tt> <tt class="py-line"><tt class="py-docstring"> >>> print(tostring(h, encoding='unicode'))</tt> </tt>
-<a name="L217"></a><tt class="py-lineno"> 217</tt> <tt class="py-line"><tt class="py-docstring"> <div>Hello World!</div></tt> </tt>
-<a name="L218"></a><tt class="py-lineno"> 218</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L219"></a><tt class="py-lineno"> 219</tt> <tt class="py-line"> <tt class="py-name">parent</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-109" class="py-name"><a title="lxml.etree._Element.getparent
+lxml.html.MultipleSelectOptions.remove" class="py-name" href="#" onclick="return doclink('link-109', 'remove', 'link-109');">remove</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L209"></a><tt class="py-lineno"> 209</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.drop_tag"></a><div id="HtmlMixin.drop_tag-def"><a name="L210"></a><tt class="py-lineno"> 210</tt> <a class="py-toggle" href="#" id="HtmlMixin.drop_tag-toggle" onclick="return toggle('HtmlMixin.drop_tag');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#drop_tag">drop_tag</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.drop_tag-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.drop_tag-expanded"><a name="L211"></a><tt class="py-lineno"> 211</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L212"></a><tt class="py-lineno"> 212</tt> <tt class="py-line"><tt class="py-docstring"> Remove the tag, but not its children or text. The children and text</tt> </tt>
+<a name="L213"></a><tt class="py-lineno"> 213</tt> <tt class="py-line"><tt class="py-docstring"> are merged into the parent.</tt> </tt>
+<a name="L214"></a><tt class="py-lineno"> 214</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L215"></a><tt class="py-lineno"> 215</tt> <tt class="py-line"><tt class="py-docstring"> Example::</tt> </tt>
+<a name="L216"></a><tt class="py-lineno"> 216</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L217"></a><tt class="py-lineno"> 217</tt> <tt class="py-line"><tt class="py-docstring"> >>> h = fragment_fromstring('<div>Hello <b>World!</b></div>')</tt> </tt>
+<a name="L218"></a><tt class="py-lineno"> 218</tt> <tt class="py-line"><tt class="py-docstring"> >>> h.find('.//b').drop_tag()</tt> </tt>
+<a name="L219"></a><tt class="py-lineno"> 219</tt> <tt class="py-line"><tt class="py-docstring"> >>> print(tostring(h, encoding='unicode'))</tt> </tt>
+<a name="L220"></a><tt class="py-lineno"> 220</tt> <tt class="py-line"><tt class="py-docstring"> <div>Hello World!</div></tt> </tt>
+<a name="L221"></a><tt class="py-lineno"> 221</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L222"></a><tt class="py-lineno"> 222</tt> <tt class="py-line"> <tt class="py-name">parent</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-110" class="py-name"><a title="lxml.etree._Element.getparent
lxml.etree._ElementStringResult.getparent
-lxml.etree._ElementUnicodeResult.getparent" class="py-name" href="#" onclick="return doclink('link-109', 'getparent', 'link-99');">getparent</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L220"></a><tt class="py-lineno"> 220</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">parent</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt> </tt>
-<a name="L221"></a><tt class="py-lineno"> 221</tt> <tt class="py-line"> <tt class="py-name">previous</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-110" class="py-name"><a title="lxml.etree._Element.getprevious" class="py-name" href="#" onclick="return doclink('link-110', 'getprevious', 'link-101');">getprevious</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L222"></a><tt class="py-lineno"> 222</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-111" class="py-name"><a title="lxml.etree.QName.text
+lxml.etree._ElementUnicodeResult.getparent" class="py-name" href="#" onclick="return doclink('link-110', 'getparent', 'link-100');">getparent</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L223"></a><tt class="py-lineno"> 223</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">parent</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt> </tt>
+<a name="L224"></a><tt class="py-lineno"> 224</tt> <tt class="py-line"> <tt class="py-name">previous</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-111" class="py-name"><a title="lxml.etree._Element.getprevious" class="py-name" href="#" onclick="return doclink('link-111', 'getprevious', 'link-102');">getprevious</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L225"></a><tt class="py-lineno"> 225</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-112" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-111', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">and</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-112" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-112', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">and</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-113" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-112', 'tag', 'link-48');">tag</a></tt><tt class="py-op">,</tt> <tt id="link-113" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-113', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L223"></a><tt class="py-lineno"> 223</tt> <tt class="py-line"> <tt class="py-comment"># not a Comment, etc.</tt> </tt>
-<a name="L224"></a><tt class="py-lineno"> 224</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">previous</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L225"></a><tt class="py-lineno"> 225</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-114" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-113', 'tag', 'link-49');">tag</a></tt><tt class="py-op">,</tt> <tt id="link-114" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-114', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L226"></a><tt class="py-lineno"> 226</tt> <tt class="py-line"> <tt class="py-comment"># not a Comment, etc.</tt> </tt>
+<a name="L227"></a><tt class="py-lineno"> 227</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">previous</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L228"></a><tt class="py-lineno"> 228</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-115" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-114', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-115" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-115', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-116" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-115', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-116" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-116', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-117" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-116', 'text', 'link-102');">text</a></tt> </tt>
-<a name="L226"></a><tt class="py-lineno"> 226</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L227"></a><tt class="py-lineno"> 227</tt> <tt class="py-line"> <tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-117" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-117', 'tail', 'link-100');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-118" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-118', 'tail', 'link-100');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-119" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-117', 'text', 'link-103');">text</a></tt> </tt>
+<a name="L229"></a><tt class="py-lineno"> 229</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L230"></a><tt class="py-lineno"> 230</tt> <tt class="py-line"> <tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-118" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-118', 'tail', 'link-101');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-119" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-119', 'tail', 'link-101');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-120" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-119', 'text', 'link-102');">text</a></tt> </tt>
-<a name="L228"></a><tt class="py-lineno"> 228</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-120" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-120', 'tail', 'link-100');">tail</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L229"></a><tt class="py-lineno"> 229</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L230"></a><tt class="py-lineno"> 230</tt> <tt class="py-line"> <tt class="py-name">last</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> </tt>
-<a name="L231"></a><tt class="py-lineno"> 231</tt> <tt class="py-line"> <tt class="py-name">last</tt><tt class="py-op">.</tt><tt id="link-121" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-121', 'tail', 'link-100');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">last</tt><tt class="py-op">.</tt><tt id="link-122" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-122', 'tail', 'link-100');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-123" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-123', 'tail', 'link-100');">tail</a></tt> </tt>
-<a name="L232"></a><tt class="py-lineno"> 232</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">previous</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L233"></a><tt class="py-lineno"> 233</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-124" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-120', 'text', 'link-103');">text</a></tt> </tt>
+<a name="L231"></a><tt class="py-lineno"> 231</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-121" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-121', 'tail', 'link-101');">tail</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L232"></a><tt class="py-lineno"> 232</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L233"></a><tt class="py-lineno"> 233</tt> <tt class="py-line"> <tt class="py-name">last</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> </tt>
+<a name="L234"></a><tt class="py-lineno"> 234</tt> <tt class="py-line"> <tt class="py-name">last</tt><tt class="py-op">.</tt><tt id="link-122" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-122', 'tail', 'link-101');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">last</tt><tt class="py-op">.</tt><tt id="link-123" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-123', 'tail', 'link-101');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-124" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-124', 'tail', 'link-101');">tail</a></tt> </tt>
+<a name="L235"></a><tt class="py-lineno"> 235</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">previous</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L236"></a><tt class="py-lineno"> 236</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-125" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-124', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-125" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-125', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-126" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-125', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-126" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-126', 'tail', 'link-100');">tail</a></tt> </tt>
-<a name="L234"></a><tt class="py-lineno"> 234</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L235"></a><tt class="py-lineno"> 235</tt> <tt class="py-line"> <tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-127" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-127', 'tail', 'link-100');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-128" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-128', 'tail', 'link-100');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-129" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-129', 'tail', 'link-100');">tail</a></tt> </tt>
-<a name="L236"></a><tt class="py-lineno"> 236</tt> <tt class="py-line"> <tt id="link-130" class="py-name" targets="Method lxml.etree._Element.index()=lxml.etree._Element-class.html#index"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-130', 'index', 'link-130');">index</a></tt> <tt class="py-op">=</tt> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-131" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-131', 'index', 'link-130');">index</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-<a name="L237"></a><tt class="py-lineno"> 237</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">[</tt><tt id="link-132" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-132', 'index', 'link-130');">index</a></tt><tt class="py-op">:</tt><tt id="link-133" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-133', 'index', 'link-130');">index</a></tt><tt class="py-op">+</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L238"></a><tt class="py-lineno"> 238</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.find_rel_links"></a><div id="HtmlMixin.find_rel_links-def"><a name="L239"></a><tt class="py-lineno"> 239</tt> <a class="py-toggle" href="#" id="HtmlMixin.find_rel_links-toggle" onclick="return toggle('HtmlMixin.find_rel_links');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#find_rel_links">find_rel_links</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">rel</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.find_rel_links-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.find_rel_links-expanded"><a name="L240"></a><tt class="py-lineno"> 240</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L241"></a><tt class="py-lineno"> 241</tt> <tt class="py-line"><tt class="py-docstring"> Find any links like ``<a rel="{rel}">...</a>``; returns a list of elements.</tt> </tt>
-<a name="L242"></a><tt class="py-lineno"> 242</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L243"></a><tt class="py-lineno"> 243</tt> <tt class="py-line"> <tt class="py-name">rel</tt> <tt class="py-op">=</tt> <tt class="py-name">rel</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L244"></a><tt class="py-lineno"> 244</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-op">[</tt><tt class="py-name">el</tt> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-134" class="py-name"><a title="lxml.html._rel_links_xpath" class="py-name" href="#" onclick="return doclink('link-134', '_rel_links_xpath', 'link-17');">_rel_links_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-<a name="L245"></a><tt class="py-lineno"> 245</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-135" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-126', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-127" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-127', 'tail', 'link-101');">tail</a></tt> </tt>
+<a name="L237"></a><tt class="py-lineno"> 237</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L238"></a><tt class="py-lineno"> 238</tt> <tt class="py-line"> <tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-128" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-128', 'tail', 'link-101');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">previous</tt><tt class="py-op">.</tt><tt id="link-129" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-129', 'tail', 'link-101');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-130" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-130', 'tail', 'link-101');">tail</a></tt> </tt>
+<a name="L239"></a><tt class="py-lineno"> 239</tt> <tt class="py-line"> <tt id="link-131" class="py-name" targets="Method lxml.etree._Element.index()=lxml.etree._Element-class.html#index"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-131', 'index', 'link-131');">index</a></tt> <tt class="py-op">=</tt> <tt class="py-name">parent</tt><tt class="py-op">.</tt><tt id="link-132" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-132', 'index', 'link-131');">index</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+<a name="L240"></a><tt class="py-lineno"> 240</tt> <tt class="py-line"> <tt class="py-name">parent</tt><tt class="py-op">[</tt><tt id="link-133" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-133', 'index', 'link-131');">index</a></tt><tt class="py-op">:</tt><tt id="link-134" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-134', 'index', 'link-131');">index</a></tt><tt class="py-op">+</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L241"></a><tt class="py-lineno"> 241</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.find_rel_links"></a><div id="HtmlMixin.find_rel_links-def"><a name="L242"></a><tt class="py-lineno"> 242</tt> <a class="py-toggle" href="#" id="HtmlMixin.find_rel_links-toggle" onclick="return toggle('HtmlMixin.find_rel_links');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#find_rel_links">find_rel_links</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">rel</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.find_rel_links-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.find_rel_links-expanded"><a name="L243"></a><tt class="py-lineno"> 243</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L244"></a><tt class="py-lineno"> 244</tt> <tt class="py-line"><tt class="py-docstring"> Find any links like ``<a rel="{rel}">...</a>``; returns a list of elements.</tt> </tt>
+<a name="L245"></a><tt class="py-lineno"> 245</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L246"></a><tt class="py-lineno"> 246</tt> <tt class="py-line"> <tt class="py-name">rel</tt> <tt class="py-op">=</tt> <tt class="py-name">rel</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L247"></a><tt class="py-lineno"> 247</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-op">[</tt><tt class="py-name">el</tt> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-135" class="py-name"><a title="lxml.html._rel_links_xpath" class="py-name" href="#" onclick="return doclink('link-135', '_rel_links_xpath', 'link-17');">_rel_links_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+<a name="L248"></a><tt class="py-lineno"> 248</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-136" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-135', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'rel'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">rel</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L246"></a><tt class="py-lineno"> 246</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.find_class"></a><div id="HtmlMixin.find_class-def"><a name="L247"></a><tt class="py-lineno"> 247</tt> <a class="py-toggle" href="#" id="HtmlMixin.find_class-toggle" onclick="return toggle('HtmlMixin.find_class');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#find_class">find_class</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">class_name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.find_class-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.find_class-expanded"><a name="L248"></a><tt class="py-lineno"> 248</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L249"></a><tt class="py-lineno"> 249</tt> <tt class="py-line"><tt class="py-docstring"> Find any elements with the given class name.</tt> </tt>
-<a name="L250"></a><tt class="py-lineno"> 250</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L251"></a><tt class="py-lineno"> 251</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-136" class="py-name"><a title="lxml.html._class_xpath" class="py-name" href="#" onclick="return doclink('link-136', '_class_xpath', 'link-29');">_class_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-name">class_name</tt><tt class="py-op">=</tt><tt class="py-name">class_name</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L252"></a><tt class="py-lineno"> 252</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.get_element_by_id"></a><div id="HtmlMixin.get_element_by_id-def"><a name="L253"></a><tt class="py-lineno"> 253</tt> <a class="py-toggle" href="#" id="HtmlMixin.get_element_by_id-toggle" onclick="return toggle('HtmlMixin.get_element_by_id');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#get_element_by_id">get_element_by_id</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">id</tt><tt class="py-op">,</tt> <tt class="py-op">*</tt><tt class="py-param">default</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.get_element_by_id-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.get_element_by_id-expanded"><a name="L254"></a><tt class="py-lineno"> 254</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L255"></a><tt class="py-lineno"> 255</tt> <tt class="py-line"><tt class="py-docstring"> Get the first element in a document with the given id. If none is</tt> </tt>
-<a name="L256"></a><tt class="py-lineno"> 256</tt> <tt class="py-line"><tt class="py-docstring"> found, return the default argument if provided or raise KeyError</tt> </tt>
-<a name="L257"></a><tt class="py-lineno"> 257</tt> <tt class="py-line"><tt class="py-docstring"> otherwise.</tt> </tt>
-<a name="L258"></a><tt class="py-lineno"> 258</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L259"></a><tt class="py-lineno"> 259</tt> <tt class="py-line"><tt class="py-docstring"> Note that there can be more than one element with the same id,</tt> </tt>
-<a name="L260"></a><tt class="py-lineno"> 260</tt> <tt class="py-line"><tt class="py-docstring"> and this isn't uncommon in HTML documents found in the wild.</tt> </tt>
-<a name="L261"></a><tt class="py-lineno"> 261</tt> <tt class="py-line"><tt class="py-docstring"> Browsers return only the first match, and this function does</tt> </tt>
-<a name="L262"></a><tt class="py-lineno"> 262</tt> <tt class="py-line"><tt class="py-docstring"> the same.</tt> </tt>
-<a name="L263"></a><tt class="py-lineno"> 263</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L264"></a><tt class="py-lineno"> 264</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
-<a name="L265"></a><tt class="py-lineno"> 265</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: should this check for multiple matches?</tt> </tt>
-<a name="L266"></a><tt class="py-lineno"> 266</tt> <tt class="py-line"> <tt class="py-comment"># browsers just return the first one</tt> </tt>
-<a name="L267"></a><tt class="py-lineno"> 267</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-137" class="py-name"><a title="lxml.html._id_xpath" class="py-name" href="#" onclick="return doclink('link-137', '_id_xpath', 'link-32');">_id_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">=</tt><tt class="py-name">id</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L268"></a><tt class="py-lineno"> 268</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">IndexError</tt><tt class="py-op">:</tt> </tt>
-<a name="L269"></a><tt class="py-lineno"> 269</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">default</tt><tt class="py-op">:</tt> </tt>
-<a name="L270"></a><tt class="py-lineno"> 270</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">default</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L271"></a><tt class="py-lineno"> 271</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L272"></a><tt class="py-lineno"> 272</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt><tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L273"></a><tt class="py-lineno"> 273</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.text_content"></a><div id="HtmlMixin.text_content-def"><a name="L274"></a><tt class="py-lineno"> 274</tt> <a class="py-toggle" href="#" id="HtmlMixin.text_content-toggle" onclick="return toggle('HtmlMixin.text_content');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#text_content">text_content</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.text_content-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.text_content-expanded"><a name="L275"></a><tt class="py-lineno"> 275</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L276"></a><tt class="py-lineno"> 276</tt> <tt class="py-line"><tt class="py-docstring"> Return the text content of the tag (and the text in any children).</tt> </tt>
-<a name="L277"></a><tt class="py-lineno"> 277</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L278"></a><tt class="py-lineno"> 278</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-138" class="py-name"><a title="lxml.html._collect_string_content" class="py-name" href="#" onclick="return doclink('link-138', '_collect_string_content', 'link-35');">_collect_string_content</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L279"></a><tt class="py-lineno"> 279</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.cssselect"></a><div id="HtmlMixin.cssselect-def"><a name="L280"></a><tt class="py-lineno"> 280</tt> <a class="py-toggle" href="#" id="HtmlMixin.cssselect-toggle" onclick="return toggle('HtmlMixin.cssselect');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#cssselect">cssselect</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">expr</tt><tt class="py-op">,</tt> <tt class="py-param">translator</tt><tt class="py-op">=</tt><tt class="py-string">'html'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.cssselect-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.cssselect-expanded"><a name="L281"></a><tt class="py-lineno"> 281</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L282"></a><tt class="py-lineno"> 282</tt> <tt class="py-line"><tt class="py-docstring"> Run the CSS expression on this element and its children,</tt> </tt>
-<a name="L283"></a><tt class="py-lineno"> 283</tt> <tt class="py-line"><tt class="py-docstring"> returning a list of the results.</tt> </tt>
-<a name="L284"></a><tt class="py-lineno"> 284</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L285"></a><tt class="py-lineno"> 285</tt> <tt class="py-line"><tt class="py-docstring"> Equivalent to lxml.cssselect.CSSSelect(expr, translator='html')(self)</tt> </tt>
-<a name="L286"></a><tt class="py-lineno"> 286</tt> <tt class="py-line"><tt class="py-docstring"> -- note that pre-compiling the expression can provide a substantial</tt> </tt>
-<a name="L287"></a><tt class="py-lineno"> 287</tt> <tt class="py-line"><tt class="py-docstring"> speedup.</tt> </tt>
-<a name="L288"></a><tt class="py-lineno"> 288</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L289"></a><tt class="py-lineno"> 289</tt> <tt class="py-line"> <tt class="py-comment"># Do the import here to make the dependency optional.</tt> </tt>
-<a name="L290"></a><tt class="py-lineno"> 290</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt id="link-139" class="py-name"><a title="lxml" class="py-name" href="#" onclick="return doclink('link-139', 'lxml', 'link-2');">lxml</a></tt><tt class="py-op">.</tt><tt id="link-140" class="py-name" targets="Module lxml.cssselect=lxml.cssselect-module.html,Method lxml.html.HtmlMixin.cssselect()=lxml.html.HtmlMixin-class.html#cssselect"><a title="lxml.cssselect
-lxml.html.HtmlMixin.cssselect" class="py-name" href="#" onclick="return doclink('link-140', 'cssselect', 'link-140');">cssselect</a></tt> <tt class="py-keyword">import</tt> <tt id="link-141" class="py-name" targets="Class lxml.cssselect.CSSSelector=lxml.cssselect.CSSSelector-class.html"><a title="lxml.cssselect.CSSSelector" class="py-name" href="#" onclick="return doclink('link-141', 'CSSSelector', 'link-141');">CSSSelector</a></tt> </tt>
-<a name="L291"></a><tt class="py-lineno"> 291</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-142" class="py-name"><a title="lxml.cssselect.CSSSelector" class="py-name" href="#" onclick="return doclink('link-142', 'CSSSelector', 'link-141');">CSSSelector</a></tt><tt class="py-op">(</tt><tt class="py-name">expr</tt><tt class="py-op">,</tt> <tt class="py-name">translator</tt><tt class="py-op">=</tt><tt class="py-name">translator</tt><tt class="py-op">)</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L292"></a><tt class="py-lineno"> 292</tt> <tt class="py-line"> </tt>
-<a name="L293"></a><tt class="py-lineno"> 293</tt> <tt class="py-line"> <tt class="py-comment">########################################</tt> </tt>
-<a name="L294"></a><tt class="py-lineno"> 294</tt> <tt class="py-line"> <tt class="py-comment">## Link functions</tt> </tt>
-<a name="L295"></a><tt class="py-lineno"> 295</tt> <tt class="py-line"> <tt class="py-comment">########################################</tt> </tt>
-<a name="L296"></a><tt class="py-lineno"> 296</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.make_links_absolute"></a><div id="HtmlMixin.make_links_absolute-def"><a name="L297"></a><tt class="py-lineno"> 297</tt> <a class="py-toggle" href="#" id="HtmlMixin.make_links_absolute-toggle" onclick="return toggle('HtmlMixin.make_links_absolute');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#make_links_absolute">make_links_absolute</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">resolve_base_href</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> </tt>
-<a name="L298"></a><tt class="py-lineno"> 298</tt> <tt class="py-line"> <tt class="py-param">handle_failures</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.make_links_absolute-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.make_links_absolute-expanded"><a name="L299"></a><tt class="py-lineno"> 299</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L300"></a><tt class="py-lineno"> 300</tt> <tt class="py-line"><tt class="py-docstring"> Make all links in the document absolute, given the</tt> </tt>
-<a name="L301"></a><tt class="py-lineno"> 301</tt> <tt class="py-line"><tt class="py-docstring"> ``base_url`` for the document (the full URL where the document</tt> </tt>
-<a name="L302"></a><tt class="py-lineno"> 302</tt> <tt class="py-line"><tt class="py-docstring"> came from), or if no ``base_url`` is given, then the ``.base_url``</tt> </tt>
-<a name="L303"></a><tt class="py-lineno"> 303</tt> <tt class="py-line"><tt class="py-docstring"> of the document.</tt> </tt>
-<a name="L304"></a><tt class="py-lineno"> 304</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L305"></a><tt class="py-lineno"> 305</tt> <tt class="py-line"><tt class="py-docstring"> If ``resolve_base_href`` is true, then any ``<base href>``</tt> </tt>
-<a name="L306"></a><tt class="py-lineno"> 306</tt> <tt class="py-line"><tt class="py-docstring"> tags in the document are used *and* removed from the document.</tt> </tt>
-<a name="L307"></a><tt class="py-lineno"> 307</tt> <tt class="py-line"><tt class="py-docstring"> If it is false then any such tag is ignored.</tt> </tt>
-<a name="L308"></a><tt class="py-lineno"> 308</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L309"></a><tt class="py-lineno"> 309</tt> <tt class="py-line"><tt class="py-docstring"> If ``handle_failures`` is None (default), a failure to process</tt> </tt>
-<a name="L310"></a><tt class="py-lineno"> 310</tt> <tt class="py-line"><tt class="py-docstring"> a URL will abort the processing. If set to 'ignore', errors</tt> </tt>
-<a name="L311"></a><tt class="py-lineno"> 311</tt> <tt class="py-line"><tt class="py-docstring"> are ignored. If set to 'discard', failing URLs will be removed.</tt> </tt>
-<a name="L312"></a><tt class="py-lineno"> 312</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L313"></a><tt class="py-lineno"> 313</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-143" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-143', 'base_url', 'link-59');">base_url</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L314"></a><tt class="py-lineno"> 314</tt> <tt class="py-line"> <tt id="link-144" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-144', 'base_url', 'link-59');">base_url</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-145" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-145', 'base_url', 'link-59');">base_url</a></tt> </tt>
-<a name="L315"></a><tt class="py-lineno"> 315</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-146" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-146', 'base_url', 'link-59');">base_url</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L316"></a><tt class="py-lineno"> 316</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
-<a name="L317"></a><tt class="py-lineno"> 317</tt> <tt class="py-line"> <tt class="py-string">"No base_url given, and the document has no base_url"</tt><tt class="py-op">)</tt> </tt>
-<a name="L318"></a><tt class="py-lineno"> 318</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-147" class="py-name" targets="Method lxml.html.HtmlMixin.resolve_base_href()=lxml.html.HtmlMixin-class.html#resolve_base_href,Variable lxml.html.resolve_base_href=lxml.html-module.html#resolve_base_href"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-147', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L319"></a><tt class="py-lineno"> 319</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-148" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-148', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L320"></a><tt class="py-lineno"> 320</tt> <tt class="py-line"> </tt>
-<a name="L321"></a><tt class="py-lineno"> 321</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">handle_failures</tt> <tt class="py-op">==</tt> <tt class="py-string">'ignore'</tt><tt class="py-op">:</tt> </tt>
-<a name="L322"></a><tt class="py-lineno"> 322</tt> <tt class="py-line"> <tt class="py-keyword">def</tt> <tt class="py-def-name">link_repl</tt><tt class="py-op">(</tt><tt class="py-param">href</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L323"></a><tt class="py-lineno"> 323</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
-<a name="L324"></a><tt class="py-lineno"> 324</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-149" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-149', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">href</tt><tt class="py-op">)</tt> </tt>
-<a name="L325"></a><tt class="py-lineno"> 325</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">ValueError</tt><tt class="py-op">:</tt> </tt>
-<a name="L326"></a><tt class="py-lineno"> 326</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">href</tt> </tt>
-</div><a name="L327"></a><tt class="py-lineno"> 327</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">handle_failures</tt> <tt class="py-op">==</tt> <tt class="py-string">'discard'</tt><tt class="py-op">:</tt> </tt>
-<a name="L328"></a><tt class="py-lineno"> 328</tt> <tt class="py-line"> <tt class="py-keyword">def</tt> <tt class="py-def-name">link_repl</tt><tt class="py-op">(</tt><tt class="py-param">href</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L329"></a><tt class="py-lineno"> 329</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
-<a name="L330"></a><tt class="py-lineno"> 330</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-150" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-150', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">href</tt><tt class="py-op">)</tt> </tt>
-<a name="L331"></a><tt class="py-lineno"> 331</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">ValueError</tt><tt class="py-op">:</tt> </tt>
-<a name="L332"></a><tt class="py-lineno"> 332</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-</div><a name="L333"></a><tt class="py-lineno"> 333</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">handle_failures</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L334"></a><tt class="py-lineno"> 334</tt> <tt class="py-line"> <tt class="py-keyword">def</tt> <tt class="py-def-name">link_repl</tt><tt class="py-op">(</tt><tt class="py-param">href</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L335"></a><tt class="py-lineno"> 335</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-151" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-151', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">href</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L336"></a><tt class="py-lineno"> 336</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L337"></a><tt class="py-lineno"> 337</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
-<a name="L338"></a><tt class="py-lineno"> 338</tt> <tt class="py-line"> <tt class="py-string">"unexpected value for handle_failures: %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">handle_failures</tt><tt class="py-op">)</tt> </tt>
-<a name="L339"></a><tt class="py-lineno"> 339</tt> <tt class="py-line"> </tt>
-<a name="L340"></a><tt class="py-lineno"> 340</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-152" class="py-name" targets="Method lxml.html.HtmlMixin.rewrite_links()=lxml.html.HtmlMixin-class.html#rewrite_links,Variable lxml.html.rewrite_links=lxml.html-module.html#rewrite_links"><a title="lxml.html.HtmlMixin.rewrite_links
-lxml.html.rewrite_links" class="py-name" href="#" onclick="return doclink('link-152', 'rewrite_links', 'link-152');">rewrite_links</a></tt><tt class="py-op">(</tt><tt class="py-name">link_repl</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L341"></a><tt class="py-lineno"> 341</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.resolve_base_href"></a><div id="HtmlMixin.resolve_base_href-def"><a name="L342"></a><tt class="py-lineno"> 342</tt> <a class="py-toggle" href="#" id="HtmlMixin.resolve_base_href-toggle" onclick="return toggle('HtmlMixin.resolve_base_href');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#resolve_base_href">resolve_base_href</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">handle_failures</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.resolve_base_href-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.resolve_base_href-expanded"><a name="L343"></a><tt class="py-lineno"> 343</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L344"></a><tt class="py-lineno"> 344</tt> <tt class="py-line"><tt class="py-docstring"> Find any ``<base href>`` tag in the document, and apply its</tt> </tt>
-<a name="L345"></a><tt class="py-lineno"> 345</tt> <tt class="py-line"><tt class="py-docstring"> values to all links found in the document. Also remove the</tt> </tt>
-<a name="L346"></a><tt class="py-lineno"> 346</tt> <tt class="py-line"><tt class="py-docstring"> tag once it has been applied.</tt> </tt>
-<a name="L347"></a><tt class="py-lineno"> 347</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L348"></a><tt class="py-lineno"> 348</tt> <tt class="py-line"><tt class="py-docstring"> If ``handle_failures`` is None (default), a failure to process</tt> </tt>
-<a name="L349"></a><tt class="py-lineno"> 349</tt> <tt class="py-line"><tt class="py-docstring"> a URL will abort the processing. If set to 'ignore', errors</tt> </tt>
-<a name="L350"></a><tt class="py-lineno"> 350</tt> <tt class="py-line"><tt class="py-docstring"> are ignored. If set to 'discard', failing URLs will be removed.</tt> </tt>
-<a name="L351"></a><tt class="py-lineno"> 351</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L352"></a><tt class="py-lineno"> 352</tt> <tt class="py-line"> <tt class="py-name">base_href</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-<a name="L353"></a><tt class="py-lineno"> 353</tt> <tt class="py-line"> <tt class="py-name">basetags</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-153" class="py-name"><a title="lxml.etree._Element.xpath
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-136', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'rel'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">rel</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L249"></a><tt class="py-lineno"> 249</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.find_class"></a><div id="HtmlMixin.find_class-def"><a name="L250"></a><tt class="py-lineno"> 250</tt> <a class="py-toggle" href="#" id="HtmlMixin.find_class-toggle" onclick="return toggle('HtmlMixin.find_class');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#find_class">find_class</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">class_name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.find_class-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.find_class-expanded"><a name="L251"></a><tt class="py-lineno"> 251</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L252"></a><tt class="py-lineno"> 252</tt> <tt class="py-line"><tt class="py-docstring"> Find any elements with the given class name.</tt> </tt>
+<a name="L253"></a><tt class="py-lineno"> 253</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L254"></a><tt class="py-lineno"> 254</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-137" class="py-name"><a title="lxml.html._class_xpath" class="py-name" href="#" onclick="return doclink('link-137', '_class_xpath', 'link-29');">_class_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-name">class_name</tt><tt class="py-op">=</tt><tt class="py-name">class_name</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L255"></a><tt class="py-lineno"> 255</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.get_element_by_id"></a><div id="HtmlMixin.get_element_by_id-def"><a name="L256"></a><tt class="py-lineno"> 256</tt> <a class="py-toggle" href="#" id="HtmlMixin.get_element_by_id-toggle" onclick="return toggle('HtmlMixin.get_element_by_id');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#get_element_by_id">get_element_by_id</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">id</tt><tt class="py-op">,</tt> <tt class="py-op">*</tt><tt class="py-param">default</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.get_element_by_id-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.get_element_by_id-expanded"><a name="L257"></a><tt class="py-lineno"> 257</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L258"></a><tt class="py-lineno"> 258</tt> <tt class="py-line"><tt class="py-docstring"> Get the first element in a document with the given id. If none is</tt> </tt>
+<a name="L259"></a><tt class="py-lineno"> 259</tt> <tt class="py-line"><tt class="py-docstring"> found, return the default argument if provided or raise KeyError</tt> </tt>
+<a name="L260"></a><tt class="py-lineno"> 260</tt> <tt class="py-line"><tt class="py-docstring"> otherwise.</tt> </tt>
+<a name="L261"></a><tt class="py-lineno"> 261</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L262"></a><tt class="py-lineno"> 262</tt> <tt class="py-line"><tt class="py-docstring"> Note that there can be more than one element with the same id,</tt> </tt>
+<a name="L263"></a><tt class="py-lineno"> 263</tt> <tt class="py-line"><tt class="py-docstring"> and this isn't uncommon in HTML documents found in the wild.</tt> </tt>
+<a name="L264"></a><tt class="py-lineno"> 264</tt> <tt class="py-line"><tt class="py-docstring"> Browsers return only the first match, and this function does</tt> </tt>
+<a name="L265"></a><tt class="py-lineno"> 265</tt> <tt class="py-line"><tt class="py-docstring"> the same.</tt> </tt>
+<a name="L266"></a><tt class="py-lineno"> 266</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L267"></a><tt class="py-lineno"> 267</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
+<a name="L268"></a><tt class="py-lineno"> 268</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: should this check for multiple matches?</tt> </tt>
+<a name="L269"></a><tt class="py-lineno"> 269</tt> <tt class="py-line"> <tt class="py-comment"># browsers just return the first one</tt> </tt>
+<a name="L270"></a><tt class="py-lineno"> 270</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-138" class="py-name"><a title="lxml.html._id_xpath" class="py-name" href="#" onclick="return doclink('link-138', '_id_xpath', 'link-32');">_id_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">=</tt><tt class="py-name">id</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L271"></a><tt class="py-lineno"> 271</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">IndexError</tt><tt class="py-op">:</tt> </tt>
+<a name="L272"></a><tt class="py-lineno"> 272</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">default</tt><tt class="py-op">:</tt> </tt>
+<a name="L273"></a><tt class="py-lineno"> 273</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">default</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L274"></a><tt class="py-lineno"> 274</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L275"></a><tt class="py-lineno"> 275</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt><tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L276"></a><tt class="py-lineno"> 276</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.text_content"></a><div id="HtmlMixin.text_content-def"><a name="L277"></a><tt class="py-lineno"> 277</tt> <a class="py-toggle" href="#" id="HtmlMixin.text_content-toggle" onclick="return toggle('HtmlMixin.text_content');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#text_content">text_content</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.text_content-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.text_content-expanded"><a name="L278"></a><tt class="py-lineno"> 278</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L279"></a><tt class="py-lineno"> 279</tt> <tt class="py-line"><tt class="py-docstring"> Return the text content of the tag (and the text in any children).</tt> </tt>
+<a name="L280"></a><tt class="py-lineno"> 280</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L281"></a><tt class="py-lineno"> 281</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-139" class="py-name"><a title="lxml.html._collect_string_content" class="py-name" href="#" onclick="return doclink('link-139', '_collect_string_content', 'link-35');">_collect_string_content</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L282"></a><tt class="py-lineno"> 282</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.cssselect"></a><div id="HtmlMixin.cssselect-def"><a name="L283"></a><tt class="py-lineno"> 283</tt> <a class="py-toggle" href="#" id="HtmlMixin.cssselect-toggle" onclick="return toggle('HtmlMixin.cssselect');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#cssselect">cssselect</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">expr</tt><tt class="py-op">,</tt> <tt class="py-param">translator</tt><tt class="py-op">=</tt><tt class="py-string">'html'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.cssselect-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.cssselect-expanded"><a name="L284"></a><tt class="py-lineno"> 284</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L285"></a><tt class="py-lineno"> 285</tt> <tt class="py-line"><tt class="py-docstring"> Run the CSS expression on this element and its children,</tt> </tt>
+<a name="L286"></a><tt class="py-lineno"> 286</tt> <tt class="py-line"><tt class="py-docstring"> returning a list of the results.</tt> </tt>
+<a name="L287"></a><tt class="py-lineno"> 287</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L288"></a><tt class="py-lineno"> 288</tt> <tt class="py-line"><tt class="py-docstring"> Equivalent to lxml.cssselect.CSSSelect(expr, translator='html')(self)</tt> </tt>
+<a name="L289"></a><tt class="py-lineno"> 289</tt> <tt class="py-line"><tt class="py-docstring"> -- note that pre-compiling the expression can provide a substantial</tt> </tt>
+<a name="L290"></a><tt class="py-lineno"> 290</tt> <tt class="py-line"><tt class="py-docstring"> speedup.</tt> </tt>
+<a name="L291"></a><tt class="py-lineno"> 291</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L292"></a><tt class="py-lineno"> 292</tt> <tt class="py-line"> <tt class="py-comment"># Do the import here to make the dependency optional.</tt> </tt>
+<a name="L293"></a><tt class="py-lineno"> 293</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt id="link-140" class="py-name"><a title="lxml" class="py-name" href="#" onclick="return doclink('link-140', 'lxml', 'link-2');">lxml</a></tt><tt class="py-op">.</tt><tt id="link-141" class="py-name" targets="Module lxml.cssselect=lxml.cssselect-module.html,Method lxml.html.HtmlMixin.cssselect()=lxml.html.HtmlMixin-class.html#cssselect"><a title="lxml.cssselect
+lxml.html.HtmlMixin.cssselect" class="py-name" href="#" onclick="return doclink('link-141', 'cssselect', 'link-141');">cssselect</a></tt> <tt class="py-keyword">import</tt> <tt id="link-142" class="py-name" targets="Class lxml.cssselect.CSSSelector=lxml.cssselect.CSSSelector-class.html"><a title="lxml.cssselect.CSSSelector" class="py-name" href="#" onclick="return doclink('link-142', 'CSSSelector', 'link-142');">CSSSelector</a></tt> </tt>
+<a name="L294"></a><tt class="py-lineno"> 294</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-143" class="py-name"><a title="lxml.cssselect.CSSSelector" class="py-name" href="#" onclick="return doclink('link-143', 'CSSSelector', 'link-142');">CSSSelector</a></tt><tt class="py-op">(</tt><tt class="py-name">expr</tt><tt class="py-op">,</tt> <tt class="py-name">translator</tt><tt class="py-op">=</tt><tt class="py-name">translator</tt><tt class="py-op">)</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L295"></a><tt class="py-lineno"> 295</tt> <tt class="py-line"> </tt>
+<a name="L296"></a><tt class="py-lineno"> 296</tt> <tt class="py-line"> <tt class="py-comment">########################################</tt> </tt>
+<a name="L297"></a><tt class="py-lineno"> 297</tt> <tt class="py-line"> <tt class="py-comment">## Link functions</tt> </tt>
+<a name="L298"></a><tt class="py-lineno"> 298</tt> <tt class="py-line"> <tt class="py-comment">########################################</tt> </tt>
+<a name="L299"></a><tt class="py-lineno"> 299</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.make_links_absolute"></a><div id="HtmlMixin.make_links_absolute-def"><a name="L300"></a><tt class="py-lineno"> 300</tt> <a class="py-toggle" href="#" id="HtmlMixin.make_links_absolute-toggle" onclick="return toggle('HtmlMixin.make_links_absolute');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#make_links_absolute">make_links_absolute</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">resolve_base_href</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> </tt>
+<a name="L301"></a><tt class="py-lineno"> 301</tt> <tt class="py-line"> <tt class="py-param">handle_failures</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.make_links_absolute-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.make_links_absolute-expanded"><a name="L302"></a><tt class="py-lineno"> 302</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L303"></a><tt class="py-lineno"> 303</tt> <tt class="py-line"><tt class="py-docstring"> Make all links in the document absolute, given the</tt> </tt>
+<a name="L304"></a><tt class="py-lineno"> 304</tt> <tt class="py-line"><tt class="py-docstring"> ``base_url`` for the document (the full URL where the document</tt> </tt>
+<a name="L305"></a><tt class="py-lineno"> 305</tt> <tt class="py-line"><tt class="py-docstring"> came from), or if no ``base_url`` is given, then the ``.base_url``</tt> </tt>
+<a name="L306"></a><tt class="py-lineno"> 306</tt> <tt class="py-line"><tt class="py-docstring"> of the document.</tt> </tt>
+<a name="L307"></a><tt class="py-lineno"> 307</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L308"></a><tt class="py-lineno"> 308</tt> <tt class="py-line"><tt class="py-docstring"> If ``resolve_base_href`` is true, then any ``<base href>``</tt> </tt>
+<a name="L309"></a><tt class="py-lineno"> 309</tt> <tt class="py-line"><tt class="py-docstring"> tags in the document are used *and* removed from the document.</tt> </tt>
+<a name="L310"></a><tt class="py-lineno"> 310</tt> <tt class="py-line"><tt class="py-docstring"> If it is false then any such tag is ignored.</tt> </tt>
+<a name="L311"></a><tt class="py-lineno"> 311</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L312"></a><tt class="py-lineno"> 312</tt> <tt class="py-line"><tt class="py-docstring"> If ``handle_failures`` is None (default), a failure to process</tt> </tt>
+<a name="L313"></a><tt class="py-lineno"> 313</tt> <tt class="py-line"><tt class="py-docstring"> a URL will abort the processing. If set to 'ignore', errors</tt> </tt>
+<a name="L314"></a><tt class="py-lineno"> 314</tt> <tt class="py-line"><tt class="py-docstring"> are ignored. If set to 'discard', failing URLs will be removed.</tt> </tt>
+<a name="L315"></a><tt class="py-lineno"> 315</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L316"></a><tt class="py-lineno"> 316</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-144" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-144', 'base_url', 'link-60');">base_url</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L317"></a><tt class="py-lineno"> 317</tt> <tt class="py-line"> <tt id="link-145" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-145', 'base_url', 'link-60');">base_url</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-146" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-146', 'base_url', 'link-60');">base_url</a></tt> </tt>
+<a name="L318"></a><tt class="py-lineno"> 318</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-147" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-147', 'base_url', 'link-60');">base_url</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L319"></a><tt class="py-lineno"> 319</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
+<a name="L320"></a><tt class="py-lineno"> 320</tt> <tt class="py-line"> <tt class="py-string">"No base_url given, and the document has no base_url"</tt><tt class="py-op">)</tt> </tt>
+<a name="L321"></a><tt class="py-lineno"> 321</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-148" class="py-name" targets="Method lxml.html.HtmlMixin.resolve_base_href()=lxml.html.HtmlMixin-class.html#resolve_base_href,Variable lxml.html.resolve_base_href=lxml.html-module.html#resolve_base_href"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-148', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L322"></a><tt class="py-lineno"> 322</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-149" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-149', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L323"></a><tt class="py-lineno"> 323</tt> <tt class="py-line"> </tt>
+<a name="L324"></a><tt class="py-lineno"> 324</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">handle_failures</tt> <tt class="py-op">==</tt> <tt class="py-string">'ignore'</tt><tt class="py-op">:</tt> </tt>
+<a name="L325"></a><tt class="py-lineno"> 325</tt> <tt class="py-line"> <tt class="py-keyword">def</tt> <tt class="py-def-name">link_repl</tt><tt class="py-op">(</tt><tt class="py-param">href</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L326"></a><tt class="py-lineno"> 326</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
+<a name="L327"></a><tt class="py-lineno"> 327</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-150" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-150', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">href</tt><tt class="py-op">)</tt> </tt>
+<a name="L328"></a><tt class="py-lineno"> 328</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">ValueError</tt><tt class="py-op">:</tt> </tt>
+<a name="L329"></a><tt class="py-lineno"> 329</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">href</tt> </tt>
+</div><a name="L330"></a><tt class="py-lineno"> 330</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">handle_failures</tt> <tt class="py-op">==</tt> <tt class="py-string">'discard'</tt><tt class="py-op">:</tt> </tt>
+<a name="L331"></a><tt class="py-lineno"> 331</tt> <tt class="py-line"> <tt class="py-keyword">def</tt> <tt class="py-def-name">link_repl</tt><tt class="py-op">(</tt><tt class="py-param">href</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L332"></a><tt class="py-lineno"> 332</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
+<a name="L333"></a><tt class="py-lineno"> 333</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-151" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-151', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">href</tt><tt class="py-op">)</tt> </tt>
+<a name="L334"></a><tt class="py-lineno"> 334</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">ValueError</tt><tt class="py-op">:</tt> </tt>
+<a name="L335"></a><tt class="py-lineno"> 335</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
+</div><a name="L336"></a><tt class="py-lineno"> 336</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">handle_failures</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L337"></a><tt class="py-lineno"> 337</tt> <tt class="py-line"> <tt class="py-keyword">def</tt> <tt class="py-def-name">link_repl</tt><tt class="py-op">(</tt><tt class="py-param">href</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L338"></a><tt class="py-lineno"> 338</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-152" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-152', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-name">href</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L339"></a><tt class="py-lineno"> 339</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L340"></a><tt class="py-lineno"> 340</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
+<a name="L341"></a><tt class="py-lineno"> 341</tt> <tt class="py-line"> <tt class="py-string">"unexpected value for handle_failures: %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">handle_failures</tt><tt class="py-op">)</tt> </tt>
+<a name="L342"></a><tt class="py-lineno"> 342</tt> <tt class="py-line"> </tt>
+<a name="L343"></a><tt class="py-lineno"> 343</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-153" class="py-name" targets="Method lxml.html.HtmlMixin.rewrite_links()=lxml.html.HtmlMixin-class.html#rewrite_links,Variable lxml.html.rewrite_links=lxml.html-module.html#rewrite_links"><a title="lxml.html.HtmlMixin.rewrite_links
+lxml.html.rewrite_links" class="py-name" href="#" onclick="return doclink('link-153', 'rewrite_links', 'link-153');">rewrite_links</a></tt><tt class="py-op">(</tt><tt class="py-name">link_repl</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L344"></a><tt class="py-lineno"> 344</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.resolve_base_href"></a><div id="HtmlMixin.resolve_base_href-def"><a name="L345"></a><tt class="py-lineno"> 345</tt> <a class="py-toggle" href="#" id="HtmlMixin.resolve_base_href-toggle" onclick="return toggle('HtmlMixin.resolve_base_href');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#resolve_base_href">resolve_base_href</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">handle_failures</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.resolve_base_href-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.resolve_base_href-expanded"><a name="L346"></a><tt class="py-lineno"> 346</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L347"></a><tt class="py-lineno"> 347</tt> <tt class="py-line"><tt class="py-docstring"> Find any ``<base href>`` tag in the document, and apply its</tt> </tt>
+<a name="L348"></a><tt class="py-lineno"> 348</tt> <tt class="py-line"><tt class="py-docstring"> values to all links found in the document. Also remove the</tt> </tt>
+<a name="L349"></a><tt class="py-lineno"> 349</tt> <tt class="py-line"><tt class="py-docstring"> tag once it has been applied.</tt> </tt>
+<a name="L350"></a><tt class="py-lineno"> 350</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L351"></a><tt class="py-lineno"> 351</tt> <tt class="py-line"><tt class="py-docstring"> If ``handle_failures`` is None (default), a failure to process</tt> </tt>
+<a name="L352"></a><tt class="py-lineno"> 352</tt> <tt class="py-line"><tt class="py-docstring"> a URL will abort the processing. If set to 'ignore', errors</tt> </tt>
+<a name="L353"></a><tt class="py-lineno"> 353</tt> <tt class="py-line"><tt class="py-docstring"> are ignored. If set to 'discard', failing URLs will be removed.</tt> </tt>
+<a name="L354"></a><tt class="py-lineno"> 354</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L355"></a><tt class="py-lineno"> 355</tt> <tt class="py-line"> <tt class="py-name">base_href</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+<a name="L356"></a><tt class="py-lineno"> 356</tt> <tt class="py-line"> <tt class="py-name">basetags</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-154" class="py-name"><a title="lxml.etree._Element.xpath
lxml.etree._ElementTree.xpath
-lxml.tests.test_xpathevaluator.xpath" class="py-name" href="#" onclick="return doclink('link-153', 'xpath', 'link-68');">xpath</a></tt><tt class="py-op">(</tt><tt class="py-string">'//base[@href]|//x:base[@href]'</tt><tt class="py-op">,</tt> </tt>
-<a name="L354"></a><tt class="py-lineno"> 354</tt> <tt class="py-line"> <tt class="py-name">namespaces</tt><tt class="py-op">=</tt><tt class="py-op">{</tt><tt class="py-string">'x'</tt><tt class="py-op">:</tt> <tt id="link-154" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-154', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">}</tt><tt class="py-op">)</tt> </tt>
-<a name="L355"></a><tt class="py-lineno"> 355</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">b</tt> <tt class="py-keyword">in</tt> <tt class="py-name">basetags</tt><tt class="py-op">:</tt> </tt>
-<a name="L356"></a><tt class="py-lineno"> 356</tt> <tt class="py-line"> <tt class="py-name">base_href</tt> <tt class="py-op">=</tt> <tt class="py-name">b</tt><tt class="py-op">.</tt><tt id="link-155" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.tests.test_xpathevaluator.xpath" class="py-name" href="#" onclick="return doclink('link-154', 'xpath', 'link-69');">xpath</a></tt><tt class="py-op">(</tt><tt class="py-string">'//base[@href]|//x:base[@href]'</tt><tt class="py-op">,</tt> </tt>
+<a name="L357"></a><tt class="py-lineno"> 357</tt> <tt class="py-line"> <tt class="py-name">namespaces</tt><tt class="py-op">=</tt><tt class="py-op">{</tt><tt class="py-string">'x'</tt><tt class="py-op">:</tt> <tt id="link-155" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-155', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">}</tt><tt class="py-op">)</tt> </tt>
+<a name="L358"></a><tt class="py-lineno"> 358</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">b</tt> <tt class="py-keyword">in</tt> <tt class="py-name">basetags</tt><tt class="py-op">:</tt> </tt>
+<a name="L359"></a><tt class="py-lineno"> 359</tt> <tt class="py-line"> <tt class="py-name">base_href</tt> <tt class="py-op">=</tt> <tt class="py-name">b</tt><tt class="py-op">.</tt><tt id="link-156" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-155', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'href'</tt><tt class="py-op">)</tt> </tt>
-<a name="L357"></a><tt class="py-lineno"> 357</tt> <tt class="py-line"> <tt class="py-name">b</tt><tt class="py-op">.</tt><tt id="link-156" class="py-name" targets="Method lxml.html.HtmlMixin.drop_tree()=lxml.html.HtmlMixin-class.html#drop_tree"><a title="lxml.html.HtmlMixin.drop_tree" class="py-name" href="#" onclick="return doclink('link-156', 'drop_tree', 'link-156');">drop_tree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L358"></a><tt class="py-lineno"> 358</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">base_href</tt><tt class="py-op">:</tt> </tt>
-<a name="L359"></a><tt class="py-lineno"> 359</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> </tt>
-<a name="L360"></a><tt class="py-lineno"> 360</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-157" class="py-name" targets="Method lxml.html.HtmlMixin.make_links_absolute()=lxml.html.HtmlMixin-class.html#make_links_absolute,Variable lxml.html.make_links_absolute=lxml.html-module.html#make_links_absolute"><a title="lxml.html.HtmlMixin.make_links_absolute
-lxml.html.make_links_absolute" class="py-name" href="#" onclick="return doclink('link-157', 'make_links_absolute', 'link-157');">make_links_absolute</a></tt><tt class="py-op">(</tt><tt class="py-name">base_href</tt><tt class="py-op">,</tt> <tt id="link-158" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-158', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> </tt>
-<a name="L361"></a><tt class="py-lineno"> 361</tt> <tt class="py-line"> <tt class="py-name">handle_failures</tt><tt class="py-op">=</tt><tt class="py-name">handle_failures</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L362"></a><tt class="py-lineno"> 362</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.iterlinks"></a><div id="HtmlMixin.iterlinks-def"><a name="L363"></a><tt class="py-lineno"> 363</tt> <a class="py-toggle" href="#" id="HtmlMixin.iterlinks-toggle" onclick="return toggle('HtmlMixin.iterlinks');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#iterlinks">iterlinks</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.iterlinks-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.iterlinks-expanded"><a name="L364"></a><tt class="py-lineno"> 364</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L365"></a><tt class="py-lineno"> 365</tt> <tt class="py-line"><tt class="py-docstring"> Yield (element, attribute, link, pos), where attribute may be None</tt> </tt>
-<a name="L366"></a><tt class="py-lineno"> 366</tt> <tt class="py-line"><tt class="py-docstring"> (indicating the link is in the text). ``pos`` is the position</tt> </tt>
-<a name="L367"></a><tt class="py-lineno"> 367</tt> <tt class="py-line"><tt class="py-docstring"> where the link occurs; often 0, but sometimes something else in</tt> </tt>
-<a name="L368"></a><tt class="py-lineno"> 368</tt> <tt class="py-line"><tt class="py-docstring"> the case of links in stylesheets or style tags.</tt> </tt>
-<a name="L369"></a><tt class="py-lineno"> 369</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L370"></a><tt class="py-lineno"> 370</tt> <tt class="py-line"><tt class="py-docstring"> Note: <base href> is *not* taken into account in any way. The</tt> </tt>
-<a name="L371"></a><tt class="py-lineno"> 371</tt> <tt class="py-line"><tt class="py-docstring"> link you get is exactly the link in the document.</tt> </tt>
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-156', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'href'</tt><tt class="py-op">)</tt> </tt>
+<a name="L360"></a><tt class="py-lineno"> 360</tt> <tt class="py-line"> <tt class="py-name">b</tt><tt class="py-op">.</tt><tt id="link-157" class="py-name" targets="Method lxml.html.HtmlMixin.drop_tree()=lxml.html.HtmlMixin-class.html#drop_tree"><a title="lxml.html.HtmlMixin.drop_tree" class="py-name" href="#" onclick="return doclink('link-157', 'drop_tree', 'link-157');">drop_tree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L361"></a><tt class="py-lineno"> 361</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">base_href</tt><tt class="py-op">:</tt> </tt>
+<a name="L362"></a><tt class="py-lineno"> 362</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> </tt>
+<a name="L363"></a><tt class="py-lineno"> 363</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-158" class="py-name" targets="Method lxml.html.HtmlMixin.make_links_absolute()=lxml.html.HtmlMixin-class.html#make_links_absolute,Variable lxml.html.make_links_absolute=lxml.html-module.html#make_links_absolute"><a title="lxml.html.HtmlMixin.make_links_absolute
+lxml.html.make_links_absolute" class="py-name" href="#" onclick="return doclink('link-158', 'make_links_absolute', 'link-158');">make_links_absolute</a></tt><tt class="py-op">(</tt><tt class="py-name">base_href</tt><tt class="py-op">,</tt> <tt id="link-159" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-159', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> </tt>
+<a name="L364"></a><tt class="py-lineno"> 364</tt> <tt class="py-line"> <tt class="py-name">handle_failures</tt><tt class="py-op">=</tt><tt class="py-name">handle_failures</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L365"></a><tt class="py-lineno"> 365</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.iterlinks"></a><div id="HtmlMixin.iterlinks-def"><a name="L366"></a><tt class="py-lineno"> 366</tt> <a class="py-toggle" href="#" id="HtmlMixin.iterlinks-toggle" onclick="return toggle('HtmlMixin.iterlinks');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#iterlinks">iterlinks</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.iterlinks-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.iterlinks-expanded"><a name="L367"></a><tt class="py-lineno"> 367</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L368"></a><tt class="py-lineno"> 368</tt> <tt class="py-line"><tt class="py-docstring"> Yield (element, attribute, link, pos), where attribute may be None</tt> </tt>
+<a name="L369"></a><tt class="py-lineno"> 369</tt> <tt class="py-line"><tt class="py-docstring"> (indicating the link is in the text). ``pos`` is the position</tt> </tt>
+<a name="L370"></a><tt class="py-lineno"> 370</tt> <tt class="py-line"><tt class="py-docstring"> where the link occurs; often 0, but sometimes something else in</tt> </tt>
+<a name="L371"></a><tt class="py-lineno"> 371</tt> <tt class="py-line"><tt class="py-docstring"> the case of links in stylesheets or style tags.</tt> </tt>
<a name="L372"></a><tt class="py-lineno"> 372</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L373"></a><tt class="py-lineno"> 373</tt> <tt class="py-line"><tt class="py-docstring"> Note: multiple links inside of a single text string or</tt> </tt>
-<a name="L374"></a><tt class="py-lineno"> 374</tt> <tt class="py-line"><tt class="py-docstring"> attribute value are returned in reversed order. This makes it</tt> </tt>
-<a name="L375"></a><tt class="py-lineno"> 375</tt> <tt class="py-line"><tt class="py-docstring"> possible to replace or delete them from the text string value</tt> </tt>
-<a name="L376"></a><tt class="py-lineno"> 376</tt> <tt class="py-line"><tt class="py-docstring"> based on their reported text positions. Otherwise, a</tt> </tt>
-<a name="L377"></a><tt class="py-lineno"> 377</tt> <tt class="py-line"><tt class="py-docstring"> modification at one text position can change the positions of</tt> </tt>
-<a name="L378"></a><tt class="py-lineno"> 378</tt> <tt class="py-line"><tt class="py-docstring"> links reported later on.</tt> </tt>
-<a name="L379"></a><tt class="py-lineno"> 379</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L380"></a><tt class="py-lineno"> 380</tt> <tt class="py-line"> <tt id="link-159" class="py-name" targets="Variable lxml.html.defs.link_attrs=lxml.html.defs-module.html#link_attrs"><a title="lxml.html.defs.link_attrs" class="py-name" href="#" onclick="return doclink('link-159', 'link_attrs', 'link-159');">link_attrs</a></tt> <tt class="py-op">=</tt> <tt id="link-160" class="py-name"><a title="lxml.html.defs" class="py-name" href="#" onclick="return doclink('link-160', 'defs', 'link-6');">defs</a></tt><tt class="py-op">.</tt><tt id="link-161" class="py-name"><a title="lxml.html.defs.link_attrs" class="py-name" href="#" onclick="return doclink('link-161', 'link_attrs', 'link-159');">link_attrs</a></tt> </tt>
-<a name="L381"></a><tt class="py-lineno"> 381</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-162" class="py-name" targets="Method lxml.etree._Element.iter()=lxml.etree._Element-class.html#iter,Method lxml.etree._ElementTree.iter()=lxml.etree._ElementTree-class.html#iter"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-162', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt id="link-163" class="py-name"><a title="lxml.etree
+<a name="L373"></a><tt class="py-lineno"> 373</tt> <tt class="py-line"><tt class="py-docstring"> Note: <base href> is *not* taken into account in any way. The</tt> </tt>
+<a name="L374"></a><tt class="py-lineno"> 374</tt> <tt class="py-line"><tt class="py-docstring"> link you get is exactly the link in the document.</tt> </tt>
+<a name="L375"></a><tt class="py-lineno"> 375</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L376"></a><tt class="py-lineno"> 376</tt> <tt class="py-line"><tt class="py-docstring"> Note: multiple links inside of a single text string or</tt> </tt>
+<a name="L377"></a><tt class="py-lineno"> 377</tt> <tt class="py-line"><tt class="py-docstring"> attribute value are returned in reversed order. This makes it</tt> </tt>
+<a name="L378"></a><tt class="py-lineno"> 378</tt> <tt class="py-line"><tt class="py-docstring"> possible to replace or delete them from the text string value</tt> </tt>
+<a name="L379"></a><tt class="py-lineno"> 379</tt> <tt class="py-line"><tt class="py-docstring"> based on their reported text positions. Otherwise, a</tt> </tt>
+<a name="L380"></a><tt class="py-lineno"> 380</tt> <tt class="py-line"><tt class="py-docstring"> modification at one text position can change the positions of</tt> </tt>
+<a name="L381"></a><tt class="py-lineno"> 381</tt> <tt class="py-line"><tt class="py-docstring"> links reported later on.</tt> </tt>
+<a name="L382"></a><tt class="py-lineno"> 382</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L383"></a><tt class="py-lineno"> 383</tt> <tt class="py-line"> <tt id="link-160" class="py-name" targets="Variable lxml.html.defs.link_attrs=lxml.html.defs-module.html#link_attrs"><a title="lxml.html.defs.link_attrs" class="py-name" href="#" onclick="return doclink('link-160', 'link_attrs', 'link-160');">link_attrs</a></tt> <tt class="py-op">=</tt> <tt id="link-161" class="py-name"><a title="lxml.html.defs" class="py-name" href="#" onclick="return doclink('link-161', 'defs', 'link-6');">defs</a></tt><tt class="py-op">.</tt><tt id="link-162" class="py-name"><a title="lxml.html.defs.link_attrs" class="py-name" href="#" onclick="return doclink('link-162', 'link_attrs', 'link-160');">link_attrs</a></tt> </tt>
+<a name="L384"></a><tt class="py-lineno"> 384</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-163" class="py-name" targets="Method lxml.etree._Element.iter()=lxml.etree._Element-class.html#iter,Method lxml.etree._ElementTree.iter()=lxml.etree._ElementTree-class.html#iter"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-163', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt id="link-164" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-163', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-164" class="py-name" targets="Function lxml.etree.Element()=lxml.etree-module.html#Element,Function lxml.objectify.Element()=lxml.objectify-module.html#Element,Method lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element()=lxml.tests.test_pyclasslookup.PyClassLookupTestCase-class.html#Element,Class xml.etree.ElementTree.Element=xml.etree.ElementTree.Element-class.html"><a title="lxml.etree.Element
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-164', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-165" class="py-name" targets="Function lxml.etree.Element()=lxml.etree-module.html#Element,Function lxml.objectify.Element()=lxml.objectify-module.html#Element,Method lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element()=lxml.tests.test_pyclasslookup.PyClassLookupTestCase-class.html#Element,Class xml.etree.ElementTree.Element=xml.etree.ElementTree.Element-class.html"><a title="lxml.etree.Element
lxml.objectify.Element
lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element
-xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-164', 'Element', 'link-164');">Element</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L382"></a><tt class="py-lineno"> 382</tt> <tt class="py-line"> <tt class="py-name">attribs</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-165" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-165', 'Element', 'link-165');">Element</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L385"></a><tt class="py-lineno"> 385</tt> <tt class="py-line"> <tt class="py-name">attribs</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-166" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-165', 'attrib', 'link-92');">attrib</a></tt> </tt>
-<a name="L383"></a><tt class="py-lineno"> 383</tt> <tt class="py-line"> <tt id="link-166" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-166', 'attrib', 'link-93');">attrib</a></tt> </tt>
+<a name="L386"></a><tt class="py-lineno"> 386</tt> <tt class="py-line"> <tt id="link-167" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-166', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-167" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-167', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-168" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-167', 'tag', 'link-48');">tag</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L384"></a><tt class="py-lineno"> 384</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-168" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-168', 'tag', 'link-49');">tag</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L387"></a><tt class="py-lineno"> 387</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-169" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-168', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'object'</tt><tt class="py-op">:</tt> </tt>
-<a name="L385"></a><tt class="py-lineno"> 385</tt> <tt class="py-line"> <tt class="py-name">codebase</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-<a name="L386"></a><tt class="py-lineno"> 386</tt> <tt class="py-line"> <tt class="py-comment">## <object> tags have attributes that are relative to</tt> </tt>
-<a name="L387"></a><tt class="py-lineno"> 387</tt> <tt class="py-line"> <tt class="py-comment">## codebase</tt> </tt>
-<a name="L388"></a><tt class="py-lineno"> 388</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'codebase'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
-<a name="L389"></a><tt class="py-lineno"> 389</tt> <tt class="py-line"> <tt class="py-name">codebase</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-169" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-169', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'object'</tt><tt class="py-op">:</tt> </tt>
+<a name="L388"></a><tt class="py-lineno"> 388</tt> <tt class="py-line"> <tt class="py-name">codebase</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+<a name="L389"></a><tt class="py-lineno"> 389</tt> <tt class="py-line"> <tt class="py-comment">## <object> tags have attributes that are relative to</tt> </tt>
+<a name="L390"></a><tt class="py-lineno"> 390</tt> <tt class="py-line"> <tt class="py-comment">## codebase</tt> </tt>
+<a name="L391"></a><tt class="py-lineno"> 391</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'codebase'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
+<a name="L392"></a><tt class="py-lineno"> 392</tt> <tt class="py-line"> <tt class="py-name">codebase</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-170" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-169', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'codebase'</tt><tt class="py-op">)</tt> </tt>
-<a name="L390"></a><tt class="py-lineno"> 390</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'codebase'</tt><tt class="py-op">,</tt> <tt class="py-name">codebase</tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
-<a name="L391"></a><tt class="py-lineno"> 391</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-170" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-170', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'codebase'</tt><tt class="py-op">)</tt> </tt>
+<a name="L393"></a><tt class="py-lineno"> 393</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'codebase'</tt><tt class="py-op">,</tt> <tt class="py-name">codebase</tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
+<a name="L394"></a><tt class="py-lineno"> 394</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-171" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-170', 'attrib', 'link-92');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt class="py-op">(</tt><tt class="py-string">'classid'</tt><tt class="py-op">,</tt> <tt class="py-string">'data'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L392"></a><tt class="py-lineno"> 392</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-171" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-171', 'attrib', 'link-93');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt class="py-op">(</tt><tt class="py-string">'classid'</tt><tt class="py-op">,</tt> <tt class="py-string">'data'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L395"></a><tt class="py-lineno"> 395</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-172" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-171', 'attrib', 'link-92');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
-<a name="L393"></a><tt class="py-lineno"> 393</tt> <tt class="py-line"> <tt id="link-172" class="py-name" targets="Variable lxml.html.CheckboxGroup.value=lxml.html.CheckboxGroup-class.html#value,Variable lxml.html.InputElement.value=lxml.html.InputElement-class.html#value,Variable lxml.html.RadioGroup.value=lxml.html.RadioGroup-class.html#value,Variable lxml.html.SelectElement.value=lxml.html.SelectElement-class.html#value,Variable lxml.html.TextareaElement.value=lxml.html.TextareaElement-class.html#value"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-172', 'attrib', 'link-93');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
+<a name="L396"></a><tt class="py-lineno"> 396</tt> <tt class="py-line"> <tt id="link-173" class="py-name" targets="Variable lxml.html.CheckboxGroup.value=lxml.html.CheckboxGroup-class.html#value,Variable lxml.html.InputElement.value=lxml.html.InputElement-class.html#value,Variable lxml.html.RadioGroup.value=lxml.html.RadioGroup-class.html#value,Variable lxml.html.SelectElement.value=lxml.html.SelectElement-class.html#value,Variable lxml.html.TextareaElement.value=lxml.html.TextareaElement-class.html#value"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-172', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-173" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-173', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-174" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-173', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt id="link-174" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-174', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt id="link-175" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-174', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L394"></a><tt class="py-lineno"> 394</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">codebase</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L395"></a><tt class="py-lineno"> 395</tt> <tt class="py-line"> <tt id="link-175" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-175', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L397"></a><tt class="py-lineno"> 397</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">codebase</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L398"></a><tt class="py-lineno"> 398</tt> <tt class="py-line"> <tt id="link-176" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-175', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt class="py-name">codebase</tt><tt class="py-op">,</tt> <tt id="link-176" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-176', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt class="py-name">codebase</tt><tt class="py-op">,</tt> <tt id="link-177" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-176', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L396"></a><tt class="py-lineno"> 396</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-177" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-177', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L399"></a><tt class="py-lineno"> 399</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-178" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-177', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">,</tt> <tt id="link-178" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-178', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">,</tt> <tt id="link-179" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-178', 'value', 'link-172');">value</a></tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
-<a name="L397"></a><tt class="py-lineno"> 397</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'archive'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
-<a name="L398"></a><tt class="py-lineno"> 398</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt id="link-179" class="py-name"><a title="lxml.html._archive_re" class="py-name" href="#" onclick="return doclink('link-179', '_archive_re', 'link-43');">_archive_re</a></tt><tt class="py-op">.</tt><tt class="py-name">finditer</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-180" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-179', 'value', 'link-173');">value</a></tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
+<a name="L400"></a><tt class="py-lineno"> 400</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'archive'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
+<a name="L401"></a><tt class="py-lineno"> 401</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt id="link-180" class="py-name"><a title="lxml.html._archive_re" class="py-name" href="#" onclick="return doclink('link-180', '_archive_re', 'link-43');">_archive_re</a></tt><tt class="py-op">.</tt><tt class="py-name">finditer</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-181" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-180', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'archive'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L399"></a><tt class="py-lineno"> 399</tt> <tt class="py-line"> <tt id="link-181" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-181', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'archive'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L402"></a><tt class="py-lineno"> 402</tt> <tt class="py-line"> <tt id="link-182" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-181', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
-<a name="L400"></a><tt class="py-lineno"> 400</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">codebase</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L401"></a><tt class="py-lineno"> 401</tt> <tt class="py-line"> <tt id="link-182" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-182', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
+<a name="L403"></a><tt class="py-lineno"> 403</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">codebase</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L404"></a><tt class="py-lineno"> 404</tt> <tt class="py-line"> <tt id="link-183" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-182', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt class="py-name">codebase</tt><tt class="py-op">,</tt> <tt id="link-183" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-183', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt class="py-name">codebase</tt><tt class="py-op">,</tt> <tt id="link-184" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-183', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L402"></a><tt class="py-lineno"> 402</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'archive'</tt><tt class="py-op">,</tt> <tt id="link-184" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-184', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L405"></a><tt class="py-lineno"> 405</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'archive'</tt><tt class="py-op">,</tt> <tt id="link-185" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-184', 'value', 'link-172');">value</a></tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-185" class="py-name" targets="Method lxml.etree.TreeBuilder.start()=lxml.etree.TreeBuilder-class.html#start"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-185', 'start', 'link-185');">start</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L403"></a><tt class="py-lineno"> 403</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L404"></a><tt class="py-lineno"> 404</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-186" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-185', 'value', 'link-173');">value</a></tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-186" class="py-name" targets="Method lxml.etree.TreeBuilder.start()=lxml.etree.TreeBuilder-class.html#start"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-186', 'start', 'link-186');">start</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L406"></a><tt class="py-lineno"> 406</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L407"></a><tt class="py-lineno"> 407</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-187" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-186', 'attrib', 'link-92');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt id="link-187" class="py-name"><a title="lxml.html.defs.link_attrs" class="py-name" href="#" onclick="return doclink('link-187', 'link_attrs', 'link-159');">link_attrs</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L405"></a><tt class="py-lineno"> 405</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-188" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-187', 'attrib', 'link-93');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt id="link-188" class="py-name"><a title="lxml.html.defs.link_attrs" class="py-name" href="#" onclick="return doclink('link-188', 'link_attrs', 'link-160');">link_attrs</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L408"></a><tt class="py-lineno"> 408</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-189" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-188', 'attrib', 'link-92');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
-<a name="L406"></a><tt class="py-lineno"> 406</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-189" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-189', 'attrib', 'link-93');">attrib</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
+<a name="L409"></a><tt class="py-lineno"> 409</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-190" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-189', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">,</tt> <tt class="py-name">attribs</tt><tt class="py-op">[</tt><tt id="link-190" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-190', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">,</tt> <tt class="py-name">attribs</tt><tt class="py-op">[</tt><tt id="link-191" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-190', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">]</tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
-<a name="L407"></a><tt class="py-lineno"> 407</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-191" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-191', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">]</tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
+<a name="L410"></a><tt class="py-lineno"> 410</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-192" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-191', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'meta'</tt><tt class="py-op">:</tt> </tt>
-<a name="L408"></a><tt class="py-lineno"> 408</tt> <tt class="py-line"> <tt class="py-name">http_equiv</tt> <tt class="py-op">=</tt> <tt class="py-name">attribs</tt><tt class="py-op">.</tt><tt id="link-192" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-192', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'meta'</tt><tt class="py-op">:</tt> </tt>
+<a name="L411"></a><tt class="py-lineno"> 411</tt> <tt class="py-line"> <tt class="py-name">http_equiv</tt> <tt class="py-op">=</tt> <tt class="py-name">attribs</tt><tt class="py-op">.</tt><tt id="link-193" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-192', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'http-equiv'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L409"></a><tt class="py-lineno"> 409</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">http_equiv</tt> <tt class="py-op">==</tt> <tt class="py-string">'refresh'</tt><tt class="py-op">:</tt> </tt>
-<a name="L410"></a><tt class="py-lineno"> 410</tt> <tt class="py-line"> <tt class="py-name">content</tt> <tt class="py-op">=</tt> <tt class="py-name">attribs</tt><tt class="py-op">.</tt><tt id="link-193" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-193', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'http-equiv'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L412"></a><tt class="py-lineno"> 412</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">http_equiv</tt> <tt class="py-op">==</tt> <tt class="py-string">'refresh'</tt><tt class="py-op">:</tt> </tt>
+<a name="L413"></a><tt class="py-lineno"> 413</tt> <tt class="py-line"> <tt class="py-name">content</tt> <tt class="py-op">=</tt> <tt class="py-name">attribs</tt><tt class="py-op">.</tt><tt id="link-194" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-193', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'content'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
-<a name="L411"></a><tt class="py-lineno"> 411</tt> <tt class="py-line"> <tt class="py-name">i</tt> <tt class="py-op">=</tt> <tt class="py-name">content</tt><tt class="py-op">.</tt><tt id="link-194" class="py-name" targets="Method lxml.etree._Element.find()=lxml.etree._Element-class.html#find,Method lxml.etree._ElementTree.find()=lxml.etree._ElementTree-class.html#find,Variable lxml.objectify.ObjectPath.find=lxml.objectify.ObjectPath-class.html#find"><a title="lxml.etree._Element.find
-lxml.etree._ElementTree.find
-lxml.objectify.ObjectPath.find" class="py-name" href="#" onclick="return doclink('link-194', 'find', 'link-194');">find</a></tt><tt class="py-op">(</tt><tt class="py-string">';'</tt><tt class="py-op">)</tt> </tt>
-<a name="L412"></a><tt class="py-lineno"> 412</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-name">content</tt><tt class="py-op">[</tt><tt class="py-name">i</tt><tt class="py-op">+</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> <tt class="py-keyword">if</tt> <tt class="py-name">i</tt> <tt class="py-op">>=</tt> <tt class="py-number">0</tt> <tt class="py-keyword">else</tt> <tt class="py-name">content</tt> </tt>
-<a name="L413"></a><tt class="py-lineno"> 413</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">url</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-number">4</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-string">'url='</tt><tt class="py-op">:</tt> </tt>
-<a name="L414"></a><tt class="py-lineno"> 414</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-name">url</tt><tt class="py-op">[</tt><tt class="py-number">4</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
-<a name="L415"></a><tt class="py-lineno"> 415</tt> <tt class="py-line"> <tt class="py-comment">#else:</tt> </tt>
-<a name="L416"></a><tt class="py-lineno"> 416</tt> <tt class="py-line"> <tt class="py-comment"># No "url=" means the redirect won't work, but we might</tt> </tt>
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-194', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'content'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
+<a name="L414"></a><tt class="py-lineno"> 414</tt> <tt class="py-line"> <tt class="py-name">match</tt> <tt class="py-op">=</tt> <tt class="py-name">_parse_meta_refresh_url</tt><tt class="py-op">(</tt><tt class="py-name">content</tt><tt class="py-op">)</tt> </tt>
+<a name="L415"></a><tt class="py-lineno"> 415</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-string">'url'</tt><tt class="py-op">)</tt> <tt class="py-keyword">if</tt> <tt class="py-name">match</tt> <tt class="py-keyword">else</tt> <tt class="py-name">content</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-195" class="py-name" targets="Function lxml.doctestcompare.strip()=lxml.doctestcompare-module.html#strip"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-195', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L416"></a><tt class="py-lineno"> 416</tt> <tt class="py-line"> <tt class="py-comment"># unexpected content means the redirect won't work, but we might</tt> </tt>
<a name="L417"></a><tt class="py-lineno"> 417</tt> <tt class="py-line"> <tt class="py-comment"># as well be permissive and return the entire string.</tt> </tt>
<a name="L418"></a><tt class="py-lineno"> 418</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">url</tt><tt class="py-op">:</tt> </tt>
-<a name="L419"></a><tt class="py-lineno"> 419</tt> <tt class="py-line"> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt> <tt class="py-op">=</tt> <tt class="py-name">_unquote_match</tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">,</tt> <tt class="py-name">i</tt> <tt class="py-op">+</tt> <tt class="py-number">5</tt><tt class="py-op">)</tt> </tt>
-<a name="L420"></a><tt class="py-lineno"> 420</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'content'</tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt><tt class="py-op">)</tt> </tt>
-<a name="L421"></a><tt class="py-lineno"> 421</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-195" class="py-name"><a title="lxml.etree._Comment.tag
+<a name="L419"></a><tt class="py-lineno"> 419</tt> <tt class="py-line"> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt> <tt class="py-op">=</tt> <tt class="py-name">_unquote_match</tt><tt class="py-op">(</tt> </tt>
+<a name="L420"></a><tt class="py-lineno"> 420</tt> <tt class="py-line"> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-196" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-196', 'start', 'link-186');">start</a></tt><tt class="py-op">(</tt><tt class="py-string">'url'</tt><tt class="py-op">)</tt> <tt class="py-keyword">if</tt> <tt class="py-name">match</tt> <tt class="py-keyword">else</tt> <tt class="py-name">content</tt><tt class="py-op">.</tt><tt id="link-197" class="py-name" targets="Method lxml.etree._Element.find()=lxml.etree._Element-class.html#find,Method lxml.etree._ElementTree.find()=lxml.etree._ElementTree-class.html#find,Variable lxml.objectify.ObjectPath.find=lxml.objectify.ObjectPath-class.html#find"><a title="lxml.etree._Element.find
+lxml.etree._ElementTree.find
+lxml.objectify.ObjectPath.find" class="py-name" href="#" onclick="return doclink('link-197', 'find', 'link-197');">find</a></tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L421"></a><tt class="py-lineno"> 421</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'content'</tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt><tt class="py-op">)</tt> </tt>
+<a name="L422"></a><tt class="py-lineno"> 422</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-198" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-195', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'param'</tt><tt class="py-op">:</tt> </tt>
-<a name="L422"></a><tt class="py-lineno"> 422</tt> <tt class="py-line"> <tt class="py-name">valuetype</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-196" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-198', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'param'</tt><tt class="py-op">:</tt> </tt>
+<a name="L423"></a><tt class="py-lineno"> 423</tt> <tt class="py-line"> <tt class="py-name">valuetype</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-199" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-196', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'valuetype'</tt><tt class="py-op">)</tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L423"></a><tt class="py-lineno"> 423</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">valuetype</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-string">'ref'</tt><tt class="py-op">:</tt> </tt>
-<a name="L424"></a><tt class="py-lineno"> 424</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: while it's fine we *find* this link,</tt> </tt>
-<a name="L425"></a><tt class="py-lineno"> 425</tt> <tt class="py-line"> <tt class="py-comment">## according to the spec we aren't supposed to</tt> </tt>
-<a name="L426"></a><tt class="py-lineno"> 426</tt> <tt class="py-line"> <tt class="py-comment">## actually change the value, including resolving</tt> </tt>
-<a name="L427"></a><tt class="py-lineno"> 427</tt> <tt class="py-line"> <tt class="py-comment">## it. It can also still be a link, even if it</tt> </tt>
-<a name="L428"></a><tt class="py-lineno"> 428</tt> <tt class="py-line"> <tt class="py-comment">## doesn't have a valuetype="ref" (which seems to be the norm)</tt> </tt>
-<a name="L429"></a><tt class="py-lineno"> 429</tt> <tt class="py-line"> <tt class="py-comment">## http://www.w3.org/TR/html401/struct/objects.html#adef-valuetype</tt> </tt>
-<a name="L430"></a><tt class="py-lineno"> 430</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'value'</tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-197" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-199', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'valuetype'</tt><tt class="py-op">)</tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L424"></a><tt class="py-lineno"> 424</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">valuetype</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-string">'ref'</tt><tt class="py-op">:</tt> </tt>
+<a name="L425"></a><tt class="py-lineno"> 425</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: while it's fine we *find* this link,</tt> </tt>
+<a name="L426"></a><tt class="py-lineno"> 426</tt> <tt class="py-line"> <tt class="py-comment">## according to the spec we aren't supposed to</tt> </tt>
+<a name="L427"></a><tt class="py-lineno"> 427</tt> <tt class="py-line"> <tt class="py-comment">## actually change the value, including resolving</tt> </tt>
+<a name="L428"></a><tt class="py-lineno"> 428</tt> <tt class="py-line"> <tt class="py-comment">## it. It can also still be a link, even if it</tt> </tt>
+<a name="L429"></a><tt class="py-lineno"> 429</tt> <tt class="py-line"> <tt class="py-comment">## doesn't have a valuetype="ref" (which seems to be the norm)</tt> </tt>
+<a name="L430"></a><tt class="py-lineno"> 430</tt> <tt class="py-line"> <tt class="py-comment">## http://www.w3.org/TR/html401/struct/objects.html#adef-valuetype</tt> </tt>
+<a name="L431"></a><tt class="py-lineno"> 431</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'value'</tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-200" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-197', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
-<a name="L431"></a><tt class="py-lineno"> 431</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-198" class="py-name"><a title="lxml.etree._Comment.tag
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-200', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-number">0</tt><tt class="py-op">)</tt> </tt>
+<a name="L432"></a><tt class="py-lineno"> 432</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-201" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-198', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'style'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-199" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-201', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'style'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-202" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-199', 'text', 'link-102');">text</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L432"></a><tt class="py-lineno"> 432</tt> <tt class="py-line"> <tt class="py-name">urls</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt> </tt>
-<a name="L433"></a><tt class="py-lineno"> 433</tt> <tt class="py-line"> <tt class="py-comment"># (start_pos, url)</tt> </tt>
-<a name="L434"></a><tt class="py-lineno"> 434</tt> <tt class="py-line"> <tt class="py-name">_unquote_match</tt><tt class="py-op">(</tt><tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-200" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-200', 'start', 'link-185');">start</a></tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> </tt>
-<a name="L435"></a><tt class="py-lineno"> 435</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt class="py-name">_iter_css_urls</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-201" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-202', 'text', 'link-103');">text</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L433"></a><tt class="py-lineno"> 433</tt> <tt class="py-line"> <tt class="py-name">urls</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt> </tt>
+<a name="L434"></a><tt class="py-lineno"> 434</tt> <tt class="py-line"> <tt class="py-comment"># (start_pos, url)</tt> </tt>
+<a name="L435"></a><tt class="py-lineno"> 435</tt> <tt class="py-line"> <tt class="py-name">_unquote_match</tt><tt class="py-op">(</tt><tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-203" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-203', 'start', 'link-186');">start</a></tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt> </tt>
+<a name="L436"></a><tt class="py-lineno"> 436</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt class="py-name">_iter_css_urls</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-204" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-201', 'text', 'link-102');">text</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L436"></a><tt class="py-lineno"> 436</tt> <tt class="py-line"> <tt class="py-op">]</tt> <tt class="py-op">+</tt> <tt class="py-op">[</tt> </tt>
-<a name="L437"></a><tt class="py-lineno"> 437</tt> <tt class="py-line"> <tt class="py-op">(</tt><tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-202" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-202', 'start', 'link-185');">start</a></tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L438"></a><tt class="py-lineno"> 438</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt class="py-name">_iter_css_imports</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-203" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-204', 'text', 'link-103');">text</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L437"></a><tt class="py-lineno"> 437</tt> <tt class="py-line"> <tt class="py-op">]</tt> <tt class="py-op">+</tt> <tt class="py-op">[</tt> </tt>
+<a name="L438"></a><tt class="py-lineno"> 438</tt> <tt class="py-line"> <tt class="py-op">(</tt><tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-205" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-205', 'start', 'link-186');">start</a></tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L439"></a><tt class="py-lineno"> 439</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt class="py-name">_iter_css_imports</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-206" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-203', 'text', 'link-102');">text</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L439"></a><tt class="py-lineno"> 439</tt> <tt class="py-line"> <tt class="py-op">]</tt> </tt>
-<a name="L440"></a><tt class="py-lineno"> 440</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">urls</tt><tt class="py-op">:</tt> </tt>
-<a name="L441"></a><tt class="py-lineno"> 441</tt> <tt class="py-line"> <tt class="py-comment"># sort by start pos to bring both match sets back into order</tt> </tt>
-<a name="L442"></a><tt class="py-lineno"> 442</tt> <tt class="py-line"> <tt class="py-comment"># and reverse the list to report correct positions despite</tt> </tt>
-<a name="L443"></a><tt class="py-lineno"> 443</tt> <tt class="py-line"> <tt class="py-comment"># modifications</tt> </tt>
-<a name="L444"></a><tt class="py-lineno"> 444</tt> <tt class="py-line"> <tt class="py-name">urls</tt><tt class="py-op">.</tt><tt class="py-name">sort</tt><tt class="py-op">(</tt><tt class="py-name">reverse</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
-<a name="L445"></a><tt class="py-lineno"> 445</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-204" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-204', 'start', 'link-185');">start</a></tt><tt class="py-op">,</tt> <tt class="py-name">url</tt> <tt class="py-keyword">in</tt> <tt class="py-name">urls</tt><tt class="py-op">:</tt> </tt>
-<a name="L446"></a><tt class="py-lineno"> 446</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-205" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-205', 'start', 'link-185');">start</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L447"></a><tt class="py-lineno"> 447</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'style'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
-<a name="L448"></a><tt class="py-lineno"> 448</tt> <tt class="py-line"> <tt class="py-name">urls</tt> <tt class="py-op">=</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">_iter_css_urls</tt><tt class="py-op">(</tt><tt class="py-name">attribs</tt><tt class="py-op">[</tt><tt class="py-string">'style'</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L449"></a><tt class="py-lineno"> 449</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">urls</tt><tt class="py-op">:</tt> </tt>
-<a name="L450"></a><tt class="py-lineno"> 450</tt> <tt class="py-line"> <tt class="py-comment"># return in reversed order to simplify in-place modifications</tt> </tt>
-<a name="L451"></a><tt class="py-lineno"> 451</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt class="py-name">urls</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">:</tt> </tt>
-<a name="L452"></a><tt class="py-lineno"> 452</tt> <tt class="py-line"> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-206" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-206', 'start', 'link-185');">start</a></tt> <tt class="py-op">=</tt> <tt class="py-name">_unquote_match</tt><tt class="py-op">(</tt><tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-207" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-207', 'start', 'link-185');">start</a></tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L453"></a><tt class="py-lineno"> 453</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'style'</tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-208" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-208', 'start', 'link-185');">start</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L454"></a><tt class="py-lineno"> 454</tt> <tt class="py-line"> </tt>
-<a name="HtmlMixin.rewrite_links"></a><div id="HtmlMixin.rewrite_links-def"><a name="L455"></a><tt class="py-lineno"> 455</tt> <a class="py-toggle" href="#" id="HtmlMixin.rewrite_links-toggle" onclick="return toggle('HtmlMixin.rewrite_links');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#rewrite_links">rewrite_links</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">link_repl_func</tt><tt class="py-op">,</tt> <tt class="py-param">resolve_base_href</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> </tt>
-<a name="L456"></a><tt class="py-lineno"> 456</tt> <tt class="py-line"> <tt class="py-param">base_href</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlMixin.rewrite_links-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.rewrite_links-expanded"><a name="L457"></a><tt class="py-lineno"> 457</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L458"></a><tt class="py-lineno"> 458</tt> <tt class="py-line"><tt class="py-docstring"> Rewrite all the links in the document. For each link</tt> </tt>
-<a name="L459"></a><tt class="py-lineno"> 459</tt> <tt class="py-line"><tt class="py-docstring"> ``link_repl_func(link)`` will be called, and the return value</tt> </tt>
-<a name="L460"></a><tt class="py-lineno"> 460</tt> <tt class="py-line"><tt class="py-docstring"> will replace the old link.</tt> </tt>
-<a name="L461"></a><tt class="py-lineno"> 461</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L462"></a><tt class="py-lineno"> 462</tt> <tt class="py-line"><tt class="py-docstring"> Note that links may not be absolute (unless you first called</tt> </tt>
-<a name="L463"></a><tt class="py-lineno"> 463</tt> <tt class="py-line"><tt class="py-docstring"> ``make_links_absolute()``), and may be internal (e.g.,</tt> </tt>
-<a name="L464"></a><tt class="py-lineno"> 464</tt> <tt class="py-line"><tt class="py-docstring"> ``'#anchor'``). They can also be values like</tt> </tt>
-<a name="L465"></a><tt class="py-lineno"> 465</tt> <tt class="py-line"><tt class="py-docstring"> ``'mailto:email'`` or ``'javascript:expr'``.</tt> </tt>
-<a name="L466"></a><tt class="py-lineno"> 466</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L467"></a><tt class="py-lineno"> 467</tt> <tt class="py-line"><tt class="py-docstring"> If you give ``base_href`` then all links passed to</tt> </tt>
-<a name="L468"></a><tt class="py-lineno"> 468</tt> <tt class="py-line"><tt class="py-docstring"> ``link_repl_func()`` will take that into account.</tt> </tt>
-<a name="L469"></a><tt class="py-lineno"> 469</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L470"></a><tt class="py-lineno"> 470</tt> <tt class="py-line"><tt class="py-docstring"> If the ``link_repl_func`` returns None, the attribute or</tt> </tt>
-<a name="L471"></a><tt class="py-lineno"> 471</tt> <tt class="py-line"><tt class="py-docstring"> tag text will be removed completely.</tt> </tt>
-<a name="L472"></a><tt class="py-lineno"> 472</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L473"></a><tt class="py-lineno"> 473</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">base_href</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L474"></a><tt class="py-lineno"> 474</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: this can be done in one pass with a wrapper</tt> </tt>
-<a name="L475"></a><tt class="py-lineno"> 475</tt> <tt class="py-line"> <tt class="py-comment"># around link_repl_func</tt> </tt>
-<a name="L476"></a><tt class="py-lineno"> 476</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-209" class="py-name"><a title="lxml.html.HtmlMixin.make_links_absolute
-lxml.html.make_links_absolute" class="py-name" href="#" onclick="return doclink('link-209', 'make_links_absolute', 'link-157');">make_links_absolute</a></tt><tt class="py-op">(</tt> </tt>
-<a name="L477"></a><tt class="py-lineno"> 477</tt> <tt class="py-line"> <tt class="py-name">base_href</tt><tt class="py-op">,</tt> <tt id="link-210" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-210', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt><tt class="py-op">=</tt><tt id="link-211" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-211', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L478"></a><tt class="py-lineno"> 478</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-212" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-212', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L479"></a><tt class="py-lineno"> 479</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-213" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-213', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L480"></a><tt class="py-lineno"> 480</tt> <tt class="py-line"> </tt>
-<a name="L481"></a><tt class="py-lineno"> 481</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-214" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-206', 'text', 'link-103');">text</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L440"></a><tt class="py-lineno"> 440</tt> <tt class="py-line"> <tt class="py-op">]</tt> </tt>
+<a name="L441"></a><tt class="py-lineno"> 441</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">urls</tt><tt class="py-op">:</tt> </tt>
+<a name="L442"></a><tt class="py-lineno"> 442</tt> <tt class="py-line"> <tt class="py-comment"># sort by start pos to bring both match sets back into order</tt> </tt>
+<a name="L443"></a><tt class="py-lineno"> 443</tt> <tt class="py-line"> <tt class="py-comment"># and reverse the list to report correct positions despite</tt> </tt>
+<a name="L444"></a><tt class="py-lineno"> 444</tt> <tt class="py-line"> <tt class="py-comment"># modifications</tt> </tt>
+<a name="L445"></a><tt class="py-lineno"> 445</tt> <tt class="py-line"> <tt class="py-name">urls</tt><tt class="py-op">.</tt><tt class="py-name">sort</tt><tt class="py-op">(</tt><tt class="py-name">reverse</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
+<a name="L446"></a><tt class="py-lineno"> 446</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-207" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-207', 'start', 'link-186');">start</a></tt><tt class="py-op">,</tt> <tt class="py-name">url</tt> <tt class="py-keyword">in</tt> <tt class="py-name">urls</tt><tt class="py-op">:</tt> </tt>
+<a name="L447"></a><tt class="py-lineno"> 447</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-208" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-208', 'start', 'link-186');">start</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L448"></a><tt class="py-lineno"> 448</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'style'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">attribs</tt><tt class="py-op">:</tt> </tt>
+<a name="L449"></a><tt class="py-lineno"> 449</tt> <tt class="py-line"> <tt class="py-name">urls</tt> <tt class="py-op">=</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">_iter_css_urls</tt><tt class="py-op">(</tt><tt class="py-name">attribs</tt><tt class="py-op">[</tt><tt class="py-string">'style'</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L450"></a><tt class="py-lineno"> 450</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">urls</tt><tt class="py-op">:</tt> </tt>
+<a name="L451"></a><tt class="py-lineno"> 451</tt> <tt class="py-line"> <tt class="py-comment"># return in reversed order to simplify in-place modifications</tt> </tt>
+<a name="L452"></a><tt class="py-lineno"> 452</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">match</tt> <tt class="py-keyword">in</tt> <tt class="py-name">urls</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">:</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">:</tt> </tt>
+<a name="L453"></a><tt class="py-lineno"> 453</tt> <tt class="py-line"> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-209" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-209', 'start', 'link-186');">start</a></tt> <tt class="py-op">=</tt> <tt class="py-name">_unquote_match</tt><tt class="py-op">(</tt><tt class="py-name">match</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">match</tt><tt class="py-op">.</tt><tt id="link-210" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-210', 'start', 'link-186');">start</a></tt><tt class="py-op">(</tt><tt class="py-number">1</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L454"></a><tt class="py-lineno"> 454</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt class="py-string">'style'</tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-211" class="py-name"><a title="lxml.etree.TreeBuilder.start" class="py-name" href="#" onclick="return doclink('link-211', 'start', 'link-186');">start</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L455"></a><tt class="py-lineno"> 455</tt> <tt class="py-line"> </tt>
+<a name="HtmlMixin.rewrite_links"></a><div id="HtmlMixin.rewrite_links-def"><a name="L456"></a><tt class="py-lineno"> 456</tt> <a class="py-toggle" href="#" id="HtmlMixin.rewrite_links-toggle" onclick="return toggle('HtmlMixin.rewrite_links');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlMixin-class.html#rewrite_links">rewrite_links</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">link_repl_func</tt><tt class="py-op">,</tt> <tt class="py-param">resolve_base_href</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> </tt>
+<a name="L457"></a><tt class="py-lineno"> 457</tt> <tt class="py-line"> <tt class="py-param">base_href</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlMixin.rewrite_links-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlMixin.rewrite_links-expanded"><a name="L458"></a><tt class="py-lineno"> 458</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L459"></a><tt class="py-lineno"> 459</tt> <tt class="py-line"><tt class="py-docstring"> Rewrite all the links in the document. For each link</tt> </tt>
+<a name="L460"></a><tt class="py-lineno"> 460</tt> <tt class="py-line"><tt class="py-docstring"> ``link_repl_func(link)`` will be called, and the return value</tt> </tt>
+<a name="L461"></a><tt class="py-lineno"> 461</tt> <tt class="py-line"><tt class="py-docstring"> will replace the old link.</tt> </tt>
+<a name="L462"></a><tt class="py-lineno"> 462</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L463"></a><tt class="py-lineno"> 463</tt> <tt class="py-line"><tt class="py-docstring"> Note that links may not be absolute (unless you first called</tt> </tt>
+<a name="L464"></a><tt class="py-lineno"> 464</tt> <tt class="py-line"><tt class="py-docstring"> ``make_links_absolute()``), and may be internal (e.g.,</tt> </tt>
+<a name="L465"></a><tt class="py-lineno"> 465</tt> <tt class="py-line"><tt class="py-docstring"> ``'#anchor'``). They can also be values like</tt> </tt>
+<a name="L466"></a><tt class="py-lineno"> 466</tt> <tt class="py-line"><tt class="py-docstring"> ``'mailto:email'`` or ``'javascript:expr'``.</tt> </tt>
+<a name="L467"></a><tt class="py-lineno"> 467</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L468"></a><tt class="py-lineno"> 468</tt> <tt class="py-line"><tt class="py-docstring"> If you give ``base_href`` then all links passed to</tt> </tt>
+<a name="L469"></a><tt class="py-lineno"> 469</tt> <tt class="py-line"><tt class="py-docstring"> ``link_repl_func()`` will take that into account.</tt> </tt>
+<a name="L470"></a><tt class="py-lineno"> 470</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L471"></a><tt class="py-lineno"> 471</tt> <tt class="py-line"><tt class="py-docstring"> If the ``link_repl_func`` returns None, the attribute or</tt> </tt>
+<a name="L472"></a><tt class="py-lineno"> 472</tt> <tt class="py-line"><tt class="py-docstring"> tag text will be removed completely.</tt> </tt>
+<a name="L473"></a><tt class="py-lineno"> 473</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L474"></a><tt class="py-lineno"> 474</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">base_href</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L475"></a><tt class="py-lineno"> 475</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: this can be done in one pass with a wrapper</tt> </tt>
+<a name="L476"></a><tt class="py-lineno"> 476</tt> <tt class="py-line"> <tt class="py-comment"># around link_repl_func</tt> </tt>
+<a name="L477"></a><tt class="py-lineno"> 477</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-212" class="py-name"><a title="lxml.html.HtmlMixin.make_links_absolute
+lxml.html.make_links_absolute" class="py-name" href="#" onclick="return doclink('link-212', 'make_links_absolute', 'link-158');">make_links_absolute</a></tt><tt class="py-op">(</tt> </tt>
+<a name="L478"></a><tt class="py-lineno"> 478</tt> <tt class="py-line"> <tt class="py-name">base_href</tt><tt class="py-op">,</tt> <tt id="link-213" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-213', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt><tt class="py-op">=</tt><tt id="link-214" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-214', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L479"></a><tt class="py-lineno"> 479</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-215" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-215', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L480"></a><tt class="py-lineno"> 480</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-216" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-216', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L481"></a><tt class="py-lineno"> 481</tt> <tt class="py-line"> </tt>
+<a name="L482"></a><tt class="py-lineno"> 482</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-217" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-214', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">,</tt> <tt class="py-name">link</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-215" class="py-name" targets="Method lxml.html.HtmlMixin.iterlinks()=lxml.html.HtmlMixin-class.html#iterlinks,Variable lxml.html.iterlinks=lxml.html-module.html#iterlinks"><a title="lxml.html.HtmlMixin.iterlinks
-lxml.html.iterlinks" class="py-name" href="#" onclick="return doclink('link-215', 'iterlinks', 'link-215');">iterlinks</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L482"></a><tt class="py-lineno"> 482</tt> <tt class="py-line"> <tt class="py-name">new_link</tt> <tt class="py-op">=</tt> <tt class="py-name">link_repl_func</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">.</tt><tt id="link-216" class="py-name" targets="Function lxml.doctestcompare.strip()=lxml.doctestcompare-module.html#strip"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-216', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L483"></a><tt class="py-lineno"> 483</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">new_link</tt> <tt class="py-op">==</tt> <tt class="py-name">link</tt><tt class="py-op">:</tt> </tt>
-<a name="L484"></a><tt class="py-lineno"> 484</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
-<a name="L485"></a><tt class="py-lineno"> 485</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">new_link</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L486"></a><tt class="py-lineno"> 486</tt> <tt class="py-line"> <tt class="py-comment"># Remove the attribute or element content</tt> </tt>
-<a name="L487"></a><tt class="py-lineno"> 487</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-217" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-217', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">,</tt> <tt class="py-name">link</tt><tt class="py-op">,</tt> <tt class="py-name">pos</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-218" class="py-name" targets="Method lxml.html.HtmlMixin.iterlinks()=lxml.html.HtmlMixin-class.html#iterlinks,Variable lxml.html.iterlinks=lxml.html-module.html#iterlinks"><a title="lxml.html.HtmlMixin.iterlinks
+lxml.html.iterlinks" class="py-name" href="#" onclick="return doclink('link-218', 'iterlinks', 'link-218');">iterlinks</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L483"></a><tt class="py-lineno"> 483</tt> <tt class="py-line"> <tt class="py-name">new_link</tt> <tt class="py-op">=</tt> <tt class="py-name">link_repl_func</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">.</tt><tt id="link-219" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-219', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L484"></a><tt class="py-lineno"> 484</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">new_link</tt> <tt class="py-op">==</tt> <tt class="py-name">link</tt><tt class="py-op">:</tt> </tt>
+<a name="L485"></a><tt class="py-lineno"> 485</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
+<a name="L486"></a><tt class="py-lineno"> 486</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">new_link</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L487"></a><tt class="py-lineno"> 487</tt> <tt class="py-line"> <tt class="py-comment"># Remove the attribute or element content</tt> </tt>
+<a name="L488"></a><tt class="py-lineno"> 488</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-220" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-217', 'attrib', 'link-92');">attrib</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L488"></a><tt class="py-lineno"> 488</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-218" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-220', 'attrib', 'link-93');">attrib</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L489"></a><tt class="py-lineno"> 489</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-221" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-218', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-string">''</tt> </tt>
-<a name="L489"></a><tt class="py-lineno"> 489</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L490"></a><tt class="py-lineno"> 490</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-219" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-221', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-string">''</tt> </tt>
+<a name="L490"></a><tt class="py-lineno"> 490</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L491"></a><tt class="py-lineno"> 491</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-222" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-219', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt id="link-220" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-222', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt id="link-223" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-220', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">]</tt> </tt>
-<a name="L491"></a><tt class="py-lineno"> 491</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
-<a name="L492"></a><tt class="py-lineno"> 492</tt> <tt class="py-line"> </tt>
-<a name="L493"></a><tt class="py-lineno"> 493</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-221" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-223', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">]</tt> </tt>
+<a name="L492"></a><tt class="py-lineno"> 492</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
+<a name="L493"></a><tt class="py-lineno"> 493</tt> <tt class="py-line"> </tt>
+<a name="L494"></a><tt class="py-lineno"> 494</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-224" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-221', 'attrib', 'link-92');">attrib</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L494"></a><tt class="py-lineno"> 494</tt> <tt class="py-line"> <tt class="py-name">new</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-222" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-224', 'attrib', 'link-93');">attrib</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L495"></a><tt class="py-lineno"> 495</tt> <tt class="py-line"> <tt class="py-name">new</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-225" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-222', 'text', 'link-102');">text</a></tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-name">pos</tt><tt class="py-op">]</tt> <tt class="py-op">+</tt> <tt class="py-name">new_link</tt> <tt class="py-op">+</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-223" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-225', 'text', 'link-103');">text</a></tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-name">pos</tt><tt class="py-op">]</tt> <tt class="py-op">+</tt> <tt class="py-name">new_link</tt> <tt class="py-op">+</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-226" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-223', 'text', 'link-102');">text</a></tt><tt class="py-op">[</tt><tt class="py-name">pos</tt><tt class="py-op">+</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">)</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
-<a name="L495"></a><tt class="py-lineno"> 495</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-224" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-226', 'text', 'link-103');">text</a></tt><tt class="py-op">[</tt><tt class="py-name">pos</tt><tt class="py-op">+</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">)</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
+<a name="L496"></a><tt class="py-lineno"> 496</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-227" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-224', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-name">new</tt> </tt>
-<a name="L496"></a><tt class="py-lineno"> 496</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L497"></a><tt class="py-lineno"> 497</tt> <tt class="py-line"> <tt class="py-name">cur</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-225" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-227', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-name">new</tt> </tt>
+<a name="L497"></a><tt class="py-lineno"> 497</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L498"></a><tt class="py-lineno"> 498</tt> <tt class="py-line"> <tt class="py-name">cur</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-228" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-225', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt id="link-226" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-228', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt id="link-229" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-226', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L498"></a><tt class="py-lineno"> 498</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">pos</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">cur</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L499"></a><tt class="py-lineno"> 499</tt> <tt class="py-line"> <tt class="py-name">new</tt> <tt class="py-op">=</tt> <tt class="py-name">new_link</tt> <tt class="py-comment"># most common case</tt> </tt>
-<a name="L500"></a><tt class="py-lineno"> 500</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L501"></a><tt class="py-lineno"> 501</tt> <tt class="py-line"> <tt class="py-name">new</tt> <tt class="py-op">=</tt> <tt class="py-name">cur</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-name">pos</tt><tt class="py-op">]</tt> <tt class="py-op">+</tt> <tt class="py-name">new_link</tt> <tt class="py-op">+</tt> <tt class="py-name">cur</tt><tt class="py-op">[</tt><tt class="py-name">pos</tt><tt class="py-op">+</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">)</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
-<a name="L502"></a><tt class="py-lineno"> 502</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-227" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-227', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt id="link-228" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-229', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L499"></a><tt class="py-lineno"> 499</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">pos</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">cur</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L500"></a><tt class="py-lineno"> 500</tt> <tt class="py-line"> <tt class="py-name">new</tt> <tt class="py-op">=</tt> <tt class="py-name">new_link</tt> <tt class="py-comment"># most common case</tt> </tt>
+<a name="L501"></a><tt class="py-lineno"> 501</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L502"></a><tt class="py-lineno"> 502</tt> <tt class="py-line"> <tt class="py-name">new</tt> <tt class="py-op">=</tt> <tt class="py-name">cur</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-name">pos</tt><tt class="py-op">]</tt> <tt class="py-op">+</tt> <tt class="py-name">new_link</tt> <tt class="py-op">+</tt> <tt class="py-name">cur</tt><tt class="py-op">[</tt><tt class="py-name">pos</tt><tt class="py-op">+</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">link</tt><tt class="py-op">)</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
+<a name="L503"></a><tt class="py-lineno"> 503</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-230" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-230', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt id="link-231" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-228', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">,</tt> <tt class="py-name">new</tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L503"></a><tt class="py-lineno"> 503</tt> <tt class="py-line"> </tt>
-<a name="L504"></a><tt class="py-lineno"> 504</tt> <tt class="py-line"> </tt>
-<a name="_MethodFunc"></a><div id="_MethodFunc-def"><a name="L505"></a><tt class="py-lineno"> 505</tt> <a class="py-toggle" href="#" id="_MethodFunc-toggle" onclick="return toggle('_MethodFunc');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html._MethodFunc-class.html">_MethodFunc</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_MethodFunc-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_MethodFunc-expanded"><a name="L506"></a><tt class="py-lineno"> 506</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L507"></a><tt class="py-lineno"> 507</tt> <tt class="py-line"><tt class="py-docstring"> An object that represents a method on an element as a function;</tt> </tt>
-<a name="L508"></a><tt class="py-lineno"> 508</tt> <tt class="py-line"><tt class="py-docstring"> the function takes either an element or an HTML string. It</tt> </tt>
-<a name="L509"></a><tt class="py-lineno"> 509</tt> <tt class="py-line"><tt class="py-docstring"> returns whatever the function normally returns, or if the function</tt> </tt>
-<a name="L510"></a><tt class="py-lineno"> 510</tt> <tt class="py-line"><tt class="py-docstring"> works in-place (and so returns None) it returns a serialized form</tt> </tt>
-<a name="L511"></a><tt class="py-lineno"> 511</tt> <tt class="py-line"><tt class="py-docstring"> of the resulting document.</tt> </tt>
-<a name="L512"></a><tt class="py-lineno"> 512</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="_MethodFunc.__init__"></a><div id="_MethodFunc.__init__-def"><a name="L513"></a><tt class="py-lineno"> 513</tt> <a class="py-toggle" href="#" id="_MethodFunc.__init__-toggle" onclick="return toggle('_MethodFunc.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html._MethodFunc-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">,</tt> <tt class="py-param">copy</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">source_class</tt><tt class="py-op">=</tt><tt id="link-229" class="py-name" targets="Class lxml.html.HtmlMixin=lxml.html.HtmlMixin-class.html"><a title="lxml.html.HtmlMixin" class="py-name" href="#" onclick="return doclink('link-229', 'HtmlMixin', 'link-229');">HtmlMixin</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_MethodFunc.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="_MethodFunc.__init__-expanded"><a name="L514"></a><tt class="py-lineno"> 514</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-230" class="py-name" targets="Variable lxml.etree.DTD.name=lxml.etree.DTD-class.html#name,Variable lxml.etree._Entity.name=lxml.etree._Entity-class.html#name,Variable lxml.html.InputMixin.name=lxml.html.InputMixin-class.html#name,Variable lxml.objectify.PyType.name=lxml.objectify.PyType-class.html#name"><a title="lxml.etree.DTD.name
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-231', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">,</tt> <tt class="py-name">new</tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L504"></a><tt class="py-lineno"> 504</tt> <tt class="py-line"> </tt>
+<a name="L505"></a><tt class="py-lineno"> 505</tt> <tt class="py-line"> </tt>
+<a name="_MethodFunc"></a><div id="_MethodFunc-def"><a name="L506"></a><tt class="py-lineno"> 506</tt> <a class="py-toggle" href="#" id="_MethodFunc-toggle" onclick="return toggle('_MethodFunc');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html._MethodFunc-class.html">_MethodFunc</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_MethodFunc-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_MethodFunc-expanded"><a name="L507"></a><tt class="py-lineno"> 507</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L508"></a><tt class="py-lineno"> 508</tt> <tt class="py-line"><tt class="py-docstring"> An object that represents a method on an element as a function;</tt> </tt>
+<a name="L509"></a><tt class="py-lineno"> 509</tt> <tt class="py-line"><tt class="py-docstring"> the function takes either an element or an HTML string. It</tt> </tt>
+<a name="L510"></a><tt class="py-lineno"> 510</tt> <tt class="py-line"><tt class="py-docstring"> returns whatever the function normally returns, or if the function</tt> </tt>
+<a name="L511"></a><tt class="py-lineno"> 511</tt> <tt class="py-line"><tt class="py-docstring"> works in-place (and so returns None) it returns a serialized form</tt> </tt>
+<a name="L512"></a><tt class="py-lineno"> 512</tt> <tt class="py-line"><tt class="py-docstring"> of the resulting document.</tt> </tt>
+<a name="L513"></a><tt class="py-lineno"> 513</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="_MethodFunc.__init__"></a><div id="_MethodFunc.__init__-def"><a name="L514"></a><tt class="py-lineno"> 514</tt> <a class="py-toggle" href="#" id="_MethodFunc.__init__-toggle" onclick="return toggle('_MethodFunc.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html._MethodFunc-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">,</tt> <tt class="py-param">copy</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">source_class</tt><tt class="py-op">=</tt><tt id="link-232" class="py-name" targets="Class lxml.html.HtmlMixin=lxml.html.HtmlMixin-class.html"><a title="lxml.html.HtmlMixin" class="py-name" href="#" onclick="return doclink('link-232', 'HtmlMixin', 'link-232');">HtmlMixin</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_MethodFunc.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="_MethodFunc.__init__-expanded"><a name="L515"></a><tt class="py-lineno"> 515</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-233" class="py-name" targets="Variable lxml.etree.DTD.name=lxml.etree.DTD-class.html#name,Variable lxml.etree._Entity.name=lxml.etree._Entity-class.html#name,Variable lxml.html.InputMixin.name=lxml.html.InputMixin-class.html#name,Variable lxml.objectify.PyType.name=lxml.objectify.PyType-class.html#name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-230', 'name', 'link-230');">name</a></tt> <tt class="py-op">=</tt> <tt id="link-231" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-233', 'name', 'link-233');">name</a></tt> <tt class="py-op">=</tt> <tt id="link-234" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-231', 'name', 'link-230');">name</a></tt> </tt>
-<a name="L515"></a><tt class="py-lineno"> 515</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-232" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-234', 'name', 'link-233');">name</a></tt> </tt>
+<a name="L516"></a><tt class="py-lineno"> 516</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-235" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-232', 'copy', 'link-1');">copy</a></tt> <tt class="py-op">=</tt> <tt id="link-233" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-235', 'copy', 'link-1');">copy</a></tt> <tt class="py-op">=</tt> <tt id="link-236" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-233', 'copy', 'link-1');">copy</a></tt> </tt>
-<a name="L516"></a><tt class="py-lineno"> 516</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-234" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-234', '__doc__', 'link-62');">__doc__</a></tt> <tt class="py-op">=</tt> <tt class="py-name">getattr</tt><tt class="py-op">(</tt><tt class="py-name">source_class</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-235" class="py-name"><a title="lxml.etree.DTD.name
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-236', 'copy', 'link-1');">copy</a></tt> </tt>
+<a name="L517"></a><tt class="py-lineno"> 517</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-237" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-237', '__doc__', 'link-63');">__doc__</a></tt> <tt class="py-op">=</tt> <tt class="py-name">getattr</tt><tt class="py-op">(</tt><tt class="py-name">source_class</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-238" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-235', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-236" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-236', '__doc__', 'link-62');">__doc__</a></tt> </tt>
-</div><a name="_MethodFunc.__call__"></a><div id="_MethodFunc.__call__-def"><a name="L517"></a><tt class="py-lineno"> 517</tt> <a class="py-toggle" href="#" id="_MethodFunc.__call__-toggle" onclick="return toggle('_MethodFunc.__call__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html._MethodFunc-class.html#__call__">__call__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">doc</tt><tt class="py-op">,</tt> <tt class="py-op">*</tt><tt class="py-param">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_MethodFunc.__call__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="_MethodFunc.__call__-expanded"><a name="L518"></a><tt class="py-lineno"> 518</tt> <tt class="py-line"> <tt class="py-name">result_type</tt> <tt class="py-op">=</tt> <tt id="link-237" class="py-name" targets="Variable lxml.etree._LogEntry.type=lxml.etree._LogEntry-class.html#type,Variable lxml.html.InputElement.type=lxml.html.InputElement-class.html#type"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-237', 'type', 'link-237');">type</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
-<a name="L519"></a><tt class="py-lineno"> 519</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt id="link-238" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-238', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L520"></a><tt class="py-lineno"> 520</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'copy'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">kw</tt><tt class="py-op">:</tt> </tt>
-<a name="L521"></a><tt class="py-lineno"> 521</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
-<a name="L522"></a><tt class="py-lineno"> 522</tt> <tt class="py-line"> <tt class="py-string">"The keyword 'copy' can only be used with element inputs to %s, not a string input"</tt> <tt class="py-op">%</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-239" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-238', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-239" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-239', '__doc__', 'link-63');">__doc__</a></tt> </tt>
+</div><a name="_MethodFunc.__call__"></a><div id="_MethodFunc.__call__-def"><a name="L518"></a><tt class="py-lineno"> 518</tt> <a class="py-toggle" href="#" id="_MethodFunc.__call__-toggle" onclick="return toggle('_MethodFunc.__call__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html._MethodFunc-class.html#__call__">__call__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">doc</tt><tt class="py-op">,</tt> <tt class="py-op">*</tt><tt class="py-param">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_MethodFunc.__call__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="_MethodFunc.__call__-expanded"><a name="L519"></a><tt class="py-lineno"> 519</tt> <tt class="py-line"> <tt class="py-name">result_type</tt> <tt class="py-op">=</tt> <tt id="link-240" class="py-name" targets="Variable lxml.etree._LogEntry.type=lxml.etree._LogEntry-class.html#type,Variable lxml.html.InputElement.type=lxml.html.InputElement-class.html#type"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-240', 'type', 'link-240');">type</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
+<a name="L520"></a><tt class="py-lineno"> 520</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt id="link-241" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-241', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L521"></a><tt class="py-lineno"> 521</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'copy'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">kw</tt><tt class="py-op">:</tt> </tt>
+<a name="L522"></a><tt class="py-lineno"> 522</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
+<a name="L523"></a><tt class="py-lineno"> 523</tt> <tt class="py-line"> <tt class="py-string">"The keyword 'copy' can only be used with element inputs to %s, not a string input"</tt> <tt class="py-op">%</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-242" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-239', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L523"></a><tt class="py-lineno"> 523</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-240" class="py-name" targets="Function lxml.etree.fromstring()=lxml.etree-module.html#fromstring,Function lxml.html.html5parser.fromstring()=lxml.html.html5parser-module.html#fromstring,Function lxml.html.soupparser.fromstring()=lxml.html.soupparser-module.html#fromstring,Function lxml.objectify.fromstring()=lxml.objectify-module.html#fromstring"><a title="lxml.etree.fromstring
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-242', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L524"></a><tt class="py-lineno"> 524</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-243" class="py-name" targets="Function lxml.etree.fromstring()=lxml.etree-module.html#fromstring,Function lxml.html.html5parser.fromstring()=lxml.html.html5parser-module.html#fromstring,Function lxml.html.soupparser.fromstring()=lxml.html.soupparser-module.html#fromstring,Function lxml.objectify.fromstring()=lxml.objectify-module.html#fromstring"><a title="lxml.etree.fromstring
lxml.html.html5parser.fromstring
lxml.html.soupparser.fromstring
-lxml.objectify.fromstring" class="py-name" href="#" onclick="return doclink('link-240', 'fromstring', 'link-240');">fromstring</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-<a name="L524"></a><tt class="py-lineno"> 524</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L525"></a><tt class="py-lineno"> 525</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'copy'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">kw</tt><tt class="py-op">:</tt> </tt>
-<a name="L526"></a><tt class="py-lineno"> 526</tt> <tt class="py-line"> <tt class="py-name">make_a_copy</tt> <tt class="py-op">=</tt> <tt class="py-name">kw</tt><tt class="py-op">.</tt><tt id="link-241" class="py-name" targets="Method lxml.etree._Attrib.pop()=lxml.etree._Attrib-class.html#pop"><a title="lxml.etree._Attrib.pop" class="py-name" href="#" onclick="return doclink('link-241', 'pop', 'link-241');">pop</a></tt><tt class="py-op">(</tt><tt class="py-string">'copy'</tt><tt class="py-op">)</tt> </tt>
-<a name="L527"></a><tt class="py-lineno"> 527</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L528"></a><tt class="py-lineno"> 528</tt> <tt class="py-line"> <tt class="py-name">make_a_copy</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-242" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.objectify.fromstring" class="py-name" href="#" onclick="return doclink('link-243', 'fromstring', 'link-243');">fromstring</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+<a name="L525"></a><tt class="py-lineno"> 525</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L526"></a><tt class="py-lineno"> 526</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'copy'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">kw</tt><tt class="py-op">:</tt> </tt>
+<a name="L527"></a><tt class="py-lineno"> 527</tt> <tt class="py-line"> <tt class="py-name">make_a_copy</tt> <tt class="py-op">=</tt> <tt class="py-name">kw</tt><tt class="py-op">.</tt><tt id="link-244" class="py-name" targets="Method lxml.etree._Attrib.pop()=lxml.etree._Attrib-class.html#pop"><a title="lxml.etree._Attrib.pop" class="py-name" href="#" onclick="return doclink('link-244', 'pop', 'link-244');">pop</a></tt><tt class="py-op">(</tt><tt class="py-string">'copy'</tt><tt class="py-op">)</tt> </tt>
+<a name="L528"></a><tt class="py-lineno"> 528</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L529"></a><tt class="py-lineno"> 529</tt> <tt class="py-line"> <tt class="py-name">make_a_copy</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-245" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-242', 'copy', 'link-1');">copy</a></tt> </tt>
-<a name="L529"></a><tt class="py-lineno"> 529</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">make_a_copy</tt><tt class="py-op">:</tt> </tt>
-<a name="L530"></a><tt class="py-lineno"> 530</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-243" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-245', 'copy', 'link-1');">copy</a></tt> </tt>
+<a name="L530"></a><tt class="py-lineno"> 530</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">make_a_copy</tt><tt class="py-op">:</tt> </tt>
+<a name="L531"></a><tt class="py-lineno"> 531</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-246" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-243', 'copy', 'link-1');">copy</a></tt><tt class="py-op">.</tt><tt class="py-name">deepcopy</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
-<a name="L531"></a><tt class="py-lineno"> 531</tt> <tt class="py-line"> <tt class="py-name">meth</tt> <tt class="py-op">=</tt> <tt class="py-name">getattr</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-244" class="py-name"><a title="lxml.etree.DTD.name
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-246', 'copy', 'link-1');">copy</a></tt><tt class="py-op">.</tt><tt class="py-name">deepcopy</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
+<a name="L532"></a><tt class="py-lineno"> 532</tt> <tt class="py-line"> <tt class="py-name">meth</tt> <tt class="py-op">=</tt> <tt class="py-name">getattr</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-247" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-244', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L532"></a><tt class="py-lineno"> 532</tt> <tt class="py-line"> <tt class="py-name">result</tt> <tt class="py-op">=</tt> <tt class="py-name">meth</tt><tt class="py-op">(</tt><tt class="py-op">*</tt><tt class="py-name">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-<a name="L533"></a><tt class="py-lineno"> 533</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: this None test is a bit sloppy</tt> </tt>
-<a name="L534"></a><tt class="py-lineno"> 534</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">result</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L535"></a><tt class="py-lineno"> 535</tt> <tt class="py-line"> <tt class="py-comment"># Then return what we got in</tt> </tt>
-<a name="L536"></a><tt class="py-lineno"> 536</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">_transform_result</tt><tt class="py-op">(</tt><tt class="py-name">result_type</tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
-<a name="L537"></a><tt class="py-lineno"> 537</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L538"></a><tt class="py-lineno"> 538</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">result</tt> </tt>
-</div></div><a name="L539"></a><tt class="py-lineno"> 539</tt> <tt class="py-line"> </tt>
-<a name="L540"></a><tt class="py-lineno"> 540</tt> <tt class="py-line"><tt id="link-245" class="py-name" targets="Method lxml.html.HtmlMixin.find_rel_links()=lxml.html.HtmlMixin-class.html#find_rel_links,Variable lxml.html.find_rel_links=lxml.html-module.html#find_rel_links"><a title="lxml.html.HtmlMixin.find_rel_links
-lxml.html.find_rel_links" class="py-name" href="#" onclick="return doclink('link-245', 'find_rel_links', 'link-245');">find_rel_links</a></tt> <tt class="py-op">=</tt> <tt id="link-246" class="py-name" targets="Class lxml.html._MethodFunc=lxml.html._MethodFunc-class.html"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-246', '_MethodFunc', 'link-246');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'find_rel_links'</tt><tt class="py-op">,</tt> <tt id="link-247" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-247', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L533"></a><tt class="py-lineno"> 533</tt> <tt class="py-line"> <tt class="py-name">result</tt> <tt class="py-op">=</tt> <tt class="py-name">meth</tt><tt class="py-op">(</tt><tt class="py-op">*</tt><tt class="py-name">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+<a name="L534"></a><tt class="py-lineno"> 534</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: this None test is a bit sloppy</tt> </tt>
+<a name="L535"></a><tt class="py-lineno"> 535</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">result</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L536"></a><tt class="py-lineno"> 536</tt> <tt class="py-line"> <tt class="py-comment"># Then return what we got in</tt> </tt>
+<a name="L537"></a><tt class="py-lineno"> 537</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">_transform_result</tt><tt class="py-op">(</tt><tt class="py-name">result_type</tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
+<a name="L538"></a><tt class="py-lineno"> 538</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L539"></a><tt class="py-lineno"> 539</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">result</tt> </tt>
+</div></div><a name="L540"></a><tt class="py-lineno"> 540</tt> <tt class="py-line"> </tt>
+<a name="L541"></a><tt class="py-lineno"> 541</tt> <tt class="py-line"><tt id="link-248" class="py-name" targets="Method lxml.html.HtmlMixin.find_rel_links()=lxml.html.HtmlMixin-class.html#find_rel_links,Variable lxml.html.find_rel_links=lxml.html-module.html#find_rel_links"><a title="lxml.html.HtmlMixin.find_rel_links
+lxml.html.find_rel_links" class="py-name" href="#" onclick="return doclink('link-248', 'find_rel_links', 'link-248');">find_rel_links</a></tt> <tt class="py-op">=</tt> <tt id="link-249" class="py-name" targets="Class lxml.html._MethodFunc=lxml.html._MethodFunc-class.html"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-249', '_MethodFunc', 'link-249');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'find_rel_links'</tt><tt class="py-op">,</tt> <tt id="link-250" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-247', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt> </tt>
-<a name="L541"></a><tt class="py-lineno"> 541</tt> <tt class="py-line"><tt id="link-248" class="py-name" targets="Method lxml.html.HtmlMixin.find_class()=lxml.html.HtmlMixin-class.html#find_class,Variable lxml.html.find_class=lxml.html-module.html#find_class"><a title="lxml.html.HtmlMixin.find_class
-lxml.html.find_class" class="py-name" href="#" onclick="return doclink('link-248', 'find_class', 'link-248');">find_class</a></tt> <tt class="py-op">=</tt> <tt id="link-249" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-249', '_MethodFunc', 'link-246');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'find_class'</tt><tt class="py-op">,</tt> <tt id="link-250" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-250', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt> </tt>
+<a name="L542"></a><tt class="py-lineno"> 542</tt> <tt class="py-line"><tt id="link-251" class="py-name" targets="Method lxml.html.HtmlMixin.find_class()=lxml.html.HtmlMixin-class.html#find_class,Variable lxml.html.find_class=lxml.html-module.html#find_class"><a title="lxml.html.HtmlMixin.find_class
+lxml.html.find_class" class="py-name" href="#" onclick="return doclink('link-251', 'find_class', 'link-251');">find_class</a></tt> <tt class="py-op">=</tt> <tt id="link-252" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-252', '_MethodFunc', 'link-249');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'find_class'</tt><tt class="py-op">,</tt> <tt id="link-253" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-250', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt> </tt>
-<a name="L542"></a><tt class="py-lineno"> 542</tt> <tt class="py-line"><tt id="link-251" class="py-name"><a title="lxml.html.HtmlMixin.make_links_absolute
-lxml.html.make_links_absolute" class="py-name" href="#" onclick="return doclink('link-251', 'make_links_absolute', 'link-157');">make_links_absolute</a></tt> <tt class="py-op">=</tt> <tt id="link-252" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-252', '_MethodFunc', 'link-246');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'make_links_absolute'</tt><tt class="py-op">,</tt> <tt id="link-253" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-253', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt> </tt>
+<a name="L543"></a><tt class="py-lineno"> 543</tt> <tt class="py-line"><tt id="link-254" class="py-name"><a title="lxml.html.HtmlMixin.make_links_absolute
+lxml.html.make_links_absolute" class="py-name" href="#" onclick="return doclink('link-254', 'make_links_absolute', 'link-158');">make_links_absolute</a></tt> <tt class="py-op">=</tt> <tt id="link-255" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-255', '_MethodFunc', 'link-249');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'make_links_absolute'</tt><tt class="py-op">,</tt> <tt id="link-256" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-253', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
-<a name="L543"></a><tt class="py-lineno"> 543</tt> <tt class="py-line"><tt id="link-254" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
-lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-254', 'resolve_base_href', 'link-147');">resolve_base_href</a></tt> <tt class="py-op">=</tt> <tt id="link-255" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-255', '_MethodFunc', 'link-246');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'resolve_base_href'</tt><tt class="py-op">,</tt> <tt id="link-256" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-256', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
+<a name="L544"></a><tt class="py-lineno"> 544</tt> <tt class="py-line"><tt id="link-257" class="py-name"><a title="lxml.html.HtmlMixin.resolve_base_href
+lxml.html.resolve_base_href" class="py-name" href="#" onclick="return doclink('link-257', 'resolve_base_href', 'link-148');">resolve_base_href</a></tt> <tt class="py-op">=</tt> <tt id="link-258" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-258', '_MethodFunc', 'link-249');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'resolve_base_href'</tt><tt class="py-op">,</tt> <tt id="link-259" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-256', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
-<a name="L544"></a><tt class="py-lineno"> 544</tt> <tt class="py-line"><tt id="link-257" class="py-name"><a title="lxml.html.HtmlMixin.iterlinks
-lxml.html.iterlinks" class="py-name" href="#" onclick="return doclink('link-257', 'iterlinks', 'link-215');">iterlinks</a></tt> <tt class="py-op">=</tt> <tt id="link-258" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-258', '_MethodFunc', 'link-246');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'iterlinks'</tt><tt class="py-op">,</tt> <tt id="link-259" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-259', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
+<a name="L545"></a><tt class="py-lineno"> 545</tt> <tt class="py-line"><tt id="link-260" class="py-name"><a title="lxml.html.HtmlMixin.iterlinks
+lxml.html.iterlinks" class="py-name" href="#" onclick="return doclink('link-260', 'iterlinks', 'link-218');">iterlinks</a></tt> <tt class="py-op">=</tt> <tt id="link-261" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-261', '_MethodFunc', 'link-249');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'iterlinks'</tt><tt class="py-op">,</tt> <tt id="link-262" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-259', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt> </tt>
-<a name="L545"></a><tt class="py-lineno"> 545</tt> <tt class="py-line"><tt id="link-260" class="py-name"><a title="lxml.html.HtmlMixin.rewrite_links
-lxml.html.rewrite_links" class="py-name" href="#" onclick="return doclink('link-260', 'rewrite_links', 'link-152');">rewrite_links</a></tt> <tt class="py-op">=</tt> <tt id="link-261" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-261', '_MethodFunc', 'link-246');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'rewrite_links'</tt><tt class="py-op">,</tt> <tt id="link-262" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-262', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">)</tt> </tt>
+<a name="L546"></a><tt class="py-lineno"> 546</tt> <tt class="py-line"><tt id="link-263" class="py-name"><a title="lxml.html.HtmlMixin.rewrite_links
+lxml.html.rewrite_links" class="py-name" href="#" onclick="return doclink('link-263', 'rewrite_links', 'link-153');">rewrite_links</a></tt> <tt class="py-op">=</tt> <tt id="link-264" class="py-name"><a title="lxml.html._MethodFunc" class="py-name" href="#" onclick="return doclink('link-264', '_MethodFunc', 'link-249');">_MethodFunc</a></tt><tt class="py-op">(</tt><tt class="py-string">'rewrite_links'</tt><tt class="py-op">,</tt> <tt id="link-265" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-262', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
-<a name="L546"></a><tt class="py-lineno"> 546</tt> <tt class="py-line"> </tt>
-<a name="HtmlComment"></a><div id="HtmlComment-def"><a name="L547"></a><tt class="py-lineno"> 547</tt> <a class="py-toggle" href="#" id="HtmlComment-toggle" onclick="return toggle('HtmlComment');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlComment-class.html">HtmlComment</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">CommentBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlComment-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlComment-expanded"><a name="L548"></a><tt class="py-lineno"> 548</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
-</div><a name="L549"></a><tt class="py-lineno"> 549</tt> <tt class="py-line"> </tt>
-<a name="HtmlElement"></a><div id="HtmlElement-def"><a name="L550"></a><tt class="py-lineno"> 550</tt> <a class="py-toggle" href="#" id="HtmlElement-toggle" onclick="return toggle('HtmlElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlElement-class.html">HtmlElement</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">ElementBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlElement-expanded"><a name="L551"></a><tt class="py-lineno"> 551</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
-</div><a name="L552"></a><tt class="py-lineno"> 552</tt> <tt class="py-line"> </tt>
-<a name="HtmlProcessingInstruction"></a><div id="HtmlProcessingInstruction-def"><a name="L553"></a><tt class="py-lineno"> 553</tt> <a class="py-toggle" href="#" id="HtmlProcessingInstruction-toggle" onclick="return toggle('HtmlProcessingInstruction');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlProcessingInstruction-class.html">HtmlProcessingInstruction</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">PIBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlProcessingInstruction-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlProcessingInstruction-expanded"><a name="L554"></a><tt class="py-lineno"> 554</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
-</div><a name="L555"></a><tt class="py-lineno"> 555</tt> <tt class="py-line"> </tt>
-<a name="HtmlEntity"></a><div id="HtmlEntity-def"><a name="L556"></a><tt class="py-lineno"> 556</tt> <a class="py-toggle" href="#" id="HtmlEntity-toggle" onclick="return toggle('HtmlEntity');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlEntity-class.html">HtmlEntity</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">EntityBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlEntity-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlEntity-expanded"><a name="L557"></a><tt class="py-lineno"> 557</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
-</div><a name="L558"></a><tt class="py-lineno"> 558</tt> <tt class="py-line"> </tt>
-<a name="L559"></a><tt class="py-lineno"> 559</tt> <tt class="py-line"> </tt>
-<a name="HtmlElementClassLookup"></a><div id="HtmlElementClassLookup-def"><a name="L560"></a><tt class="py-lineno"> 560</tt> <a class="py-toggle" href="#" id="HtmlElementClassLookup-toggle" onclick="return toggle('HtmlElementClassLookup');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlElementClassLookup-class.html">HtmlElementClassLookup</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">CustomElementClassLookup</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlElementClassLookup-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlElementClassLookup-expanded"><a name="L561"></a><tt class="py-lineno"> 561</tt> <tt class="py-line"> <tt class="py-docstring">"""A lookup scheme for HTML Element classes.</tt> </tt>
-<a name="L562"></a><tt class="py-lineno"> 562</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L563"></a><tt class="py-lineno"> 563</tt> <tt class="py-line"><tt class="py-docstring"> To create a lookup instance with different Element classes, pass a tag</tt> </tt>
-<a name="L564"></a><tt class="py-lineno"> 564</tt> <tt class="py-line"><tt class="py-docstring"> name mapping of Element classes in the ``classes`` keyword argument and/or</tt> </tt>
-<a name="L565"></a><tt class="py-lineno"> 565</tt> <tt class="py-line"><tt class="py-docstring"> a tag name mapping of Mixin classes in the ``mixins`` keyword argument.</tt> </tt>
-<a name="L566"></a><tt class="py-lineno"> 566</tt> <tt class="py-line"><tt class="py-docstring"> The special key '*' denotes a Mixin class that should be mixed into all</tt> </tt>
-<a name="L567"></a><tt class="py-lineno"> 567</tt> <tt class="py-line"><tt class="py-docstring"> Element classes.</tt> </tt>
-<a name="L568"></a><tt class="py-lineno"> 568</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L569"></a><tt class="py-lineno"> 569</tt> <tt class="py-line"> <tt id="link-263" class="py-name" targets="Variable lxml.html.HtmlElementClassLookup._default_element_classes=lxml.html.HtmlElementClassLookup-class.html#_default_element_classes"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-263', '_default_element_classes', 'link-263');">_default_element_classes</a></tt> <tt class="py-op">=</tt> <tt class="py-op">{</tt><tt class="py-op">}</tt> </tt>
-<a name="L570"></a><tt class="py-lineno"> 570</tt> <tt class="py-line"> </tt>
-<a name="HtmlElementClassLookup.__init__"></a><div id="HtmlElementClassLookup.__init__-def"><a name="L571"></a><tt class="py-lineno"> 571</tt> <a class="py-toggle" href="#" id="HtmlElementClassLookup.__init__-toggle" onclick="return toggle('HtmlElementClassLookup.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlElementClassLookup-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">classes</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">mixins</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlElementClassLookup.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlElementClassLookup.__init__-expanded"><a name="L572"></a><tt class="py-lineno"> 572</tt> <tt class="py-line"> <tt id="link-264" class="py-name"><a title="lxml.etree
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-265', 'copy', 'link-1');">copy</a></tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">)</tt> </tt>
+<a name="L547"></a><tt class="py-lineno"> 547</tt> <tt class="py-line"> </tt>
+<a name="HtmlComment"></a><div id="HtmlComment-def"><a name="L548"></a><tt class="py-lineno"> 548</tt> <a class="py-toggle" href="#" id="HtmlComment-toggle" onclick="return toggle('HtmlComment');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlComment-class.html">HtmlComment</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">CommentBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlComment-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlComment-expanded"><a name="L549"></a><tt class="py-lineno"> 549</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
+</div><a name="L550"></a><tt class="py-lineno"> 550</tt> <tt class="py-line"> </tt>
+<a name="HtmlElement"></a><div id="HtmlElement-def"><a name="L551"></a><tt class="py-lineno"> 551</tt> <a class="py-toggle" href="#" id="HtmlElement-toggle" onclick="return toggle('HtmlElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlElement-class.html">HtmlElement</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">ElementBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlElement-expanded"><a name="L552"></a><tt class="py-lineno"> 552</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
+</div><a name="L553"></a><tt class="py-lineno"> 553</tt> <tt class="py-line"> </tt>
+<a name="HtmlProcessingInstruction"></a><div id="HtmlProcessingInstruction-def"><a name="L554"></a><tt class="py-lineno"> 554</tt> <a class="py-toggle" href="#" id="HtmlProcessingInstruction-toggle" onclick="return toggle('HtmlProcessingInstruction');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlProcessingInstruction-class.html">HtmlProcessingInstruction</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">PIBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlProcessingInstruction-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlProcessingInstruction-expanded"><a name="L555"></a><tt class="py-lineno"> 555</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
+</div><a name="L556"></a><tt class="py-lineno"> 556</tt> <tt class="py-line"> </tt>
+<a name="HtmlEntity"></a><div id="HtmlEntity-def"><a name="L557"></a><tt class="py-lineno"> 557</tt> <a class="py-toggle" href="#" id="HtmlEntity-toggle" onclick="return toggle('HtmlEntity');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlEntity-class.html">HtmlEntity</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">EntityBase</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlEntity-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlEntity-expanded"><a name="L558"></a><tt class="py-lineno"> 558</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
+</div><a name="L559"></a><tt class="py-lineno"> 559</tt> <tt class="py-line"> </tt>
+<a name="L560"></a><tt class="py-lineno"> 560</tt> <tt class="py-line"> </tt>
+<a name="HtmlElementClassLookup"></a><div id="HtmlElementClassLookup-def"><a name="L561"></a><tt class="py-lineno"> 561</tt> <a class="py-toggle" href="#" id="HtmlElementClassLookup-toggle" onclick="return toggle('HtmlElementClassLookup');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HtmlElementClassLookup-class.html">HtmlElementClassLookup</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">CustomElementClassLookup</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlElementClassLookup-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HtmlElementClassLookup-expanded"><a name="L562"></a><tt class="py-lineno"> 562</tt> <tt class="py-line"> <tt class="py-docstring">"""A lookup scheme for HTML Element classes.</tt> </tt>
+<a name="L563"></a><tt class="py-lineno"> 563</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L564"></a><tt class="py-lineno"> 564</tt> <tt class="py-line"><tt class="py-docstring"> To create a lookup instance with different Element classes, pass a tag</tt> </tt>
+<a name="L565"></a><tt class="py-lineno"> 565</tt> <tt class="py-line"><tt class="py-docstring"> name mapping of Element classes in the ``classes`` keyword argument and/or</tt> </tt>
+<a name="L566"></a><tt class="py-lineno"> 566</tt> <tt class="py-line"><tt class="py-docstring"> a tag name mapping of Mixin classes in the ``mixins`` keyword argument.</tt> </tt>
+<a name="L567"></a><tt class="py-lineno"> 567</tt> <tt class="py-line"><tt class="py-docstring"> The special key '*' denotes a Mixin class that should be mixed into all</tt> </tt>
+<a name="L568"></a><tt class="py-lineno"> 568</tt> <tt class="py-line"><tt class="py-docstring"> Element classes.</tt> </tt>
+<a name="L569"></a><tt class="py-lineno"> 569</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L570"></a><tt class="py-lineno"> 570</tt> <tt class="py-line"> <tt id="link-266" class="py-name" targets="Variable lxml.html.HtmlElementClassLookup._default_element_classes=lxml.html.HtmlElementClassLookup-class.html#_default_element_classes"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-266', '_default_element_classes', 'link-266');">_default_element_classes</a></tt> <tt class="py-op">=</tt> <tt class="py-op">{</tt><tt class="py-op">}</tt> </tt>
+<a name="L571"></a><tt class="py-lineno"> 571</tt> <tt class="py-line"> </tt>
+<a name="HtmlElementClassLookup.__init__"></a><div id="HtmlElementClassLookup.__init__-def"><a name="L572"></a><tt class="py-lineno"> 572</tt> <a class="py-toggle" href="#" id="HtmlElementClassLookup.__init__-toggle" onclick="return toggle('HtmlElementClassLookup.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlElementClassLookup-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">classes</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">mixins</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlElementClassLookup.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlElementClassLookup.__init__-expanded"><a name="L573"></a><tt class="py-lineno"> 573</tt> <tt class="py-line"> <tt id="link-267" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-264', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-265" class="py-name" targets="Class lxml.etree.CustomElementClassLookup=lxml.etree.CustomElementClassLookup-class.html"><a title="lxml.etree.CustomElementClassLookup" class="py-name" href="#" onclick="return doclink('link-265', 'CustomElementClassLookup', 'link-265');">CustomElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-266" class="py-name" targets="Method lxml.builder.ElementMaker.__init__()=lxml.builder.ElementMaker-class.html#__init__,Method lxml.cssselect.CSSSelector.__init__()=lxml.cssselect.CSSSelector-class.html#__init__,Method lxml.doctestcompare._RestoreChecker.__init__()=lxml.doctestcompare._RestoreChecker-class.html#__init__,Method lxml.etree.AttributeBasedElementClassLookup.__init__()=lxml.etree.AttributeBasedElementClassLookup-class.html#__init__,Method lxml.etree.CommentBase.__init__()=lxml.etree.CommentBase-class.html#__init__,Method lxml.etree.DTD.__init__()=lxml.etree.DTD-class.html#__init__,Method lxml.etree.ETCompatXMLParser.__init__()=lxml.etree.ETCompatXMLParser-class.html#__init__,Method lxml.etree.ETXPath.__init__()=lxml.etree.ETXPath-class.html#__init__,Method lxml.etree.ElementBase.__init__()=lxml.etree.ElementBase-class.html#__init__,Method lxml.etree.ElementDefaultClassLookup.__init__()=lxml.etree.ElementDefaultClassLookup-class.html#__init__,Method lxml.etree.ElementNamespaceClassLookup.__init__()=lxml.etree.ElementNamespaceClassLookup-class.html#__init__,Method lxml.etree.EntityBase.__init__()=lxml.etree.EntityBase-class.html#__init__,Method lxml.etree.FallbackElementClassLookup.__init__()=lxml.etree.FallbackElementClassLookup-class.html#__init__,Method lxml.etree.HTMLParser.__init__()=lxml.etree.HTMLParser-class.html#__init__,Method lxml.etree.HTMLPullParser.__init__()=lxml.etree.HTMLPullParser-class.html#__init__,Method lxml.etree.LxmlError.__init__()=lxml.etree.LxmlError-class.html#__init__,Method lxml.etree.PIBase.__init__()=lxml.etree.PIBase-class.html#__init__,Method lxml.etree.ParseError.__init__()=lxml.etree.ParseError-class.html#__init__,Method lxml.etree.PyErrorLog.__init__()=lxml.etree.PyErrorLog-class.html#__init__,Method lxml.etree.QName.__init__()=lxml.etree.QName-class.html#__init__,Method lxml.etree.RelaxNG.__init__()=lxml.etree.RelaxNG-class.html#__init__,Method lxml.etree.Schematron.__init__()=lxml.etree.Schematron-class.html#__init__,Method lxml.etree.TreeBuilder.__init__()=lxml.etree.TreeBuilder-class.html#__init__,Method lxml.etree.XInclude.__init__()=lxml.etree.XInclude-class.html#__init__,Method lxml.etree.XMLParser.__init__()=lxml.etree.XMLParser-class.html#__init__,Method lxml.etree.XMLPullParser.__init__()=lxml.etree.XMLPullParser-class.html#__init__,Method lxml.etree.XMLSchema.__init__()=lxml.etree.XMLSchema-class.html#__init__,Method lxml.etree.XPath.__init__()=lxml.etree.XPath-class.html#__init__,Method lxml.etree.XPathDocumentEvaluator.__init__()=lxml.etree.XPathDocumentEvaluator-class.html#__init__,Method lxml.etree.XPathElementEvaluator.__init__()=lxml.etree.XPathElementEvaluator-class.html#__init__,Method lxml.etree.XSLT.__init__()=lxml.etree.XSLT-class.html#__init__,Method lxml.etree.XSLTAccessControl.__init__()=lxml.etree.XSLTAccessControl-class.html#__init__,Method lxml.etree._BaseErrorLog.__init__()=lxml.etree._BaseErrorLog-class.html#__init__,Method lxml.etree._DomainErrorLog.__init__()=lxml.etree._DomainErrorLog-class.html#__init__,Method lxml.etree._ErrorLog.__init__()=lxml.etree._ErrorLog-class.html#__init__,Method lxml.etree._ListErrorLog.__init__()=lxml.etree._ListErrorLog-class.html#__init__,Method lxml.etree._RotatingErrorLog.__init__()=lxml.etree._RotatingErrorLog-class.html#__init__,Method lxml.etree._TargetParserResult.__init__()=lxml.etree._TargetParserResult-class.html#__init__,Method lxml.etree._XPathEvaluatorBase.__init__()=lxml.etree._XPathEvaluatorBase-class.html#__init__,Method lxml.etree.htmlfile.__init__()=lxml.etree.htmlfile-class.html#__init__,Method lxml.etree.iterparse.__init__()=lxml.etree.iterparse-class.html#__init__,Method lxml.etree.iterwalk.__init__()=lxml.etree.iterwalk-class.html#__init__,Method lxml.etree.xmlfile.__init__()=lxml.etree.xmlfile-class.html#__init__,Method lxml.html.CheckboxValues.__init__()=lxml.html.CheckboxValues-class.html#__init__,Method lxml.html.FieldsDict.__init__()=lxml.html.FieldsDict-class.html#__init__,Method lxml.html.HTMLParser.__init__()=lxml.html.HTMLParser-class.html#__init__,Method lxml.html.HtmlElementClassLookup.__init__()=lxml.html.HtmlElementClassLookup-class.html#__init__,Method lxml.html.InputGetter.__init__()=lxml.html.InputGetter-class.html#__init__,Method lxml.html.MultipleSelectOptions.__init__()=lxml.html.MultipleSelectOptions-class.html#__init__,Method lxml.html.XHTMLParser.__init__()=lxml.html.XHTMLParser-class.html#__init__,Method lxml.html._MethodFunc.__init__()=lxml.html._MethodFunc-class.html#__init__,Method lxml.html.clean.Cleaner.__init__()=lxml.html.clean.Cleaner-class.html#__init__,Method lxml.html.formfill.DefaultErrorCreator.__init__()=lxml.html.formfill.DefaultErrorCreator-class.html#__init__,Method lxml.html.html5parser.HTMLParser.__init__()=lxml.html.html5parser.HTMLParser-class.html#__init__,Method lxml.html.html5parser.XHTMLParser.__init__()=lxml.html.html5parser.XHTMLParser-class.html#__init__,Method lxml.isoschematron.Schematron.__init__()=lxml.isoschematron.Schematron-class.html#__init__,Method lxml.objectify.ElementMaker.__init__()=lxml.objectify.ElementMaker-class.html#__init__,Method lxml.objectify.ObjectPath.__init__()=lxml.objectify.ObjectPath-class.html#__init__,Method lxml.objectify.ObjectifyElementClassLookup.__init__()=lxml.objectify.ObjectifyElementClassLookup-class.html#__init__,Method lxml.objectify.PyType.__init__()=lxml.objectify.PyType-class.html#__init__,Method lxml.sax.ElementTreeContentHandler.__init__()=lxml.sax.ElementTreeContentHandler-class.html#__init__,Method lxml.sax.ElementTreeProducer.__init__()=lxml.sax.ElementTreeProducer-class.html#__init__,Method lxml.tests.common_imports.LargeFileLike.__init__()=lxml.tests.common_imports.LargeFileLike-class.html#__init__,Method lxml.tests.common_imports.LargeFileLikeUnicode.__init__()=lxml.tests.common_imports.LargeFileLikeUnicode-class.html#__init__,Method lxml.tests.common_imports.SillyFileLike.__init__()=lxml.tests.common_imports.SillyFileLike-class.html#__init__,Method lxml.tests.dummy_http_server.HTTPRequestCollector.__init__()=lxml.tests.dummy_http_server.HTTPRequestCollector-class.html#__init__,Method lxml.tests.test_doctestcompare.DummyInput.__init__()=lxml.tests.test_doctestcompare.DummyInput-class.html#__init__,Method lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.__init__()=lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike-class.html#__init__,Method lxml.tests.test_threading.ThreadPipelineTestCase.Worker.__init__()=lxml.tests.test_threading.ThreadPipelineTestCase.Worker-class.html#__init__,Method lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__()=lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver-class.html#__init__"><a title="lxml.builder.ElementMaker.__init__
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-267', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-268" class="py-name" targets="Class lxml.etree.CustomElementClassLookup=lxml.etree.CustomElementClassLookup-class.html"><a title="lxml.etree.CustomElementClassLookup" class="py-name" href="#" onclick="return doclink('link-268', 'CustomElementClassLookup', 'link-268');">CustomElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-269" class="py-name" targets="Method lxml.builder.ElementMaker.__init__()=lxml.builder.ElementMaker-class.html#__init__,Method lxml.cssselect.CSSSelector.__init__()=lxml.cssselect.CSSSelector-class.html#__init__,Method lxml.doctestcompare._RestoreChecker.__init__()=lxml.doctestcompare._RestoreChecker-class.html#__init__,Method lxml.etree.AttributeBasedElementClassLookup.__init__()=lxml.etree.AttributeBasedElementClassLookup-class.html#__init__,Method lxml.etree.CommentBase.__init__()=lxml.etree.CommentBase-class.html#__init__,Method lxml.etree.DTD.__init__()=lxml.etree.DTD-class.html#__init__,Method lxml.etree.ETCompatXMLParser.__init__()=lxml.etree.ETCompatXMLParser-class.html#__init__,Method lxml.etree.ETXPath.__init__()=lxml.etree.ETXPath-class.html#__init__,Method lxml.etree.ElementBase.__init__()=lxml.etree.ElementBase-class.html#__init__,Method lxml.etree.ElementDefaultClassLookup.__init__()=lxml.etree.ElementDefaultClassLookup-class.html#__init__,Method lxml.etree.ElementNamespaceClassLookup.__init__()=lxml.etree.ElementNamespaceClassLookup-class.html#__init__,Method lxml.etree.EntityBase.__init__()=lxml.etree.EntityBase-class.html#__init__,Method lxml.etree.FallbackElementClassLookup.__init__()=lxml.etree.FallbackElementClassLookup-class.html#__init__,Method lxml.etree.HTMLParser.__init__()=lxml.etree.HTMLParser-class.html#__init__,Method lxml.etree.HTMLPullParser.__init__()=lxml.etree.HTMLPullParser-class.html#__init__,Method lxml.etree.LxmlError.__init__()=lxml.etree.LxmlError-class.html#__init__,Method lxml.etree.PIBase.__init__()=lxml.etree.PIBase-class.html#__init__,Method lxml.etree.ParseError.__init__()=lxml.etree.ParseError-class.html#__init__,Method lxml.etree.PyErrorLog.__init__()=lxml.etree.PyErrorLog-class.html#__init__,Method lxml.etree.QName.__init__()=lxml.etree.QName-class.html#__init__,Method lxml.etree.RelaxNG.__init__()=lxml.etree.RelaxNG-class.html#__init__,Method lxml.etree.Schematron.__init__()=lxml.etree.Schematron-class.html#__init__,Method lxml.etree.TreeBuilder.__init__()=lxml.etree.TreeBuilder-class.html#__init__,Method lxml.etree.XInclude.__init__()=lxml.etree.XInclude-class.html#__init__,Method lxml.etree.XMLParser.__init__()=lxml.etree.XMLParser-class.html#__init__,Method lxml.etree.XMLPullParser.__init__()=lxml.etree.XMLPullParser-class.html#__init__,Method lxml.etree.XMLSchema.__init__()=lxml.etree.XMLSchema-class.html#__init__,Method lxml.etree.XPath.__init__()=lxml.etree.XPath-class.html#__init__,Method lxml.etree.XPathDocumentEvaluator.__init__()=lxml.etree.XPathDocumentEvaluator-class.html#__init__,Method lxml.etree.XPathElementEvaluator.__init__()=lxml.etree.XPathElementEvaluator-class.html#__init__,Method lxml.etree.XSLT.__init__()=lxml.etree.XSLT-class.html#__init__,Method lxml.etree.XSLTAccessControl.__init__()=lxml.etree.XSLTAccessControl-class.html#__init__,Method lxml.etree._BaseErrorLog.__init__()=lxml.etree._BaseErrorLog-class.html#__init__,Method lxml.etree._DomainErrorLog.__init__()=lxml.etree._DomainErrorLog-class.html#__init__,Method lxml.etree._ErrorLog.__init__()=lxml.etree._ErrorLog-class.html#__init__,Method lxml.etree._ListErrorLog.__init__()=lxml.etree._ListErrorLog-class.html#__init__,Method lxml.etree._RotatingErrorLog.__init__()=lxml.etree._RotatingErrorLog-class.html#__init__,Method lxml.etree._TargetParserResult.__init__()=lxml.etree._TargetParserResult-class.html#__init__,Method lxml.etree._XPathEvaluatorBase.__init__()=lxml.etree._XPathEvaluatorBase-class.html#__init__,Method lxml.etree.htmlfile.__init__()=lxml.etree.htmlfile-class.html#__init__,Method lxml.etree.iterparse.__init__()=lxml.etree.iterparse-class.html#__init__,Method lxml.etree.iterwalk.__init__()=lxml.etree.iterwalk-class.html#__init__,Method lxml.etree.xmlfile.__init__()=lxml.etree.xmlfile-class.html#__init__,Method lxml.html.CheckboxValues.__init__()=lxml.html.CheckboxValues-class.html#__init__,Method lxml.html.FieldsDict.__init__()=lxml.html.FieldsDict-class.html#__init__,Method lxml.html.HTMLParser.__init__()=lxml.html.HTMLParser-class.html#__init__,Method lxml.html.HtmlElementClassLookup.__init__()=lxml.html.HtmlElementClassLookup-class.html#__init__,Method lxml.html.InputGetter.__init__()=lxml.html.InputGetter-class.html#__init__,Method lxml.html.MultipleSelectOptions.__init__()=lxml.html.MultipleSelectOptions-class.html#__init__,Method lxml.html.XHTMLParser.__init__()=lxml.html.XHTMLParser-class.html#__init__,Method lxml.html._MethodFunc.__init__()=lxml.html._MethodFunc-class.html#__init__,Method lxml.html.clean.Cleaner.__init__()=lxml.html.clean.Cleaner-class.html#__init__,Method lxml.html.formfill.DefaultErrorCreator.__init__()=lxml.html.formfill.DefaultErrorCreator-class.html#__init__,Method lxml.html.html5parser.HTMLParser.__init__()=lxml.html.html5parser.HTMLParser-class.html#__init__,Method lxml.html.html5parser.XHTMLParser.__init__()=lxml.html.html5parser.XHTMLParser-class.html#__init__,Method lxml.isoschematron.Schematron.__init__()=lxml.isoschematron.Schematron-class.html#__init__,Method lxml.objectify.ElementMaker.__init__()=lxml.objectify.ElementMaker-class.html#__init__,Method lxml.objectify.ObjectPath.__init__()=lxml.objectify.ObjectPath-class.html#__init__,Method lxml.objectify.ObjectifyElementClassLookup.__init__()=lxml.objectify.ObjectifyElementClassLookup-class.html#__init__,Method lxml.objectify.PyType.__init__()=lxml.objectify.PyType-class.html#__init__,Method lxml.sax.ElementTreeContentHandler.__init__()=lxml.sax.ElementTreeContentHandler-class.html#__init__,Method lxml.sax.ElementTreeProducer.__init__()=lxml.sax.ElementTreeProducer-class.html#__init__,Method lxml.tests.common_imports.LargeFileLike.__init__()=lxml.tests.common_imports.LargeFileLike-class.html#__init__,Method lxml.tests.common_imports.LargeFileLikeUnicode.__init__()=lxml.tests.common_imports.LargeFileLikeUnicode-class.html#__init__,Method lxml.tests.common_imports.SillyFileLike.__init__()=lxml.tests.common_imports.SillyFileLike-class.html#__init__,Method lxml.tests.dummy_http_server.HTTPRequestCollector.__init__()=lxml.tests.dummy_http_server.HTTPRequestCollector-class.html#__init__,Method lxml.tests.test_doctestcompare.DummyInput.__init__()=lxml.tests.test_doctestcompare.DummyInput-class.html#__init__,Method lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.__init__()=lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike-class.html#__init__,Method lxml.tests.test_threading.ThreadPipelineTestCase.Worker.__init__()=lxml.tests.test_threading.ThreadPipelineTestCase.Worker-class.html#__init__,Method lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__()=lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver-class.html#__init__"><a title="lxml.builder.ElementMaker.__init__
lxml.cssselect.CSSSelector.__init__
lxml.doctestcompare._RestoreChecker.__init__
lxml.etree.AttributeBasedElementClassLookup.__init__
lxml.tests.test_doctestcompare.DummyInput.__init__
lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.__init__
lxml.tests.test_threading.ThreadPipelineTestCase.Worker.__init__
-lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__" class="py-name" href="#" onclick="return doclink('link-266', '__init__', 'link-266');">__init__</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-<a name="L573"></a><tt class="py-lineno"> 573</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">classes</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L574"></a><tt class="py-lineno"> 574</tt> <tt class="py-line"> <tt class="py-name">classes</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-267" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-267', '_default_element_classes', 'link-263');">_default_element_classes</a></tt><tt class="py-op">.</tt><tt id="link-268" class="py-name"><a title="lxml.etree.PyErrorLog.copy
+lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__" class="py-name" href="#" onclick="return doclink('link-269', '__init__', 'link-269');">__init__</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+<a name="L574"></a><tt class="py-lineno"> 574</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">classes</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L575"></a><tt class="py-lineno"> 575</tt> <tt class="py-line"> <tt class="py-name">classes</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-270" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-270', '_default_element_classes', 'link-266');">_default_element_classes</a></tt><tt class="py-op">.</tt><tt id="link-271" class="py-name"><a title="lxml.etree.PyErrorLog.copy
lxml.etree._BaseErrorLog.copy
lxml.etree._ErrorLog.copy
lxml.etree._IDDict.copy
-lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-268', 'copy', 'link-1');">copy</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L575"></a><tt class="py-lineno"> 575</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">mixins</tt><tt class="py-op">:</tt> </tt>
-<a name="L576"></a><tt class="py-lineno"> 576</tt> <tt class="py-line"> <tt class="py-name">mixers</tt> <tt class="py-op">=</tt> <tt class="py-op">{</tt><tt class="py-op">}</tt> </tt>
-<a name="L577"></a><tt class="py-lineno"> 577</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-269" class="py-name"><a title="lxml.etree.DTD.name
+lxml.etree._ListErrorLog.copy" class="py-name" href="#" onclick="return doclink('link-271', 'copy', 'link-1');">copy</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L576"></a><tt class="py-lineno"> 576</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">mixins</tt><tt class="py-op">:</tt> </tt>
+<a name="L577"></a><tt class="py-lineno"> 577</tt> <tt class="py-line"> <tt class="py-name">mixers</tt> <tt class="py-op">=</tt> <tt class="py-op">{</tt><tt class="py-op">}</tt> </tt>
+<a name="L578"></a><tt class="py-lineno"> 578</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-272" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-269', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt id="link-270" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-272', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt id="link-273" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-270', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">mixins</tt><tt class="py-op">:</tt> </tt>
-<a name="L578"></a><tt class="py-lineno"> 578</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-271" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-273', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">mixins</tt><tt class="py-op">:</tt> </tt>
+<a name="L579"></a><tt class="py-lineno"> 579</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-274" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-271', 'name', 'link-230');">name</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'*'</tt><tt class="py-op">:</tt> </tt>
-<a name="L579"></a><tt class="py-lineno"> 579</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">n</tt> <tt class="py-keyword">in</tt> <tt class="py-name">classes</tt><tt class="py-op">.</tt><tt id="link-272" class="py-name" targets="Method lxml.etree._Attrib.keys()=lxml.etree._Attrib-class.html#keys,Method lxml.etree._Element.keys()=lxml.etree._Element-class.html#keys,Method lxml.etree._IDDict.keys()=lxml.etree._IDDict-class.html#keys,Method lxml.html.FieldsDict.keys()=lxml.html.FieldsDict-class.html#keys,Method lxml.html.InputGetter.keys()=lxml.html.InputGetter-class.html#keys"><a title="lxml.etree._Attrib.keys
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-274', 'name', 'link-233');">name</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'*'</tt><tt class="py-op">:</tt> </tt>
+<a name="L580"></a><tt class="py-lineno"> 580</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">n</tt> <tt class="py-keyword">in</tt> <tt class="py-name">classes</tt><tt class="py-op">.</tt><tt id="link-275" class="py-name" targets="Method lxml.etree._Attrib.keys()=lxml.etree._Attrib-class.html#keys,Method lxml.etree._Element.keys()=lxml.etree._Element-class.html#keys,Method lxml.etree._IDDict.keys()=lxml.etree._IDDict-class.html#keys,Method lxml.html.FieldsDict.keys()=lxml.html.FieldsDict-class.html#keys,Method lxml.html.InputGetter.keys()=lxml.html.InputGetter-class.html#keys"><a title="lxml.etree._Attrib.keys
lxml.etree._Element.keys
lxml.etree._IDDict.keys
lxml.html.FieldsDict.keys
-lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-272', 'keys', 'link-272');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L580"></a><tt class="py-lineno"> 580</tt> <tt class="py-line"> <tt class="py-name">mixers</tt><tt class="py-op">.</tt><tt class="py-name">setdefault</tt><tt class="py-op">(</tt><tt class="py-name">n</tt><tt class="py-op">,</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-273" class="py-name" targets="Method lxml.etree._Element.append()=lxml.etree._Element-class.html#append"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-273', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt id="link-274" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-275', 'keys', 'link-275');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L581"></a><tt class="py-lineno"> 581</tt> <tt class="py-line"> <tt class="py-name">mixers</tt><tt class="py-op">.</tt><tt class="py-name">setdefault</tt><tt class="py-op">(</tt><tt class="py-name">n</tt><tt class="py-op">,</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-276" class="py-name" targets="Method lxml.etree._Element.append()=lxml.etree._Element-class.html#append"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-276', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt id="link-277" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-274', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L581"></a><tt class="py-lineno"> 581</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L582"></a><tt class="py-lineno"> 582</tt> <tt class="py-line"> <tt class="py-name">mixers</tt><tt class="py-op">.</tt><tt class="py-name">setdefault</tt><tt class="py-op">(</tt><tt id="link-275" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-277', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L582"></a><tt class="py-lineno"> 582</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L583"></a><tt class="py-lineno"> 583</tt> <tt class="py-line"> <tt class="py-name">mixers</tt><tt class="py-op">.</tt><tt class="py-name">setdefault</tt><tt class="py-op">(</tt><tt id="link-278" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-275', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-276" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-276', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt id="link-277" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-278', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-279" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-279', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt id="link-280" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-277', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L583"></a><tt class="py-lineno"> 583</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-278" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-280', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L584"></a><tt class="py-lineno"> 584</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-281" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-278', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">mix_bases</tt> <tt class="py-keyword">in</tt> <tt class="py-name">mixers</tt><tt class="py-op">.</tt><tt id="link-279" class="py-name" targets="Method lxml.etree._Attrib.items()=lxml.etree._Attrib-class.html#items,Method lxml.etree._Element.items()=lxml.etree._Element-class.html#items,Method lxml.etree._IDDict.items()=lxml.etree._IDDict-class.html#items"><a title="lxml.etree._Attrib.items
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-281', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">mix_bases</tt> <tt class="py-keyword">in</tt> <tt class="py-name">mixers</tt><tt class="py-op">.</tt><tt id="link-282" class="py-name" targets="Method lxml.etree._Attrib.items()=lxml.etree._Attrib-class.html#items,Method lxml.etree._Element.items()=lxml.etree._Element-class.html#items,Method lxml.etree._IDDict.items()=lxml.etree._IDDict-class.html#items"><a title="lxml.etree._Attrib.items
lxml.etree._Element.items
-lxml.etree._IDDict.items" class="py-name" href="#" onclick="return doclink('link-279', 'items', 'link-279');">items</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L584"></a><tt class="py-lineno"> 584</tt> <tt class="py-line"> <tt class="py-name">cur</tt> <tt class="py-op">=</tt> <tt class="py-name">classes</tt><tt class="py-op">.</tt><tt id="link-280" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._IDDict.items" class="py-name" href="#" onclick="return doclink('link-282', 'items', 'link-282');">items</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L585"></a><tt class="py-lineno"> 585</tt> <tt class="py-line"> <tt class="py-name">cur</tt> <tt class="py-op">=</tt> <tt class="py-name">classes</tt><tt class="py-op">.</tt><tt id="link-283" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-280', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt id="link-281" class="py-name"><a title="lxml.etree.DTD.name
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-283', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt id="link-284" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-281', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt id="link-282" class="py-name" targets="Class lxml.html.HtmlElement=lxml.html.HtmlElement-class.html"><a title="lxml.html.HtmlElement" class="py-name" href="#" onclick="return doclink('link-282', 'HtmlElement', 'link-282');">HtmlElement</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L585"></a><tt class="py-lineno"> 585</tt> <tt class="py-line"> <tt class="py-name">bases</tt> <tt class="py-op">=</tt> <tt class="py-name">tuple</tt><tt class="py-op">(</tt><tt class="py-name">mix_bases</tt> <tt class="py-op">+</tt> <tt class="py-op">[</tt><tt class="py-name">cur</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt>
-<a name="L586"></a><tt class="py-lineno"> 586</tt> <tt class="py-line"> <tt class="py-name">classes</tt><tt class="py-op">[</tt><tt id="link-283" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-284', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt id="link-285" class="py-name" targets="Class lxml.html.HtmlElement=lxml.html.HtmlElement-class.html"><a title="lxml.html.HtmlElement" class="py-name" href="#" onclick="return doclink('link-285', 'HtmlElement', 'link-285');">HtmlElement</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L586"></a><tt class="py-lineno"> 586</tt> <tt class="py-line"> <tt class="py-name">bases</tt> <tt class="py-op">=</tt> <tt class="py-name">tuple</tt><tt class="py-op">(</tt><tt class="py-name">mix_bases</tt> <tt class="py-op">+</tt> <tt class="py-op">[</tt><tt class="py-name">cur</tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt>
+<a name="L587"></a><tt class="py-lineno"> 587</tt> <tt class="py-line"> <tt class="py-name">classes</tt><tt class="py-op">[</tt><tt id="link-286" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-283', 'name', 'link-230');">name</a></tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-284" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-284', 'type', 'link-237');">type</a></tt><tt class="py-op">(</tt><tt class="py-name">cur</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> <tt class="py-name">bases</tt><tt class="py-op">,</tt> <tt class="py-op">{</tt><tt class="py-op">}</tt><tt class="py-op">)</tt> </tt>
-<a name="L587"></a><tt class="py-lineno"> 587</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_element_classes</tt> <tt class="py-op">=</tt> <tt class="py-name">classes</tt> </tt>
-</div><a name="L588"></a><tt class="py-lineno"> 588</tt> <tt class="py-line"> </tt>
-<a name="HtmlElementClassLookup.lookup"></a><div id="HtmlElementClassLookup.lookup-def"><a name="L589"></a><tt class="py-lineno"> 589</tt> <a class="py-toggle" href="#" id="HtmlElementClassLookup.lookup-toggle" onclick="return toggle('HtmlElementClassLookup.lookup');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlElementClassLookup-class.html#lookup">lookup</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">node_type</tt><tt class="py-op">,</tt> <tt class="py-param">document</tt><tt class="py-op">,</tt> <tt class="py-param">namespace</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HtmlElementClassLookup.lookup-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlElementClassLookup.lookup-expanded"><a name="L590"></a><tt class="py-lineno"> 590</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'element'</tt><tt class="py-op">:</tt> </tt>
-<a name="L591"></a><tt class="py-lineno"> 591</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_element_classes</tt><tt class="py-op">.</tt><tt id="link-285" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-286', 'name', 'link-233');">name</a></tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-287" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-287', 'type', 'link-240');">type</a></tt><tt class="py-op">(</tt><tt class="py-name">cur</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> <tt class="py-name">bases</tt><tt class="py-op">,</tt> <tt class="py-op">{</tt><tt class="py-op">}</tt><tt class="py-op">)</tt> </tt>
+<a name="L588"></a><tt class="py-lineno"> 588</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_element_classes</tt> <tt class="py-op">=</tt> <tt class="py-name">classes</tt> </tt>
+</div><a name="L589"></a><tt class="py-lineno"> 589</tt> <tt class="py-line"> </tt>
+<a name="HtmlElementClassLookup.lookup"></a><div id="HtmlElementClassLookup.lookup-def"><a name="L590"></a><tt class="py-lineno"> 590</tt> <a class="py-toggle" href="#" id="HtmlElementClassLookup.lookup-toggle" onclick="return toggle('HtmlElementClassLookup.lookup');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HtmlElementClassLookup-class.html#lookup">lookup</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">node_type</tt><tt class="py-op">,</tt> <tt class="py-param">document</tt><tt class="py-op">,</tt> <tt class="py-param">namespace</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HtmlElementClassLookup.lookup-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HtmlElementClassLookup.lookup-expanded"><a name="L591"></a><tt class="py-lineno"> 591</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'element'</tt><tt class="py-op">:</tt> </tt>
+<a name="L592"></a><tt class="py-lineno"> 592</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">_element_classes</tt><tt class="py-op">.</tt><tt id="link-288" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-285', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt id="link-286" class="py-name"><a title="lxml.etree.DTD.name
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-288', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt id="link-289" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-286', 'name', 'link-230');">name</a></tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt id="link-287" class="py-name"><a title="lxml.html.HtmlElement" class="py-name" href="#" onclick="return doclink('link-287', 'HtmlElement', 'link-282');">HtmlElement</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L592"></a><tt class="py-lineno"> 592</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'comment'</tt><tt class="py-op">:</tt> </tt>
-<a name="L593"></a><tt class="py-lineno"> 593</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-288" class="py-name" targets="Class lxml.html.HtmlComment=lxml.html.HtmlComment-class.html"><a title="lxml.html.HtmlComment" class="py-name" href="#" onclick="return doclink('link-288', 'HtmlComment', 'link-288');">HtmlComment</a></tt> </tt>
-<a name="L594"></a><tt class="py-lineno"> 594</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'PI'</tt><tt class="py-op">:</tt> </tt>
-<a name="L595"></a><tt class="py-lineno"> 595</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-289" class="py-name" targets="Class lxml.html.HtmlProcessingInstruction=lxml.html.HtmlProcessingInstruction-class.html"><a title="lxml.html.HtmlProcessingInstruction" class="py-name" href="#" onclick="return doclink('link-289', 'HtmlProcessingInstruction', 'link-289');">HtmlProcessingInstruction</a></tt> </tt>
-<a name="L596"></a><tt class="py-lineno"> 596</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'entity'</tt><tt class="py-op">:</tt> </tt>
-<a name="L597"></a><tt class="py-lineno"> 597</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-290" class="py-name" targets="Class lxml.html.HtmlEntity=lxml.html.HtmlEntity-class.html"><a title="lxml.html.HtmlEntity" class="py-name" href="#" onclick="return doclink('link-290', 'HtmlEntity', 'link-290');">HtmlEntity</a></tt> </tt>
-<a name="L598"></a><tt class="py-lineno"> 598</tt> <tt class="py-line"> <tt class="py-comment"># Otherwise normal lookup</tt> </tt>
-<a name="L599"></a><tt class="py-lineno"> 599</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-</div></div><a name="L600"></a><tt class="py-lineno"> 600</tt> <tt class="py-line"> </tt>
-<a name="L601"></a><tt class="py-lineno"> 601</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
-<a name="L602"></a><tt class="py-lineno"> 602</tt> <tt class="py-line"><tt class="py-comment"># parsing</tt> </tt>
-<a name="L603"></a><tt class="py-lineno"> 603</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
-<a name="L604"></a><tt class="py-lineno"> 604</tt> <tt class="py-line"> </tt>
-<a name="L605"></a><tt class="py-lineno"> 605</tt> <tt class="py-line"><tt class="py-name">_looks_like_full_html_unicode</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
-<a name="L606"></a><tt class="py-lineno"> 606</tt> <tt class="py-line"> <tt class="py-name">unicode</tt><tt class="py-op">(</tt><tt class="py-string">r'^\s*<(?:html|!doctype)'</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt id="link-291" class="py-name"><a title="lxml.html.builder.I" class="py-name" href="#" onclick="return doclink('link-291', 'I', 'link-38');">I</a></tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">match</tt> </tt>
-<a name="L607"></a><tt class="py-lineno"> 607</tt> <tt class="py-line"><tt class="py-name">_looks_like_full_html_bytes</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
-<a name="L608"></a><tt class="py-lineno"> 608</tt> <tt class="py-line"> <tt class="py-string">r'^\s*<(?:html|!doctype)'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ascii'</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt id="link-292" class="py-name"><a title="lxml.html.builder.I" class="py-name" href="#" onclick="return doclink('link-292', 'I', 'link-38');">I</a></tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">match</tt> </tt>
-<a name="L609"></a><tt class="py-lineno"> 609</tt> <tt class="py-line"> </tt>
-<a name="document_fromstring"></a><div id="document_fromstring-def"><a name="L610"></a><tt class="py-lineno"> 610</tt> <a class="py-toggle" href="#" id="document_fromstring-toggle" onclick="return toggle('document_fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#document_fromstring">document_fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">ensure_head_body</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="document_fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="document_fromstring-expanded"><a name="L611"></a><tt class="py-lineno"> 611</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-293" class="py-name" targets="Variable lxml.etree._ElementTree.parser=lxml.etree._ElementTree-class.html#parser,Variable lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser=lxml.tests.test_pyclasslookup.PyClassLookupTestCase-class.html#parser"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-293', 'parser', 'link-293');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L612"></a><tt class="py-lineno"> 612</tt> <tt class="py-line"> <tt id="link-294" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-294', 'parser', 'link-293');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-295" class="py-name" targets="Variable lxml.html.html5parser.html_parser=lxml.html.html5parser-module.html#html_parser,Variable lxml.html.html_parser=lxml.html-module.html#html_parser"><a title="lxml.html.html5parser.html_parser
-lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-295', 'html_parser', 'link-295');">html_parser</a></tt> </tt>
-<a name="L613"></a><tt class="py-lineno"> 613</tt> <tt class="py-line"> <tt id="link-296" class="py-name"><a title="lxml.html.CheckboxGroup.value
-lxml.html.InputElement.value
-lxml.html.RadioGroup.value
-lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-296', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-297" class="py-name"><a title="lxml.etree
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-289', 'name', 'link-233');">name</a></tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt id="link-290" class="py-name"><a title="lxml.html.HtmlElement" class="py-name" href="#" onclick="return doclink('link-290', 'HtmlElement', 'link-285');">HtmlElement</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L593"></a><tt class="py-lineno"> 593</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'comment'</tt><tt class="py-op">:</tt> </tt>
+<a name="L594"></a><tt class="py-lineno"> 594</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-291" class="py-name" targets="Class lxml.html.HtmlComment=lxml.html.HtmlComment-class.html"><a title="lxml.html.HtmlComment" class="py-name" href="#" onclick="return doclink('link-291', 'HtmlComment', 'link-291');">HtmlComment</a></tt> </tt>
+<a name="L595"></a><tt class="py-lineno"> 595</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'PI'</tt><tt class="py-op">:</tt> </tt>
+<a name="L596"></a><tt class="py-lineno"> 596</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-292" class="py-name" targets="Class lxml.html.HtmlProcessingInstruction=lxml.html.HtmlProcessingInstruction-class.html"><a title="lxml.html.HtmlProcessingInstruction" class="py-name" href="#" onclick="return doclink('link-292', 'HtmlProcessingInstruction', 'link-292');">HtmlProcessingInstruction</a></tt> </tt>
+<a name="L597"></a><tt class="py-lineno"> 597</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">node_type</tt> <tt class="py-op">==</tt> <tt class="py-string">'entity'</tt><tt class="py-op">:</tt> </tt>
+<a name="L598"></a><tt class="py-lineno"> 598</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-293" class="py-name" targets="Class lxml.html.HtmlEntity=lxml.html.HtmlEntity-class.html"><a title="lxml.html.HtmlEntity" class="py-name" href="#" onclick="return doclink('link-293', 'HtmlEntity', 'link-293');">HtmlEntity</a></tt> </tt>
+<a name="L599"></a><tt class="py-lineno"> 599</tt> <tt class="py-line"> <tt class="py-comment"># Otherwise normal lookup</tt> </tt>
+<a name="L600"></a><tt class="py-lineno"> 600</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
+</div></div><a name="L601"></a><tt class="py-lineno"> 601</tt> <tt class="py-line"> </tt>
+<a name="L602"></a><tt class="py-lineno"> 602</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
+<a name="L603"></a><tt class="py-lineno"> 603</tt> <tt class="py-line"><tt class="py-comment"># parsing</tt> </tt>
+<a name="L604"></a><tt class="py-lineno"> 604</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
+<a name="L605"></a><tt class="py-lineno"> 605</tt> <tt class="py-line"> </tt>
+<a name="L606"></a><tt class="py-lineno"> 606</tt> <tt class="py-line"><tt class="py-name">_looks_like_full_html_unicode</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
+<a name="L607"></a><tt class="py-lineno"> 607</tt> <tt class="py-line"> <tt class="py-name">unicode</tt><tt class="py-op">(</tt><tt class="py-string">r'^\s*<(?:html|!doctype)'</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt id="link-294" class="py-name"><a title="lxml.html.builder.I" class="py-name" href="#" onclick="return doclink('link-294', 'I', 'link-38');">I</a></tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">match</tt> </tt>
+<a name="L608"></a><tt class="py-lineno"> 608</tt> <tt class="py-line"><tt class="py-name">_looks_like_full_html_bytes</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
+<a name="L609"></a><tt class="py-lineno"> 609</tt> <tt class="py-line"> <tt class="py-string">r'^\s*<(?:html|!doctype)'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ascii'</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt id="link-295" class="py-name"><a title="lxml.html.builder.I" class="py-name" href="#" onclick="return doclink('link-295', 'I', 'link-38');">I</a></tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">match</tt> </tt>
+<a name="L610"></a><tt class="py-lineno"> 610</tt> <tt class="py-line"> </tt>
+<a name="document_fromstring"></a><div id="document_fromstring-def"><a name="L611"></a><tt class="py-lineno"> 611</tt> <a class="py-toggle" href="#" id="document_fromstring-toggle" onclick="return toggle('document_fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#document_fromstring">document_fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">ensure_head_body</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="document_fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="document_fromstring-expanded"><a name="L612"></a><tt class="py-lineno"> 612</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-296" class="py-name" targets="Variable lxml.etree._ElementTree.parser=lxml.etree._ElementTree-class.html#parser,Variable lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser=lxml.tests.test_pyclasslookup.PyClassLookupTestCase-class.html#parser"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-296', 'parser', 'link-296');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L613"></a><tt class="py-lineno"> 613</tt> <tt class="py-line"> <tt id="link-297" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-297', 'parser', 'link-296');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-298" class="py-name" targets="Variable lxml.html.html5parser.html_parser=lxml.html.html5parser-module.html#html_parser,Variable lxml.html.html_parser=lxml.html-module.html#html_parser"><a title="lxml.html.html5parser.html_parser
+lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-298', 'html_parser', 'link-298');">html_parser</a></tt> </tt>
+<a name="L614"></a><tt class="py-lineno"> 614</tt> <tt class="py-line"> <tt id="link-299" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputElement.value
+lxml.html.RadioGroup.value
+lxml.html.SelectElement.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-299', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-300" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-297', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-298" class="py-name"><a title="lxml.etree.fromstring
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-300', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-301" class="py-name"><a title="lxml.etree.fromstring
lxml.html.html5parser.fromstring
lxml.html.soupparser.fromstring
-lxml.objectify.fromstring" class="py-name" href="#" onclick="return doclink('link-298', 'fromstring', 'link-240');">fromstring</a></tt><tt class="py-op">(</tt><tt id="link-299" class="py-name"><a title="lxml.html
+lxml.objectify.fromstring" class="py-name" href="#" onclick="return doclink('link-301', 'fromstring', 'link-243');">fromstring</a></tt><tt class="py-op">(</tt><tt id="link-302" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-299', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-300" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-300', 'parser', 'link-293');">parser</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-<a name="L614"></a><tt class="py-lineno"> 614</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-301" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-302', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-303" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-303', 'parser', 'link-296');">parser</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+<a name="L615"></a><tt class="py-lineno"> 615</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-304" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-301', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L615"></a><tt class="py-lineno"> 615</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-302" class="py-name"><a title="lxml.etree
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-304', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L616"></a><tt class="py-lineno"> 616</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-305" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-302', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-303" class="py-name" targets="Class lxml.etree.ParserError=lxml.etree.ParserError-class.html"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-303', 'ParserError', 'link-303');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
-<a name="L616"></a><tt class="py-lineno"> 616</tt> <tt class="py-line"> <tt class="py-string">"Document is empty"</tt><tt class="py-op">)</tt> </tt>
-<a name="L617"></a><tt class="py-lineno"> 617</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">ensure_head_body</tt> <tt class="py-keyword">and</tt> <tt id="link-304" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-305', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-306" class="py-name" targets="Class lxml.etree.ParserError=lxml.etree.ParserError-class.html"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-306', 'ParserError', 'link-306');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
+<a name="L617"></a><tt class="py-lineno"> 617</tt> <tt class="py-line"> <tt class="py-string">"Document is empty"</tt><tt class="py-op">)</tt> </tt>
+<a name="L618"></a><tt class="py-lineno"> 618</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">ensure_head_body</tt> <tt class="py-keyword">and</tt> <tt id="link-307" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-304', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-305" class="py-name"><a title="lxml.etree._Element.find
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-307', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-308" class="py-name"><a title="lxml.etree._Element.find
lxml.etree._ElementTree.find
-lxml.objectify.ObjectPath.find" class="py-name" href="#" onclick="return doclink('link-305', 'find', 'link-194');">find</a></tt><tt class="py-op">(</tt><tt class="py-string">'head'</tt><tt class="py-op">)</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L618"></a><tt class="py-lineno"> 618</tt> <tt class="py-line"> <tt id="link-306" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.ObjectPath.find" class="py-name" href="#" onclick="return doclink('link-308', 'find', 'link-197');">find</a></tt><tt class="py-op">(</tt><tt class="py-string">'head'</tt><tt class="py-op">)</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L619"></a><tt class="py-lineno"> 619</tt> <tt class="py-line"> <tt id="link-309" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-306', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-307" class="py-name" targets="Method lxml.etree._Element.insert()=lxml.etree._Element-class.html#insert"><a title="lxml.etree._Element.insert" class="py-name" href="#" onclick="return doclink('link-307', 'insert', 'link-307');">insert</a></tt><tt class="py-op">(</tt><tt class="py-number">0</tt><tt class="py-op">,</tt> <tt id="link-308" class="py-name"><a title="lxml.etree.Element
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-309', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-310" class="py-name" targets="Method lxml.etree._Element.insert()=lxml.etree._Element-class.html#insert"><a title="lxml.etree._Element.insert" class="py-name" href="#" onclick="return doclink('link-310', 'insert', 'link-310');">insert</a></tt><tt class="py-op">(</tt><tt class="py-number">0</tt><tt class="py-op">,</tt> <tt id="link-311" class="py-name"><a title="lxml.etree.Element
lxml.objectify.Element
lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element
-xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-308', 'Element', 'link-164');">Element</a></tt><tt class="py-op">(</tt><tt class="py-string">'head'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L619"></a><tt class="py-lineno"> 619</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">ensure_head_body</tt> <tt class="py-keyword">and</tt> <tt id="link-309" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-311', 'Element', 'link-165');">Element</a></tt><tt class="py-op">(</tt><tt class="py-string">'head'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L620"></a><tt class="py-lineno"> 620</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">ensure_head_body</tt> <tt class="py-keyword">and</tt> <tt id="link-312" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-309', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-310" class="py-name"><a title="lxml.etree._Element.find
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-312', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-313" class="py-name"><a title="lxml.etree._Element.find
lxml.etree._ElementTree.find
-lxml.objectify.ObjectPath.find" class="py-name" href="#" onclick="return doclink('link-310', 'find', 'link-194');">find</a></tt><tt class="py-op">(</tt><tt class="py-string">'body'</tt><tt class="py-op">)</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L620"></a><tt class="py-lineno"> 620</tt> <tt class="py-line"> <tt id="link-311" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.ObjectPath.find" class="py-name" href="#" onclick="return doclink('link-313', 'find', 'link-197');">find</a></tt><tt class="py-op">(</tt><tt class="py-string">'body'</tt><tt class="py-op">)</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L621"></a><tt class="py-lineno"> 621</tt> <tt class="py-line"> <tt id="link-314" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-311', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-312" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-312', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt id="link-313" class="py-name"><a title="lxml.etree.Element
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-314', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-315" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-315', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt id="link-316" class="py-name"><a title="lxml.etree.Element
lxml.objectify.Element
lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element
-xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-313', 'Element', 'link-164');">Element</a></tt><tt class="py-op">(</tt><tt class="py-string">'body'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L621"></a><tt class="py-lineno"> 621</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-314" class="py-name"><a title="lxml.html.CheckboxGroup.value
-lxml.html.InputElement.value
-lxml.html.RadioGroup.value
-lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-314', 'value', 'link-172');">value</a></tt> </tt>
-</div><a name="L622"></a><tt class="py-lineno"> 622</tt> <tt class="py-line"> </tt>
-<a name="fragments_fromstring"></a><div id="fragments_fromstring-def"><a name="L623"></a><tt class="py-lineno"> 623</tt> <a class="py-toggle" href="#" id="fragments_fromstring-toggle" onclick="return toggle('fragments_fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#fragments_fromstring">fragments_fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">no_leading_text</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> </tt>
-<a name="L624"></a><tt class="py-lineno"> 624</tt> <tt class="py-line"> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="fragments_fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="fragments_fromstring-expanded"><a name="L625"></a><tt class="py-lineno"> 625</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L626"></a><tt class="py-lineno"> 626</tt> <tt class="py-line"><tt class="py-docstring"> Parses several HTML elements, returning a list of elements.</tt> </tt>
-<a name="L627"></a><tt class="py-lineno"> 627</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L628"></a><tt class="py-lineno"> 628</tt> <tt class="py-line"><tt class="py-docstring"> The first item in the list may be a string (though leading</tt> </tt>
-<a name="L629"></a><tt class="py-lineno"> 629</tt> <tt class="py-line"><tt class="py-docstring"> whitespace is removed). If no_leading_text is true, then it will</tt> </tt>
-<a name="L630"></a><tt class="py-lineno"> 630</tt> <tt class="py-line"><tt class="py-docstring"> be an error if there is leading text, and it will always be a list</tt> </tt>
-<a name="L631"></a><tt class="py-lineno"> 631</tt> <tt class="py-line"><tt class="py-docstring"> of only elements.</tt> </tt>
-<a name="L632"></a><tt class="py-lineno"> 632</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L633"></a><tt class="py-lineno"> 633</tt> <tt class="py-line"><tt class="py-docstring"> base_url will set the document's base_url attribute (and the tree's docinfo.URL)</tt> </tt>
-<a name="L634"></a><tt class="py-lineno"> 634</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L635"></a><tt class="py-lineno"> 635</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-315" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-315', 'parser', 'link-293');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L636"></a><tt class="py-lineno"> 636</tt> <tt class="py-line"> <tt id="link-316" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-316', 'parser', 'link-293');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-317" class="py-name"><a title="lxml.html.html5parser.html_parser
-lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-317', 'html_parser', 'link-295');">html_parser</a></tt> </tt>
-<a name="L637"></a><tt class="py-lineno"> 637</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: check what happens when you give html with a body, head, etc.</tt> </tt>
-<a name="L638"></a><tt class="py-lineno"> 638</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-318" class="py-name"><a title="lxml.html
+xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-316', 'Element', 'link-165');">Element</a></tt><tt class="py-op">(</tt><tt class="py-string">'body'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L622"></a><tt class="py-lineno"> 622</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-317" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputElement.value
+lxml.html.RadioGroup.value
+lxml.html.SelectElement.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-317', 'value', 'link-173');">value</a></tt> </tt>
+</div><a name="L623"></a><tt class="py-lineno"> 623</tt> <tt class="py-line"> </tt>
+<a name="fragments_fromstring"></a><div id="fragments_fromstring-def"><a name="L624"></a><tt class="py-lineno"> 624</tt> <a class="py-toggle" href="#" id="fragments_fromstring-toggle" onclick="return toggle('fragments_fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#fragments_fromstring">fragments_fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">no_leading_text</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> </tt>
+<a name="L625"></a><tt class="py-lineno"> 625</tt> <tt class="py-line"> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="fragments_fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="fragments_fromstring-expanded"><a name="L626"></a><tt class="py-lineno"> 626</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L627"></a><tt class="py-lineno"> 627</tt> <tt class="py-line"><tt class="py-docstring"> Parses several HTML elements, returning a list of elements.</tt> </tt>
+<a name="L628"></a><tt class="py-lineno"> 628</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L629"></a><tt class="py-lineno"> 629</tt> <tt class="py-line"><tt class="py-docstring"> The first item in the list may be a string (though leading</tt> </tt>
+<a name="L630"></a><tt class="py-lineno"> 630</tt> <tt class="py-line"><tt class="py-docstring"> whitespace is removed). If no_leading_text is true, then it will</tt> </tt>
+<a name="L631"></a><tt class="py-lineno"> 631</tt> <tt class="py-line"><tt class="py-docstring"> be an error if there is leading text, and it will always be a list</tt> </tt>
+<a name="L632"></a><tt class="py-lineno"> 632</tt> <tt class="py-line"><tt class="py-docstring"> of only elements.</tt> </tt>
+<a name="L633"></a><tt class="py-lineno"> 633</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L634"></a><tt class="py-lineno"> 634</tt> <tt class="py-line"><tt class="py-docstring"> base_url will set the document's base_url attribute (and the tree's docinfo.URL)</tt> </tt>
+<a name="L635"></a><tt class="py-lineno"> 635</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L636"></a><tt class="py-lineno"> 636</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-318" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-318', 'parser', 'link-296');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L637"></a><tt class="py-lineno"> 637</tt> <tt class="py-line"> <tt id="link-319" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-319', 'parser', 'link-296');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-320" class="py-name"><a title="lxml.html.html5parser.html_parser
+lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-320', 'html_parser', 'link-298');">html_parser</a></tt> </tt>
+<a name="L638"></a><tt class="py-lineno"> 638</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: check what happens when you give html with a body, head, etc.</tt> </tt>
+<a name="L639"></a><tt class="py-lineno"> 639</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-321" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-318', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt class="py-name">bytes</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L639"></a><tt class="py-lineno"> 639</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">_looks_like_full_html_bytes</tt><tt class="py-op">(</tt><tt id="link-319" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-321', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt class="py-name">bytes</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L640"></a><tt class="py-lineno"> 640</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">_looks_like_full_html_bytes</tt><tt class="py-op">(</tt><tt id="link-322" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-319', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L640"></a><tt class="py-lineno"> 640</tt> <tt class="py-line"> <tt class="py-comment"># can't use %-formatting in early Py3 versions</tt> </tt>
-<a name="L641"></a><tt class="py-lineno"> 641</tt> <tt class="py-line"> <tt id="link-320" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-322', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L641"></a><tt class="py-lineno"> 641</tt> <tt class="py-line"> <tt class="py-comment"># can't use %-formatting in early Py3 versions</tt> </tt>
+<a name="L642"></a><tt class="py-lineno"> 642</tt> <tt class="py-line"> <tt id="link-323" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-320', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-string">'<html><body>'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ascii'</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt id="link-321" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-323', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt class="py-string">'<html><body>'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ascii'</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt id="link-324" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-321', 'html', 'link-5');">html</a></tt> <tt class="py-op">+</tt> </tt>
-<a name="L642"></a><tt class="py-lineno"> 642</tt> <tt class="py-line"> <tt class="py-string">'</body></html>'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ascii'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L643"></a><tt class="py-lineno"> 643</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L644"></a><tt class="py-lineno"> 644</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">_looks_like_full_html_unicode</tt><tt class="py-op">(</tt><tt id="link-322" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-324', 'html', 'link-5');">html</a></tt> <tt class="py-op">+</tt> </tt>
+<a name="L643"></a><tt class="py-lineno"> 643</tt> <tt class="py-line"> <tt class="py-string">'</body></html>'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ascii'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L644"></a><tt class="py-lineno"> 644</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L645"></a><tt class="py-lineno"> 645</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">_looks_like_full_html_unicode</tt><tt class="py-op">(</tt><tt id="link-325" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-322', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L645"></a><tt class="py-lineno"> 645</tt> <tt class="py-line"> <tt id="link-323" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-325', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L646"></a><tt class="py-lineno"> 646</tt> <tt class="py-line"> <tt id="link-326" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-323', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-string">'<html><body>%s</body></html>'</tt> <tt class="py-op">%</tt> <tt id="link-324" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-326', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-string">'<html><body>%s</body></html>'</tt> <tt class="py-op">%</tt> <tt id="link-327" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-324', 'html', 'link-5');">html</a></tt> </tt>
-<a name="L646"></a><tt class="py-lineno"> 646</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-325" class="py-name" targets="Function lxml.html.html5parser.document_fromstring()=lxml.html.html5parser-module.html#document_fromstring"><a title="lxml.html.html5parser.document_fromstring" class="py-name" href="#" onclick="return doclink('link-325', 'document_fromstring', 'link-325');">document_fromstring</a></tt><tt class="py-op">(</tt><tt id="link-326" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-327', 'html', 'link-5');">html</a></tt> </tt>
+<a name="L647"></a><tt class="py-lineno"> 647</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-328" class="py-name" targets="Function lxml.html.html5parser.document_fromstring()=lxml.html.html5parser-module.html#document_fromstring"><a title="lxml.html.html5parser.document_fromstring" class="py-name" href="#" onclick="return doclink('link-328', 'document_fromstring', 'link-328');">document_fromstring</a></tt><tt class="py-op">(</tt><tt id="link-329" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-326', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-327" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-327', 'parser', 'link-293');">parser</a></tt><tt class="py-op">=</tt><tt id="link-328" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-328', 'parser', 'link-293');">parser</a></tt><tt class="py-op">,</tt> <tt id="link-329" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-329', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-330" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-330', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-<a name="L647"></a><tt class="py-lineno"> 647</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-331" class="py-name"><a title="lxml.etree._Comment.tag
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-329', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-330" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-330', 'parser', 'link-296');">parser</a></tt><tt class="py-op">=</tt><tt id="link-331" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-331', 'parser', 'link-296');">parser</a></tt><tt class="py-op">,</tt> <tt id="link-332" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-332', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-333" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-333', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+<a name="L648"></a><tt class="py-lineno"> 648</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-334" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-331', 'tag', 'link-48');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-string">'html'</tt> </tt>
-<a name="L648"></a><tt class="py-lineno"> 648</tt> <tt class="py-line"> <tt class="py-name">bodies</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-name">e</tt> <tt class="py-keyword">for</tt> <tt class="py-name">e</tt> <tt class="py-keyword">in</tt> <tt class="py-name">doc</tt> <tt class="py-keyword">if</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">.</tt><tt id="link-332" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-334', 'tag', 'link-49');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-string">'html'</tt> </tt>
+<a name="L649"></a><tt class="py-lineno"> 649</tt> <tt class="py-line"> <tt class="py-name">bodies</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-name">e</tt> <tt class="py-keyword">for</tt> <tt class="py-name">e</tt> <tt class="py-keyword">in</tt> <tt class="py-name">doc</tt> <tt class="py-keyword">if</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">.</tt><tt id="link-335" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-332', 'tag', 'link-48');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-string">'body'</tt><tt class="py-op">]</tt> </tt>
-<a name="L649"></a><tt class="py-lineno"> 649</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">bodies</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-number">1</tt><tt class="py-op">,</tt> <tt class="py-op">(</tt><tt class="py-string">"too many bodies: %r in %r"</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">bodies</tt><tt class="py-op">,</tt> <tt id="link-333" class="py-name"><a title="lxml.html
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-335', 'tag', 'link-49');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-string">'body'</tt><tt class="py-op">]</tt> </tt>
+<a name="L650"></a><tt class="py-lineno"> 650</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">bodies</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-number">1</tt><tt class="py-op">,</tt> <tt class="py-op">(</tt><tt class="py-string">"too many bodies: %r in %r"</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">bodies</tt><tt class="py-op">,</tt> <tt id="link-336" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-333', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L650"></a><tt class="py-lineno"> 650</tt> <tt class="py-line"> <tt id="link-334" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-334', 'body', 'link-70');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">bodies</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L651"></a><tt class="py-lineno"> 651</tt> <tt class="py-line"> <tt id="link-335" class="py-name" targets="Method lxml.etree.DTD.elements()=lxml.etree.DTD-class.html#elements"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-335', 'elements', 'link-335');">elements</a></tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
-<a name="L652"></a><tt class="py-lineno"> 652</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">no_leading_text</tt> <tt class="py-keyword">and</tt> <tt id="link-336" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-336', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-337" class="py-name"><a title="lxml.etree.QName.text
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-336', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L651"></a><tt class="py-lineno"> 651</tt> <tt class="py-line"> <tt id="link-337" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-337', 'body', 'link-71');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">bodies</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L652"></a><tt class="py-lineno"> 652</tt> <tt class="py-line"> <tt id="link-338" class="py-name" targets="Method lxml.etree.DTD.elements()=lxml.etree.DTD-class.html#elements"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-338', 'elements', 'link-338');">elements</a></tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
+<a name="L653"></a><tt class="py-lineno"> 653</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">no_leading_text</tt> <tt class="py-keyword">and</tt> <tt id="link-339" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-339', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-340" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-337', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">and</tt> <tt id="link-338" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-338', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-339" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-340', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">and</tt> <tt id="link-341" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-341', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-342" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-339', 'text', 'link-102');">text</a></tt><tt class="py-op">.</tt><tt id="link-340" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-340', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L653"></a><tt class="py-lineno"> 653</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-341" class="py-name"><a title="lxml.etree
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-342', 'text', 'link-103');">text</a></tt><tt class="py-op">.</tt><tt id="link-343" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-343', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L654"></a><tt class="py-lineno"> 654</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-344" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-341', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-342" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-342', 'ParserError', 'link-303');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
-<a name="L654"></a><tt class="py-lineno"> 654</tt> <tt class="py-line"> <tt class="py-string">"There is leading text: %r"</tt> <tt class="py-op">%</tt> <tt id="link-343" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-343', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-344" class="py-name"><a title="lxml.etree.QName.text
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-344', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-345" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-345', 'ParserError', 'link-306');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
+<a name="L655"></a><tt class="py-lineno"> 655</tt> <tt class="py-line"> <tt class="py-string">"There is leading text: %r"</tt> <tt class="py-op">%</tt> <tt id="link-346" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-346', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-347" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-344', 'text', 'link-102');">text</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L655"></a><tt class="py-lineno"> 655</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-345" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-345', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-346" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-347', 'text', 'link-103');">text</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L656"></a><tt class="py-lineno"> 656</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-348" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-348', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-349" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-346', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">and</tt> <tt id="link-347" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-347', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-348" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-349', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">and</tt> <tt id="link-350" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-350', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-351" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-348', 'text', 'link-102');">text</a></tt><tt class="py-op">.</tt><tt id="link-349" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-349', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L656"></a><tt class="py-lineno"> 656</tt> <tt class="py-line"> <tt id="link-350" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-350', 'elements', 'link-335');">elements</a></tt><tt class="py-op">.</tt><tt id="link-351" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-351', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt id="link-352" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-352', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-353" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-351', 'text', 'link-103');">text</a></tt><tt class="py-op">.</tt><tt id="link-352" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-352', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L657"></a><tt class="py-lineno"> 657</tt> <tt class="py-line"> <tt id="link-353" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-353', 'elements', 'link-338');">elements</a></tt><tt class="py-op">.</tt><tt id="link-354" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-354', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt id="link-355" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-355', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-356" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-353', 'text', 'link-102');">text</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L657"></a><tt class="py-lineno"> 657</tt> <tt class="py-line"> <tt id="link-354" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-354', 'elements', 'link-335');">elements</a></tt><tt class="py-op">.</tt><tt id="link-355" class="py-name" targets="Method lxml.etree._Element.extend()=lxml.etree._Element-class.html#extend"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-355', 'extend', 'link-355');">extend</a></tt><tt class="py-op">(</tt><tt id="link-356" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-356', 'body', 'link-70');">body</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L658"></a><tt class="py-lineno"> 658</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: removing the reference to the parent artificial document</tt> </tt>
-<a name="L659"></a><tt class="py-lineno"> 659</tt> <tt class="py-line"> <tt class="py-comment"># would be nice</tt> </tt>
-<a name="L660"></a><tt class="py-lineno"> 660</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-357" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-357', 'elements', 'link-335');">elements</a></tt> </tt>
-</div><a name="L661"></a><tt class="py-lineno"> 661</tt> <tt class="py-line"> </tt>
-<a name="fragment_fromstring"></a><div id="fragment_fromstring-def"><a name="L662"></a><tt class="py-lineno"> 662</tt> <a class="py-toggle" href="#" id="fragment_fromstring-toggle" onclick="return toggle('fragment_fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#fragment_fromstring">fragment_fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">create_parent</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> </tt>
-<a name="L663"></a><tt class="py-lineno"> 663</tt> <tt class="py-line"> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="fragment_fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="fragment_fromstring-expanded"><a name="L664"></a><tt class="py-lineno"> 664</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L665"></a><tt class="py-lineno"> 665</tt> <tt class="py-line"><tt class="py-docstring"> Parses a single HTML element; it is an error if there is more than</tt> </tt>
-<a name="L666"></a><tt class="py-lineno"> 666</tt> <tt class="py-line"><tt class="py-docstring"> one element, or if anything but whitespace precedes or follows the</tt> </tt>
-<a name="L667"></a><tt class="py-lineno"> 667</tt> <tt class="py-line"><tt class="py-docstring"> element.</tt> </tt>
-<a name="L668"></a><tt class="py-lineno"> 668</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L669"></a><tt class="py-lineno"> 669</tt> <tt class="py-line"><tt class="py-docstring"> If ``create_parent`` is true (or is a tag name) then a parent node</tt> </tt>
-<a name="L670"></a><tt class="py-lineno"> 670</tt> <tt class="py-line"><tt class="py-docstring"> will be created to encapsulate the HTML in a single element. In this</tt> </tt>
-<a name="L671"></a><tt class="py-lineno"> 671</tt> <tt class="py-line"><tt class="py-docstring"> case, leading or trailing text is also allowed, as are multiple elements</tt> </tt>
-<a name="L672"></a><tt class="py-lineno"> 672</tt> <tt class="py-line"><tt class="py-docstring"> as result of the parsing.</tt> </tt>
-<a name="L673"></a><tt class="py-lineno"> 673</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L674"></a><tt class="py-lineno"> 674</tt> <tt class="py-line"><tt class="py-docstring"> Passing a ``base_url`` will set the document's ``base_url`` attribute</tt> </tt>
-<a name="L675"></a><tt class="py-lineno"> 675</tt> <tt class="py-line"><tt class="py-docstring"> (and the tree's docinfo.URL).</tt> </tt>
-<a name="L676"></a><tt class="py-lineno"> 676</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L677"></a><tt class="py-lineno"> 677</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-358" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-358', 'parser', 'link-293');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L678"></a><tt class="py-lineno"> 678</tt> <tt class="py-line"> <tt id="link-359" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-359', 'parser', 'link-293');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-360" class="py-name"><a title="lxml.html.html5parser.html_parser
-lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-360', 'html_parser', 'link-295');">html_parser</a></tt> </tt>
-<a name="L679"></a><tt class="py-lineno"> 679</tt> <tt class="py-line"> </tt>
-<a name="L680"></a><tt class="py-lineno"> 680</tt> <tt class="py-line"> <tt class="py-name">accept_leading_text</tt> <tt class="py-op">=</tt> <tt class="py-name">bool</tt><tt class="py-op">(</tt><tt class="py-name">create_parent</tt><tt class="py-op">)</tt> </tt>
-<a name="L681"></a><tt class="py-lineno"> 681</tt> <tt class="py-line"> </tt>
-<a name="L682"></a><tt class="py-lineno"> 682</tt> <tt class="py-line"> <tt id="link-361" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-361', 'elements', 'link-335');">elements</a></tt> <tt class="py-op">=</tt> <tt id="link-362" class="py-name" targets="Function lxml.html.html5parser.fragments_fromstring()=lxml.html.html5parser-module.html#fragments_fromstring"><a title="lxml.html.html5parser.fragments_fromstring" class="py-name" href="#" onclick="return doclink('link-362', 'fragments_fromstring', 'link-362');">fragments_fromstring</a></tt><tt class="py-op">(</tt> </tt>
-<a name="L683"></a><tt class="py-lineno"> 683</tt> <tt class="py-line"> <tt id="link-363" class="py-name"><a title="lxml.html
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-356', 'text', 'link-103');">text</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L658"></a><tt class="py-lineno"> 658</tt> <tt class="py-line"> <tt id="link-357" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-357', 'elements', 'link-338');">elements</a></tt><tt class="py-op">.</tt><tt id="link-358" class="py-name" targets="Method lxml.etree._Element.extend()=lxml.etree._Element-class.html#extend"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-358', 'extend', 'link-358');">extend</a></tt><tt class="py-op">(</tt><tt id="link-359" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-359', 'body', 'link-71');">body</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L659"></a><tt class="py-lineno"> 659</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: removing the reference to the parent artificial document</tt> </tt>
+<a name="L660"></a><tt class="py-lineno"> 660</tt> <tt class="py-line"> <tt class="py-comment"># would be nice</tt> </tt>
+<a name="L661"></a><tt class="py-lineno"> 661</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-360" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-360', 'elements', 'link-338');">elements</a></tt> </tt>
+</div><a name="L662"></a><tt class="py-lineno"> 662</tt> <tt class="py-line"> </tt>
+<a name="fragment_fromstring"></a><div id="fragment_fromstring-def"><a name="L663"></a><tt class="py-lineno"> 663</tt> <a class="py-toggle" href="#" id="fragment_fromstring-toggle" onclick="return toggle('fragment_fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#fragment_fromstring">fragment_fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">create_parent</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> </tt>
+<a name="L664"></a><tt class="py-lineno"> 664</tt> <tt class="py-line"> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="fragment_fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="fragment_fromstring-expanded"><a name="L665"></a><tt class="py-lineno"> 665</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L666"></a><tt class="py-lineno"> 666</tt> <tt class="py-line"><tt class="py-docstring"> Parses a single HTML element; it is an error if there is more than</tt> </tt>
+<a name="L667"></a><tt class="py-lineno"> 667</tt> <tt class="py-line"><tt class="py-docstring"> one element, or if anything but whitespace precedes or follows the</tt> </tt>
+<a name="L668"></a><tt class="py-lineno"> 668</tt> <tt class="py-line"><tt class="py-docstring"> element.</tt> </tt>
+<a name="L669"></a><tt class="py-lineno"> 669</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L670"></a><tt class="py-lineno"> 670</tt> <tt class="py-line"><tt class="py-docstring"> If ``create_parent`` is true (or is a tag name) then a parent node</tt> </tt>
+<a name="L671"></a><tt class="py-lineno"> 671</tt> <tt class="py-line"><tt class="py-docstring"> will be created to encapsulate the HTML in a single element. In this</tt> </tt>
+<a name="L672"></a><tt class="py-lineno"> 672</tt> <tt class="py-line"><tt class="py-docstring"> case, leading or trailing text is also allowed, as are multiple elements</tt> </tt>
+<a name="L673"></a><tt class="py-lineno"> 673</tt> <tt class="py-line"><tt class="py-docstring"> as result of the parsing.</tt> </tt>
+<a name="L674"></a><tt class="py-lineno"> 674</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L675"></a><tt class="py-lineno"> 675</tt> <tt class="py-line"><tt class="py-docstring"> Passing a ``base_url`` will set the document's ``base_url`` attribute</tt> </tt>
+<a name="L676"></a><tt class="py-lineno"> 676</tt> <tt class="py-line"><tt class="py-docstring"> (and the tree's docinfo.URL).</tt> </tt>
+<a name="L677"></a><tt class="py-lineno"> 677</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L678"></a><tt class="py-lineno"> 678</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-361" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-361', 'parser', 'link-296');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L679"></a><tt class="py-lineno"> 679</tt> <tt class="py-line"> <tt id="link-362" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-362', 'parser', 'link-296');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-363" class="py-name"><a title="lxml.html.html5parser.html_parser
+lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-363', 'html_parser', 'link-298');">html_parser</a></tt> </tt>
+<a name="L680"></a><tt class="py-lineno"> 680</tt> <tt class="py-line"> </tt>
+<a name="L681"></a><tt class="py-lineno"> 681</tt> <tt class="py-line"> <tt class="py-name">accept_leading_text</tt> <tt class="py-op">=</tt> <tt class="py-name">bool</tt><tt class="py-op">(</tt><tt class="py-name">create_parent</tt><tt class="py-op">)</tt> </tt>
+<a name="L682"></a><tt class="py-lineno"> 682</tt> <tt class="py-line"> </tt>
+<a name="L683"></a><tt class="py-lineno"> 683</tt> <tt class="py-line"> <tt id="link-364" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-364', 'elements', 'link-338');">elements</a></tt> <tt class="py-op">=</tt> <tt id="link-365" class="py-name" targets="Function lxml.html.html5parser.fragments_fromstring()=lxml.html.html5parser-module.html#fragments_fromstring"><a title="lxml.html.html5parser.fragments_fromstring" class="py-name" href="#" onclick="return doclink('link-365', 'fragments_fromstring', 'link-365');">fragments_fromstring</a></tt><tt class="py-op">(</tt> </tt>
+<a name="L684"></a><tt class="py-lineno"> 684</tt> <tt class="py-line"> <tt id="link-366" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-363', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-364" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-364', 'parser', 'link-293');">parser</a></tt><tt class="py-op">=</tt><tt id="link-365" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-365', 'parser', 'link-293');">parser</a></tt><tt class="py-op">,</tt> <tt class="py-name">no_leading_text</tt><tt class="py-op">=</tt><tt class="py-keyword">not</tt> <tt class="py-name">accept_leading_text</tt><tt class="py-op">,</tt> </tt>
-<a name="L684"></a><tt class="py-lineno"> 684</tt> <tt class="py-line"> <tt id="link-366" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-366', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-367" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-367', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-<a name="L685"></a><tt class="py-lineno"> 685</tt> <tt class="py-line"> </tt>
-<a name="L686"></a><tt class="py-lineno"> 686</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">create_parent</tt><tt class="py-op">:</tt> </tt>
-<a name="L687"></a><tt class="py-lineno"> 687</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">create_parent</tt><tt class="py-op">,</tt> <tt id="link-368" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-368', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L688"></a><tt class="py-lineno"> 688</tt> <tt class="py-line"> <tt class="py-name">create_parent</tt> <tt class="py-op">=</tt> <tt class="py-string">'div'</tt> </tt>
-<a name="L689"></a><tt class="py-lineno"> 689</tt> <tt class="py-line"> <tt class="py-name">new_root</tt> <tt class="py-op">=</tt> <tt id="link-369" class="py-name"><a title="lxml.etree.Element
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-366', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-367" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-367', 'parser', 'link-296');">parser</a></tt><tt class="py-op">=</tt><tt id="link-368" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-368', 'parser', 'link-296');">parser</a></tt><tt class="py-op">,</tt> <tt class="py-name">no_leading_text</tt><tt class="py-op">=</tt><tt class="py-keyword">not</tt> <tt class="py-name">accept_leading_text</tt><tt class="py-op">,</tt> </tt>
+<a name="L685"></a><tt class="py-lineno"> 685</tt> <tt class="py-line"> <tt id="link-369" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-369', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-370" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-370', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+<a name="L686"></a><tt class="py-lineno"> 686</tt> <tt class="py-line"> </tt>
+<a name="L687"></a><tt class="py-lineno"> 687</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">create_parent</tt><tt class="py-op">:</tt> </tt>
+<a name="L688"></a><tt class="py-lineno"> 688</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">create_parent</tt><tt class="py-op">,</tt> <tt id="link-371" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-371', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L689"></a><tt class="py-lineno"> 689</tt> <tt class="py-line"> <tt class="py-name">create_parent</tt> <tt class="py-op">=</tt> <tt class="py-string">'div'</tt> </tt>
+<a name="L690"></a><tt class="py-lineno"> 690</tt> <tt class="py-line"> <tt class="py-name">new_root</tt> <tt class="py-op">=</tt> <tt id="link-372" class="py-name"><a title="lxml.etree.Element
lxml.objectify.Element
lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element
-xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-369', 'Element', 'link-164');">Element</a></tt><tt class="py-op">(</tt><tt class="py-name">create_parent</tt><tt class="py-op">)</tt> </tt>
-<a name="L690"></a><tt class="py-lineno"> 690</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-370" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-370', 'elements', 'link-335');">elements</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L691"></a><tt class="py-lineno"> 691</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-371" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-371', 'elements', 'link-335');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt><tt class="py-op">,</tt> <tt id="link-372" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-372', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L692"></a><tt class="py-lineno"> 692</tt> <tt class="py-line"> <tt class="py-name">new_root</tt><tt class="py-op">.</tt><tt id="link-373" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-372', 'Element', 'link-165');">Element</a></tt><tt class="py-op">(</tt><tt class="py-name">create_parent</tt><tt class="py-op">)</tt> </tt>
+<a name="L691"></a><tt class="py-lineno"> 691</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-373" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-373', 'elements', 'link-338');">elements</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L692"></a><tt class="py-lineno"> 692</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-374" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-374', 'elements', 'link-338');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt><tt class="py-op">,</tt> <tt id="link-375" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-375', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L693"></a><tt class="py-lineno"> 693</tt> <tt class="py-line"> <tt class="py-name">new_root</tt><tt class="py-op">.</tt><tt id="link-376" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-373', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt id="link-374" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-374', 'elements', 'link-335');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L693"></a><tt class="py-lineno"> 693</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt id="link-375" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-375', 'elements', 'link-335');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L694"></a><tt class="py-lineno"> 694</tt> <tt class="py-line"> <tt class="py-name">new_root</tt><tt class="py-op">.</tt><tt id="link-376" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-376', 'extend', 'link-355');">extend</a></tt><tt class="py-op">(</tt><tt id="link-377" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-377', 'elements', 'link-335');">elements</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L695"></a><tt class="py-lineno"> 695</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">new_root</tt> </tt>
-<a name="L696"></a><tt class="py-lineno"> 696</tt> <tt class="py-line"> </tt>
-<a name="L697"></a><tt class="py-lineno"> 697</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-378" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-378', 'elements', 'link-335');">elements</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L698"></a><tt class="py-lineno"> 698</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-379" class="py-name"><a title="lxml.etree
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-376', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt id="link-377" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-377', 'elements', 'link-338');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L694"></a><tt class="py-lineno"> 694</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt id="link-378" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-378', 'elements', 'link-338');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L695"></a><tt class="py-lineno"> 695</tt> <tt class="py-line"> <tt class="py-name">new_root</tt><tt class="py-op">.</tt><tt id="link-379" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-379', 'extend', 'link-358');">extend</a></tt><tt class="py-op">(</tt><tt id="link-380" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-380', 'elements', 'link-338');">elements</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L696"></a><tt class="py-lineno"> 696</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">new_root</tt> </tt>
+<a name="L697"></a><tt class="py-lineno"> 697</tt> <tt class="py-line"> </tt>
+<a name="L698"></a><tt class="py-lineno"> 698</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-381" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-381', 'elements', 'link-338');">elements</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L699"></a><tt class="py-lineno"> 699</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-382" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-379', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-380" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-380', 'ParserError', 'link-303');">ParserError</a></tt><tt class="py-op">(</tt><tt class="py-string">'No elements found'</tt><tt class="py-op">)</tt> </tt>
-<a name="L699"></a><tt class="py-lineno"> 699</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-381" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-381', 'elements', 'link-335');">elements</a></tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
-<a name="L700"></a><tt class="py-lineno"> 700</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-382" class="py-name"><a title="lxml.etree
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-382', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-383" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-383', 'ParserError', 'link-306');">ParserError</a></tt><tt class="py-op">(</tt><tt class="py-string">'No elements found'</tt><tt class="py-op">)</tt> </tt>
+<a name="L700"></a><tt class="py-lineno"> 700</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-384" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-384', 'elements', 'link-338');">elements</a></tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
+<a name="L701"></a><tt class="py-lineno"> 701</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-385" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-382', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-383" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-383', 'ParserError', 'link-303');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
-<a name="L701"></a><tt class="py-lineno"> 701</tt> <tt class="py-line"> <tt class="py-string">"Multiple elements found (%s)"</tt> </tt>
-<a name="L702"></a><tt class="py-lineno"> 702</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt class="py-string">', '</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-name">_element_name</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">e</tt> <tt class="py-keyword">in</tt> <tt id="link-384" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-384', 'elements', 'link-335');">elements</a></tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L703"></a><tt class="py-lineno"> 703</tt> <tt class="py-line"> <tt class="py-name">el</tt> <tt class="py-op">=</tt> <tt id="link-385" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-385', 'elements', 'link-335');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L704"></a><tt class="py-lineno"> 704</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-386" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-386', 'tail', 'link-100');">tail</a></tt> <tt class="py-keyword">and</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-387" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-387', 'tail', 'link-100');">tail</a></tt><tt class="py-op">.</tt><tt id="link-388" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-388', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L705"></a><tt class="py-lineno"> 705</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-389" class="py-name"><a title="lxml.etree
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-385', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-386" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-386', 'ParserError', 'link-306');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
+<a name="L702"></a><tt class="py-lineno"> 702</tt> <tt class="py-line"> <tt class="py-string">"Multiple elements found (%s)"</tt> </tt>
+<a name="L703"></a><tt class="py-lineno"> 703</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt class="py-string">', '</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-name">_element_name</tt><tt class="py-op">(</tt><tt class="py-name">e</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">e</tt> <tt class="py-keyword">in</tt> <tt id="link-387" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-387', 'elements', 'link-338');">elements</a></tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L704"></a><tt class="py-lineno"> 704</tt> <tt class="py-line"> <tt class="py-name">el</tt> <tt class="py-op">=</tt> <tt id="link-388" class="py-name"><a title="lxml.etree.DTD.elements" class="py-name" href="#" onclick="return doclink('link-388', 'elements', 'link-338');">elements</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L705"></a><tt class="py-lineno"> 705</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-389" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-389', 'tail', 'link-101');">tail</a></tt> <tt class="py-keyword">and</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-390" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-390', 'tail', 'link-101');">tail</a></tt><tt class="py-op">.</tt><tt id="link-391" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-391', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L706"></a><tt class="py-lineno"> 706</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt id="link-392" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-389', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-390" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-390', 'ParserError', 'link-303');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
-<a name="L706"></a><tt class="py-lineno"> 706</tt> <tt class="py-line"> <tt class="py-string">"Element followed by text: %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-391" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-391', 'tail', 'link-100');">tail</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L707"></a><tt class="py-lineno"> 707</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-392" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-392', 'tail', 'link-100');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-<a name="L708"></a><tt class="py-lineno"> 708</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">el</tt> </tt>
-</div><a name="L709"></a><tt class="py-lineno"> 709</tt> <tt class="py-line"> </tt>
-<a name="fromstring"></a><div id="fromstring-def"><a name="L710"></a><tt class="py-lineno"> 710</tt> <a class="py-toggle" href="#" id="fromstring-toggle" onclick="return toggle('fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#fromstring">fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="fromstring-expanded"><a name="L711"></a><tt class="py-lineno"> 711</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L712"></a><tt class="py-lineno"> 712</tt> <tt class="py-line"><tt class="py-docstring"> Parse the html, returning a single element/document.</tt> </tt>
-<a name="L713"></a><tt class="py-lineno"> 713</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L714"></a><tt class="py-lineno"> 714</tt> <tt class="py-line"><tt class="py-docstring"> This tries to minimally parse the chunk of text, without knowing if it</tt> </tt>
-<a name="L715"></a><tt class="py-lineno"> 715</tt> <tt class="py-line"><tt class="py-docstring"> is a fragment or a document.</tt> </tt>
-<a name="L716"></a><tt class="py-lineno"> 716</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L717"></a><tt class="py-lineno"> 717</tt> <tt class="py-line"><tt class="py-docstring"> base_url will set the document's base_url attribute (and the tree's docinfo.URL)</tt> </tt>
-<a name="L718"></a><tt class="py-lineno"> 718</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L719"></a><tt class="py-lineno"> 719</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-393" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-393', 'parser', 'link-293');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L720"></a><tt class="py-lineno"> 720</tt> <tt class="py-line"> <tt id="link-394" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-394', 'parser', 'link-293');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-395" class="py-name"><a title="lxml.html.html5parser.html_parser
-lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-395', 'html_parser', 'link-295');">html_parser</a></tt> </tt>
-<a name="L721"></a><tt class="py-lineno"> 721</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-396" class="py-name"><a title="lxml.html
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-392', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-393" class="py-name"><a title="lxml.etree.ParserError" class="py-name" href="#" onclick="return doclink('link-393', 'ParserError', 'link-306');">ParserError</a></tt><tt class="py-op">(</tt> </tt>
+<a name="L707"></a><tt class="py-lineno"> 707</tt> <tt class="py-line"> <tt class="py-string">"Element followed by text: %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-394" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-394', 'tail', 'link-101');">tail</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L708"></a><tt class="py-lineno"> 708</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-395" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-395', 'tail', 'link-101');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+<a name="L709"></a><tt class="py-lineno"> 709</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">el</tt> </tt>
+</div><a name="L710"></a><tt class="py-lineno"> 710</tt> <tt class="py-line"> </tt>
+<a name="fromstring"></a><div id="fromstring-def"><a name="L711"></a><tt class="py-lineno"> 711</tt> <a class="py-toggle" href="#" id="fromstring-toggle" onclick="return toggle('fromstring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#fromstring">fromstring</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="fromstring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="fromstring-expanded"><a name="L712"></a><tt class="py-lineno"> 712</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L713"></a><tt class="py-lineno"> 713</tt> <tt class="py-line"><tt class="py-docstring"> Parse the html, returning a single element/document.</tt> </tt>
+<a name="L714"></a><tt class="py-lineno"> 714</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L715"></a><tt class="py-lineno"> 715</tt> <tt class="py-line"><tt class="py-docstring"> This tries to minimally parse the chunk of text, without knowing if it</tt> </tt>
+<a name="L716"></a><tt class="py-lineno"> 716</tt> <tt class="py-line"><tt class="py-docstring"> is a fragment or a document.</tt> </tt>
+<a name="L717"></a><tt class="py-lineno"> 717</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L718"></a><tt class="py-lineno"> 718</tt> <tt class="py-line"><tt class="py-docstring"> base_url will set the document's base_url attribute (and the tree's docinfo.URL)</tt> </tt>
+<a name="L719"></a><tt class="py-lineno"> 719</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L720"></a><tt class="py-lineno"> 720</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-396" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-396', 'parser', 'link-296');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L721"></a><tt class="py-lineno"> 721</tt> <tt class="py-line"> <tt id="link-397" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-397', 'parser', 'link-296');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-398" class="py-name"><a title="lxml.html.html5parser.html_parser
+lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-398', 'html_parser', 'link-298');">html_parser</a></tt> </tt>
+<a name="L722"></a><tt class="py-lineno"> 722</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-399" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-396', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt class="py-name">bytes</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L722"></a><tt class="py-lineno"> 722</tt> <tt class="py-line"> <tt class="py-name">is_full_html</tt> <tt class="py-op">=</tt> <tt class="py-name">_looks_like_full_html_bytes</tt><tt class="py-op">(</tt><tt id="link-397" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-399', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt class="py-name">bytes</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L723"></a><tt class="py-lineno"> 723</tt> <tt class="py-line"> <tt class="py-name">is_full_html</tt> <tt class="py-op">=</tt> <tt class="py-name">_looks_like_full_html_bytes</tt><tt class="py-op">(</tt><tt id="link-400" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-397', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L723"></a><tt class="py-lineno"> 723</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L724"></a><tt class="py-lineno"> 724</tt> <tt class="py-line"> <tt class="py-name">is_full_html</tt> <tt class="py-op">=</tt> <tt class="py-name">_looks_like_full_html_unicode</tt><tt class="py-op">(</tt><tt id="link-398" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-400', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L724"></a><tt class="py-lineno"> 724</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L725"></a><tt class="py-lineno"> 725</tt> <tt class="py-line"> <tt class="py-name">is_full_html</tt> <tt class="py-op">=</tt> <tt class="py-name">_looks_like_full_html_unicode</tt><tt class="py-op">(</tt><tt id="link-401" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-398', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L725"></a><tt class="py-lineno"> 725</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-399" class="py-name"><a title="lxml.html.html5parser.document_fromstring" class="py-name" href="#" onclick="return doclink('link-399', 'document_fromstring', 'link-325');">document_fromstring</a></tt><tt class="py-op">(</tt><tt id="link-400" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-401', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L726"></a><tt class="py-lineno"> 726</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-402" class="py-name"><a title="lxml.html.html5parser.document_fromstring" class="py-name" href="#" onclick="return doclink('link-402', 'document_fromstring', 'link-328');">document_fromstring</a></tt><tt class="py-op">(</tt><tt id="link-403" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-400', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-401" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-401', 'parser', 'link-293');">parser</a></tt><tt class="py-op">=</tt><tt id="link-402" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-402', 'parser', 'link-293');">parser</a></tt><tt class="py-op">,</tt> <tt id="link-403" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-403', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-404" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-404', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-<a name="L726"></a><tt class="py-lineno"> 726</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">is_full_html</tt><tt class="py-op">:</tt> </tt>
-<a name="L727"></a><tt class="py-lineno"> 727</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">doc</tt> </tt>
-<a name="L728"></a><tt class="py-lineno"> 728</tt> <tt class="py-line"> <tt class="py-comment"># otherwise, lets parse it out...</tt> </tt>
-<a name="L729"></a><tt class="py-lineno"> 729</tt> <tt class="py-line"> <tt class="py-name">bodies</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-405" class="py-name" targets="Method lxml.etree._Element.findall()=lxml.etree._Element-class.html#findall,Method lxml.etree._ElementTree.findall()=lxml.etree._ElementTree-class.html#findall"><a title="lxml.etree._Element.findall
-lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-405', 'findall', 'link-405');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'body'</tt><tt class="py-op">)</tt> </tt>
-<a name="L730"></a><tt class="py-lineno"> 730</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">bodies</tt><tt class="py-op">:</tt> </tt>
-<a name="L731"></a><tt class="py-lineno"> 731</tt> <tt class="py-line"> <tt class="py-name">bodies</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-406" class="py-name"><a title="lxml.etree._Element.findall
-lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-406', 'findall', 'link-405');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'{%s}body'</tt> <tt class="py-op">%</tt> <tt id="link-407" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-407', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L732"></a><tt class="py-lineno"> 732</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">bodies</tt><tt class="py-op">:</tt> </tt>
-<a name="L733"></a><tt class="py-lineno"> 733</tt> <tt class="py-line"> <tt id="link-408" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-408', 'body', 'link-70');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">bodies</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L734"></a><tt class="py-lineno"> 734</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">bodies</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
-<a name="L735"></a><tt class="py-lineno"> 735</tt> <tt class="py-line"> <tt class="py-comment"># Somehow there are multiple bodies, which is bad, but just</tt> </tt>
-<a name="L736"></a><tt class="py-lineno"> 736</tt> <tt class="py-line"> <tt class="py-comment"># smash them into one body</tt> </tt>
-<a name="L737"></a><tt class="py-lineno"> 737</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">other_body</tt> <tt class="py-keyword">in</tt> <tt class="py-name">bodies</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt><tt class="py-op">:</tt> </tt>
-<a name="L738"></a><tt class="py-lineno"> 738</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-409" class="py-name"><a title="lxml.etree.QName.text
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-403', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-404" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-404', 'parser', 'link-296');">parser</a></tt><tt class="py-op">=</tt><tt id="link-405" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-405', 'parser', 'link-296');">parser</a></tt><tt class="py-op">,</tt> <tt id="link-406" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-406', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-407" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-407', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+<a name="L727"></a><tt class="py-lineno"> 727</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">is_full_html</tt><tt class="py-op">:</tt> </tt>
+<a name="L728"></a><tt class="py-lineno"> 728</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">doc</tt> </tt>
+<a name="L729"></a><tt class="py-lineno"> 729</tt> <tt class="py-line"> <tt class="py-comment"># otherwise, lets parse it out...</tt> </tt>
+<a name="L730"></a><tt class="py-lineno"> 730</tt> <tt class="py-line"> <tt class="py-name">bodies</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-408" class="py-name" targets="Method lxml.etree._Element.findall()=lxml.etree._Element-class.html#findall,Method lxml.etree._ElementTree.findall()=lxml.etree._ElementTree-class.html#findall"><a title="lxml.etree._Element.findall
+lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-408', 'findall', 'link-408');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'body'</tt><tt class="py-op">)</tt> </tt>
+<a name="L731"></a><tt class="py-lineno"> 731</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">bodies</tt><tt class="py-op">:</tt> </tt>
+<a name="L732"></a><tt class="py-lineno"> 732</tt> <tt class="py-line"> <tt class="py-name">bodies</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-409" class="py-name"><a title="lxml.etree._Element.findall
+lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-409', 'findall', 'link-408');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'{%s}body'</tt> <tt class="py-op">%</tt> <tt id="link-410" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-410', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L733"></a><tt class="py-lineno"> 733</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">bodies</tt><tt class="py-op">:</tt> </tt>
+<a name="L734"></a><tt class="py-lineno"> 734</tt> <tt class="py-line"> <tt id="link-411" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-411', 'body', 'link-71');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">bodies</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L735"></a><tt class="py-lineno"> 735</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">bodies</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
+<a name="L736"></a><tt class="py-lineno"> 736</tt> <tt class="py-line"> <tt class="py-comment"># Somehow there are multiple bodies, which is bad, but just</tt> </tt>
+<a name="L737"></a><tt class="py-lineno"> 737</tt> <tt class="py-line"> <tt class="py-comment"># smash them into one body</tt> </tt>
+<a name="L738"></a><tt class="py-lineno"> 738</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">other_body</tt> <tt class="py-keyword">in</tt> <tt class="py-name">bodies</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt><tt class="py-op">:</tt> </tt>
+<a name="L739"></a><tt class="py-lineno"> 739</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-412" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-409', 'text', 'link-102');">text</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L739"></a><tt class="py-lineno"> 739</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-410" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-410', 'body', 'link-70');">body</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L740"></a><tt class="py-lineno"> 740</tt> <tt class="py-line"> <tt id="link-411" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-411', 'body', 'link-70');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-412" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-412', 'tail', 'link-100');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt id="link-413" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-413', 'body', 'link-70');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-414" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-414', 'tail', 'link-100');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-415" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-412', 'text', 'link-103');">text</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L740"></a><tt class="py-lineno"> 740</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-413" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-413', 'body', 'link-71');">body</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L741"></a><tt class="py-lineno"> 741</tt> <tt class="py-line"> <tt id="link-414" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-414', 'body', 'link-71');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-415" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-415', 'tail', 'link-101');">tail</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt id="link-416" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-416', 'body', 'link-71');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-417" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-417', 'tail', 'link-101');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-418" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-415', 'text', 'link-102');">text</a></tt> </tt>
-<a name="L741"></a><tt class="py-lineno"> 741</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L742"></a><tt class="py-lineno"> 742</tt> <tt class="py-line"> <tt id="link-416" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-416', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-417" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-418', 'text', 'link-103');">text</a></tt> </tt>
+<a name="L742"></a><tt class="py-lineno"> 742</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L743"></a><tt class="py-lineno"> 743</tt> <tt class="py-line"> <tt id="link-419" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-419', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-420" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-417', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt id="link-418" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-418', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-419" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-420', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-op">(</tt><tt id="link-421" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-421', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-422" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-419', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-420" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-422', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> <tt class="py-op">+</tt> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-423" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-420', 'text', 'link-102');">text</a></tt> </tt>
-<a name="L743"></a><tt class="py-lineno"> 743</tt> <tt class="py-line"> <tt id="link-421" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-421', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-422" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-422', 'extend', 'link-355');">extend</a></tt><tt class="py-op">(</tt><tt class="py-name">other_body</tt><tt class="py-op">)</tt> </tt>
-<a name="L744"></a><tt class="py-lineno"> 744</tt> <tt class="py-line"> <tt class="py-comment"># We'll ignore tail</tt> </tt>
-<a name="L745"></a><tt class="py-lineno"> 745</tt> <tt class="py-line"> <tt class="py-comment"># I guess we are ignoring attributes too</tt> </tt>
-<a name="L746"></a><tt class="py-lineno"> 746</tt> <tt class="py-line"> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-423" class="py-name"><a title="lxml.html.HtmlMixin.drop_tree" class="py-name" href="#" onclick="return doclink('link-423', 'drop_tree', 'link-156');">drop_tree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L747"></a><tt class="py-lineno"> 747</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L748"></a><tt class="py-lineno"> 748</tt> <tt class="py-line"> <tt id="link-424" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-424', 'body', 'link-70');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-<a name="L749"></a><tt class="py-lineno"> 749</tt> <tt class="py-line"> <tt class="py-name">heads</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-425" class="py-name"><a title="lxml.etree._Element.findall
-lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-425', 'findall', 'link-405');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'head'</tt><tt class="py-op">)</tt> </tt>
-<a name="L750"></a><tt class="py-lineno"> 750</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">heads</tt><tt class="py-op">:</tt> </tt>
-<a name="L751"></a><tt class="py-lineno"> 751</tt> <tt class="py-line"> <tt class="py-name">heads</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-426" class="py-name"><a title="lxml.etree._Element.findall
-lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-426', 'findall', 'link-405');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'{%s}head'</tt> <tt class="py-op">%</tt> <tt id="link-427" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-427', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L752"></a><tt class="py-lineno"> 752</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">heads</tt><tt class="py-op">:</tt> </tt>
-<a name="L753"></a><tt class="py-lineno"> 753</tt> <tt class="py-line"> <tt class="py-comment"># Well, we have some sort of structure, so lets keep it all</tt> </tt>
-<a name="L754"></a><tt class="py-lineno"> 754</tt> <tt class="py-line"> <tt id="link-428" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-428', 'head', 'link-76');">head</a></tt> <tt class="py-op">=</tt> <tt class="py-name">heads</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L755"></a><tt class="py-lineno"> 755</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">heads</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
-<a name="L756"></a><tt class="py-lineno"> 756</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">other_head</tt> <tt class="py-keyword">in</tt> <tt class="py-name">heads</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt><tt class="py-op">:</tt> </tt>
-<a name="L757"></a><tt class="py-lineno"> 757</tt> <tt class="py-line"> <tt id="link-429" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-429', 'head', 'link-76');">head</a></tt><tt class="py-op">.</tt><tt id="link-430" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-430', 'extend', 'link-355');">extend</a></tt><tt class="py-op">(</tt><tt class="py-name">other_head</tt><tt class="py-op">)</tt> </tt>
-<a name="L758"></a><tt class="py-lineno"> 758</tt> <tt class="py-line"> <tt class="py-comment"># We don't care about text or tail in a head</tt> </tt>
-<a name="L759"></a><tt class="py-lineno"> 759</tt> <tt class="py-line"> <tt class="py-name">other_head</tt><tt class="py-op">.</tt><tt id="link-431" class="py-name"><a title="lxml.html.HtmlMixin.drop_tree" class="py-name" href="#" onclick="return doclink('link-431', 'drop_tree', 'link-156');">drop_tree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L760"></a><tt class="py-lineno"> 760</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">doc</tt> </tt>
-<a name="L761"></a><tt class="py-lineno"> 761</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-432" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-432', 'body', 'link-70');">body</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L762"></a><tt class="py-lineno"> 762</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">doc</tt> </tt>
-<a name="L763"></a><tt class="py-lineno"> 763</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-433" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-433', 'body', 'link-70');">body</a></tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-number">1</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-keyword">not</tt> <tt id="link-434" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-434', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-435" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-423', 'text', 'link-103');">text</a></tt> </tt>
+<a name="L744"></a><tt class="py-lineno"> 744</tt> <tt class="py-line"> <tt id="link-424" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-424', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-425" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-425', 'extend', 'link-358');">extend</a></tt><tt class="py-op">(</tt><tt class="py-name">other_body</tt><tt class="py-op">)</tt> </tt>
+<a name="L745"></a><tt class="py-lineno"> 745</tt> <tt class="py-line"> <tt class="py-comment"># We'll ignore tail</tt> </tt>
+<a name="L746"></a><tt class="py-lineno"> 746</tt> <tt class="py-line"> <tt class="py-comment"># I guess we are ignoring attributes too</tt> </tt>
+<a name="L747"></a><tt class="py-lineno"> 747</tt> <tt class="py-line"> <tt class="py-name">other_body</tt><tt class="py-op">.</tt><tt id="link-426" class="py-name"><a title="lxml.html.HtmlMixin.drop_tree" class="py-name" href="#" onclick="return doclink('link-426', 'drop_tree', 'link-157');">drop_tree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L748"></a><tt class="py-lineno"> 748</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L749"></a><tt class="py-lineno"> 749</tt> <tt class="py-line"> <tt id="link-427" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-427', 'body', 'link-71');">body</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+<a name="L750"></a><tt class="py-lineno"> 750</tt> <tt class="py-line"> <tt class="py-name">heads</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-428" class="py-name"><a title="lxml.etree._Element.findall
+lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-428', 'findall', 'link-408');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'head'</tt><tt class="py-op">)</tt> </tt>
+<a name="L751"></a><tt class="py-lineno"> 751</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">heads</tt><tt class="py-op">:</tt> </tt>
+<a name="L752"></a><tt class="py-lineno"> 752</tt> <tt class="py-line"> <tt class="py-name">heads</tt> <tt class="py-op">=</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-429" class="py-name"><a title="lxml.etree._Element.findall
+lxml.etree._ElementTree.findall" class="py-name" href="#" onclick="return doclink('link-429', 'findall', 'link-408');">findall</a></tt><tt class="py-op">(</tt><tt class="py-string">'{%s}head'</tt> <tt class="py-op">%</tt> <tt id="link-430" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-430', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L753"></a><tt class="py-lineno"> 753</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">heads</tt><tt class="py-op">:</tt> </tt>
+<a name="L754"></a><tt class="py-lineno"> 754</tt> <tt class="py-line"> <tt class="py-comment"># Well, we have some sort of structure, so lets keep it all</tt> </tt>
+<a name="L755"></a><tt class="py-lineno"> 755</tt> <tt class="py-line"> <tt id="link-431" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-431', 'head', 'link-77');">head</a></tt> <tt class="py-op">=</tt> <tt class="py-name">heads</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L756"></a><tt class="py-lineno"> 756</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">heads</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
+<a name="L757"></a><tt class="py-lineno"> 757</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">other_head</tt> <tt class="py-keyword">in</tt> <tt class="py-name">heads</tt><tt class="py-op">[</tt><tt class="py-number">1</tt><tt class="py-op">:</tt><tt class="py-op">]</tt><tt class="py-op">:</tt> </tt>
+<a name="L758"></a><tt class="py-lineno"> 758</tt> <tt class="py-line"> <tt id="link-432" class="py-name"><a title="lxml.html.HtmlMixin.head" class="py-name" href="#" onclick="return doclink('link-432', 'head', 'link-77');">head</a></tt><tt class="py-op">.</tt><tt id="link-433" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-433', 'extend', 'link-358');">extend</a></tt><tt class="py-op">(</tt><tt class="py-name">other_head</tt><tt class="py-op">)</tt> </tt>
+<a name="L759"></a><tt class="py-lineno"> 759</tt> <tt class="py-line"> <tt class="py-comment"># We don't care about text or tail in a head</tt> </tt>
+<a name="L760"></a><tt class="py-lineno"> 760</tt> <tt class="py-line"> <tt class="py-name">other_head</tt><tt class="py-op">.</tt><tt id="link-434" class="py-name"><a title="lxml.html.HtmlMixin.drop_tree" class="py-name" href="#" onclick="return doclink('link-434', 'drop_tree', 'link-157');">drop_tree</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L761"></a><tt class="py-lineno"> 761</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">doc</tt> </tt>
+<a name="L762"></a><tt class="py-lineno"> 762</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-435" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-435', 'body', 'link-71');">body</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L763"></a><tt class="py-lineno"> 763</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">doc</tt> </tt>
+<a name="L764"></a><tt class="py-lineno"> 764</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-op">(</tt><tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-436" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-436', 'body', 'link-71');">body</a></tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt class="py-number">1</tt> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-keyword">not</tt> <tt id="link-437" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-437', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-438" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-435', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-keyword">not</tt> <tt id="link-436" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-436', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-437" class="py-name"><a title="lxml.etree.QName.text
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-438', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-keyword">not</tt> <tt id="link-439" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-439', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-440" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-437', 'text', 'link-102');">text</a></tt><tt class="py-op">.</tt><tt id="link-438" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-438', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L764"></a><tt class="py-lineno"> 764</tt> <tt class="py-line"> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-keyword">not</tt> <tt id="link-439" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-439', 'body', 'link-70');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-440" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-440', 'tail', 'link-100');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-keyword">not</tt> <tt id="link-441" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-441', 'body', 'link-70');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-442" class="py-name"><a title="lxml.etree._Element.tail
-xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-442', 'tail', 'link-100');">tail</a></tt><tt class="py-op">.</tt><tt id="link-443" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-443', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L765"></a><tt class="py-lineno"> 765</tt> <tt class="py-line"> <tt class="py-comment"># The body has just one element, so it was probably a single</tt> </tt>
-<a name="L766"></a><tt class="py-lineno"> 766</tt> <tt class="py-line"> <tt class="py-comment"># element passed in</tt> </tt>
-<a name="L767"></a><tt class="py-lineno"> 767</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-444" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-444', 'body', 'link-70');">body</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L768"></a><tt class="py-lineno"> 768</tt> <tt class="py-line"> <tt class="py-comment"># Now we have a body which represents a bunch of tags which have the</tt> </tt>
-<a name="L769"></a><tt class="py-lineno"> 769</tt> <tt class="py-line"> <tt class="py-comment"># content that was passed in. We will create a fake container, which</tt> </tt>
-<a name="L770"></a><tt class="py-lineno"> 770</tt> <tt class="py-line"> <tt class="py-comment"># is the body tag, except <body> implies too much structure.</tt> </tt>
-<a name="L771"></a><tt class="py-lineno"> 771</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-445" class="py-name" targets="Function lxml.html.diff._contains_block_level_tag()=lxml.html.diff-module.html#_contains_block_level_tag"><a title="lxml.html.diff._contains_block_level_tag" class="py-name" href="#" onclick="return doclink('link-445', '_contains_block_level_tag', 'link-445');">_contains_block_level_tag</a></tt><tt class="py-op">(</tt><tt id="link-446" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-446', 'body', 'link-70');">body</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L772"></a><tt class="py-lineno"> 772</tt> <tt class="py-line"> <tt id="link-447" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-447', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-448" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-440', 'text', 'link-103');">text</a></tt><tt class="py-op">.</tt><tt id="link-441" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-441', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L765"></a><tt class="py-lineno"> 765</tt> <tt class="py-line"> <tt class="py-keyword">and</tt> <tt class="py-op">(</tt><tt class="py-keyword">not</tt> <tt id="link-442" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-442', 'body', 'link-71');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-443" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-443', 'tail', 'link-101');">tail</a></tt> <tt class="py-keyword">or</tt> <tt class="py-keyword">not</tt> <tt id="link-444" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-444', 'body', 'link-71');">body</a></tt><tt class="py-op">[</tt><tt class="py-op">-</tt><tt class="py-number">1</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-445" class="py-name"><a title="lxml.etree._Element.tail
+xml.etree.ElementTree.Element.tail" class="py-name" href="#" onclick="return doclink('link-445', 'tail', 'link-101');">tail</a></tt><tt class="py-op">.</tt><tt id="link-446" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-446', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L766"></a><tt class="py-lineno"> 766</tt> <tt class="py-line"> <tt class="py-comment"># The body has just one element, so it was probably a single</tt> </tt>
+<a name="L767"></a><tt class="py-lineno"> 767</tt> <tt class="py-line"> <tt class="py-comment"># element passed in</tt> </tt>
+<a name="L768"></a><tt class="py-lineno"> 768</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-447" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-447', 'body', 'link-71');">body</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L769"></a><tt class="py-lineno"> 769</tt> <tt class="py-line"> <tt class="py-comment"># Now we have a body which represents a bunch of tags which have the</tt> </tt>
+<a name="L770"></a><tt class="py-lineno"> 770</tt> <tt class="py-line"> <tt class="py-comment"># content that was passed in. We will create a fake container, which</tt> </tt>
+<a name="L771"></a><tt class="py-lineno"> 771</tt> <tt class="py-line"> <tt class="py-comment"># is the body tag, except <body> implies too much structure.</tt> </tt>
+<a name="L772"></a><tt class="py-lineno"> 772</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-448" class="py-name" targets="Function lxml.html.diff._contains_block_level_tag()=lxml.html.diff-module.html#_contains_block_level_tag"><a title="lxml.html.diff._contains_block_level_tag" class="py-name" href="#" onclick="return doclink('link-448', '_contains_block_level_tag', 'link-448');">_contains_block_level_tag</a></tt><tt class="py-op">(</tt><tt id="link-449" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-449', 'body', 'link-71');">body</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L773"></a><tt class="py-lineno"> 773</tt> <tt class="py-line"> <tt id="link-450" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-450', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-451" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-448', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-string">'div'</tt> </tt>
-<a name="L773"></a><tt class="py-lineno"> 773</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L774"></a><tt class="py-lineno"> 774</tt> <tt class="py-line"> <tt id="link-449" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-449', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-450" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-451', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-string">'div'</tt> </tt>
+<a name="L774"></a><tt class="py-lineno"> 774</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L775"></a><tt class="py-lineno"> 775</tt> <tt class="py-line"> <tt id="link-452" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-452', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-453" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-450', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-string">'span'</tt> </tt>
-<a name="L775"></a><tt class="py-lineno"> 775</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-451" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-451', 'body', 'link-70');">body</a></tt> </tt>
-</div><a name="L776"></a><tt class="py-lineno"> 776</tt> <tt class="py-line"> </tt>
-<a name="parse"></a><div id="parse-def"><a name="L777"></a><tt class="py-lineno"> 777</tt> <a class="py-toggle" href="#" id="parse-toggle" onclick="return toggle('parse');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#parse">parse</a><tt class="py-op">(</tt><tt class="py-param">filename_or_url</tt><tt class="py-op">,</tt> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="parse-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="parse-expanded"><a name="L778"></a><tt class="py-lineno"> 778</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L779"></a><tt class="py-lineno"> 779</tt> <tt class="py-line"><tt class="py-docstring"> Parse a filename, URL, or file-like object into an HTML document</tt> </tt>
-<a name="L780"></a><tt class="py-lineno"> 780</tt> <tt class="py-line"><tt class="py-docstring"> tree. Note: this returns a tree, not an element. Use</tt> </tt>
-<a name="L781"></a><tt class="py-lineno"> 781</tt> <tt class="py-line"><tt class="py-docstring"> ``parse(...).getroot()`` to get the document root.</tt> </tt>
-<a name="L782"></a><tt class="py-lineno"> 782</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L783"></a><tt class="py-lineno"> 783</tt> <tt class="py-line"><tt class="py-docstring"> You can override the base URL with the ``base_url`` keyword. This</tt> </tt>
-<a name="L784"></a><tt class="py-lineno"> 784</tt> <tt class="py-line"><tt class="py-docstring"> is most useful when parsing from a file-like object.</tt> </tt>
-<a name="L785"></a><tt class="py-lineno"> 785</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L786"></a><tt class="py-lineno"> 786</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-452" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-452', 'parser', 'link-293');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L787"></a><tt class="py-lineno"> 787</tt> <tt class="py-line"> <tt id="link-453" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-453', 'parser', 'link-293');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-454" class="py-name"><a title="lxml.html.html5parser.html_parser
-lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-454', 'html_parser', 'link-295');">html_parser</a></tt> </tt>
-<a name="L788"></a><tt class="py-lineno"> 788</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-455" class="py-name"><a title="lxml.etree
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-453', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-string">'span'</tt> </tt>
+<a name="L776"></a><tt class="py-lineno"> 776</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-454" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-454', 'body', 'link-71');">body</a></tt> </tt>
+</div><a name="L777"></a><tt class="py-lineno"> 777</tt> <tt class="py-line"> </tt>
+<a name="parse"></a><div id="parse-def"><a name="L778"></a><tt class="py-lineno"> 778</tt> <a class="py-toggle" href="#" id="parse-toggle" onclick="return toggle('parse');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#parse">parse</a><tt class="py-op">(</tt><tt class="py-param">filename_or_url</tt><tt class="py-op">,</tt> <tt class="py-param">parser</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">base_url</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="parse-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="parse-expanded"><a name="L779"></a><tt class="py-lineno"> 779</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L780"></a><tt class="py-lineno"> 780</tt> <tt class="py-line"><tt class="py-docstring"> Parse a filename, URL, or file-like object into an HTML document</tt> </tt>
+<a name="L781"></a><tt class="py-lineno"> 781</tt> <tt class="py-line"><tt class="py-docstring"> tree. Note: this returns a tree, not an element. Use</tt> </tt>
+<a name="L782"></a><tt class="py-lineno"> 782</tt> <tt class="py-line"><tt class="py-docstring"> ``parse(...).getroot()`` to get the document root.</tt> </tt>
+<a name="L783"></a><tt class="py-lineno"> 783</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L784"></a><tt class="py-lineno"> 784</tt> <tt class="py-line"><tt class="py-docstring"> You can override the base URL with the ``base_url`` keyword. This</tt> </tt>
+<a name="L785"></a><tt class="py-lineno"> 785</tt> <tt class="py-line"><tt class="py-docstring"> is most useful when parsing from a file-like object.</tt> </tt>
+<a name="L786"></a><tt class="py-lineno"> 786</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L787"></a><tt class="py-lineno"> 787</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-455" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-455', 'parser', 'link-296');">parser</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L788"></a><tt class="py-lineno"> 788</tt> <tt class="py-line"> <tt id="link-456" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-456', 'parser', 'link-296');">parser</a></tt> <tt class="py-op">=</tt> <tt id="link-457" class="py-name"><a title="lxml.html.html5parser.html_parser
+lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-457', 'html_parser', 'link-298');">html_parser</a></tt> </tt>
+<a name="L789"></a><tt class="py-lineno"> 789</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-458" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-455', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-456" class="py-name"><a title="lxml.etree._ElementTree.parse
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-458', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-459" class="py-name"><a title="lxml.etree._ElementTree.parse
lxml.etree.parse
lxml.html.ElementSoup.parse
lxml.html.html5parser.parse
lxml.html.soupparser.parse
lxml.objectify.parse
-lxml.tests.common_imports.HelperTestCase.parse" class="py-name" href="#" onclick="return doclink('link-456', 'parse', 'link-0');">parse</a></tt><tt class="py-op">(</tt><tt class="py-name">filename_or_url</tt><tt class="py-op">,</tt> <tt id="link-457" class="py-name"><a title="lxml.etree._ElementTree.parser
-lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-457', 'parser', 'link-293');">parser</a></tt><tt class="py-op">,</tt> <tt id="link-458" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-458', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-459" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-459', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L789"></a><tt class="py-lineno"> 789</tt> <tt class="py-line"> </tt>
-<a name="_contains_block_level_tag"></a><div id="_contains_block_level_tag-def"><a name="L790"></a><tt class="py-lineno"> 790</tt> <a class="py-toggle" href="#" id="_contains_block_level_tag-toggle" onclick="return toggle('_contains_block_level_tag');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_contains_block_level_tag">_contains_block_level_tag</a><tt class="py-op">(</tt><tt class="py-param">el</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_contains_block_level_tag-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_contains_block_level_tag-expanded"><a name="L791"></a><tt class="py-lineno"> 791</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: I could do this with XPath, but would that just be</tt> </tt>
-<a name="L792"></a><tt class="py-lineno"> 792</tt> <tt class="py-line"> <tt class="py-comment"># unnecessarily slow?</tt> </tt>
-<a name="L793"></a><tt class="py-lineno"> 793</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-460" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-460', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt id="link-461" class="py-name"><a title="lxml.etree
+lxml.tests.common_imports.HelperTestCase.parse" class="py-name" href="#" onclick="return doclink('link-459', 'parse', 'link-0');">parse</a></tt><tt class="py-op">(</tt><tt class="py-name">filename_or_url</tt><tt class="py-op">,</tt> <tt id="link-460" class="py-name"><a title="lxml.etree._ElementTree.parser
+lxml.tests.test_pyclasslookup.PyClassLookupTestCase.parser" class="py-name" href="#" onclick="return doclink('link-460', 'parser', 'link-296');">parser</a></tt><tt class="py-op">,</tt> <tt id="link-461" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-461', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">=</tt><tt id="link-462" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-462', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L790"></a><tt class="py-lineno"> 790</tt> <tt class="py-line"> </tt>
+<a name="_contains_block_level_tag"></a><div id="_contains_block_level_tag-def"><a name="L791"></a><tt class="py-lineno"> 791</tt> <a class="py-toggle" href="#" id="_contains_block_level_tag-toggle" onclick="return toggle('_contains_block_level_tag');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_contains_block_level_tag">_contains_block_level_tag</a><tt class="py-op">(</tt><tt class="py-param">el</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_contains_block_level_tag-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_contains_block_level_tag-expanded"><a name="L792"></a><tt class="py-lineno"> 792</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: I could do this with XPath, but would that just be</tt> </tt>
+<a name="L793"></a><tt class="py-lineno"> 793</tt> <tt class="py-line"> <tt class="py-comment"># unnecessarily slow?</tt> </tt>
+<a name="L794"></a><tt class="py-lineno"> 794</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-463" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-463', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt id="link-464" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-461', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-462" class="py-name"><a title="lxml.etree.Element
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-464', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-465" class="py-name"><a title="lxml.etree.Element
lxml.objectify.Element
lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element
-xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-462', 'Element', 'link-164');">Element</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L794"></a><tt class="py-lineno"> 794</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-463" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-465', 'Element', 'link-165');">Element</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L795"></a><tt class="py-lineno"> 795</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-466" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-463', 'tag', 'link-48');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">in</tt> <tt id="link-464" class="py-name"><a title="lxml.html.defs" class="py-name" href="#" onclick="return doclink('link-464', 'defs', 'link-6');">defs</a></tt><tt class="py-op">.</tt><tt id="link-465" class="py-name" targets="Variable lxml.html.defs.block_tags=lxml.html.defs-module.html#block_tags"><a title="lxml.html.defs.block_tags" class="py-name" href="#" onclick="return doclink('link-465', 'block_tags', 'link-465');">block_tags</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L795"></a><tt class="py-lineno"> 795</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">True</tt> </tt>
-<a name="L796"></a><tt class="py-lineno"> 796</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">False</tt> </tt>
-</div><a name="L797"></a><tt class="py-lineno"> 797</tt> <tt class="py-line"> </tt>
-<a name="_element_name"></a><div id="_element_name-def"><a name="L798"></a><tt class="py-lineno"> 798</tt> <a class="py-toggle" href="#" id="_element_name-toggle" onclick="return toggle('_element_name');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_element_name">_element_name</a><tt class="py-op">(</tt><tt class="py-param">el</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="_element_name-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_element_name-expanded"><a name="L799"></a><tt class="py-lineno"> 799</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-466" class="py-name"><a title="lxml.etree
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-466', 'tag', 'link-49');">tag</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">in</tt> <tt id="link-467" class="py-name"><a title="lxml.html.defs" class="py-name" href="#" onclick="return doclink('link-467', 'defs', 'link-6');">defs</a></tt><tt class="py-op">.</tt><tt id="link-468" class="py-name" targets="Variable lxml.html.defs.block_tags=lxml.html.defs-module.html#block_tags"><a title="lxml.html.defs.block_tags" class="py-name" href="#" onclick="return doclink('link-468', 'block_tags', 'link-468');">block_tags</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L796"></a><tt class="py-lineno"> 796</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">True</tt> </tt>
+<a name="L797"></a><tt class="py-lineno"> 797</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">False</tt> </tt>
+</div><a name="L798"></a><tt class="py-lineno"> 798</tt> <tt class="py-line"> </tt>
+<a name="_element_name"></a><div id="_element_name-def"><a name="L799"></a><tt class="py-lineno"> 799</tt> <a class="py-toggle" href="#" id="_element_name-toggle" onclick="return toggle('_element_name');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#_element_name">_element_name</a><tt class="py-op">(</tt><tt class="py-param">el</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="_element_name-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="_element_name-expanded"><a name="L800"></a><tt class="py-lineno"> 800</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-469" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-466', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-467" class="py-name" targets="Class lxml.etree.CommentBase=lxml.etree.CommentBase-class.html"><a title="lxml.etree.CommentBase" class="py-name" href="#" onclick="return doclink('link-467', 'CommentBase', 'link-467');">CommentBase</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L800"></a><tt class="py-lineno"> 800</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'comment'</tt> </tt>
-<a name="L801"></a><tt class="py-lineno"> 801</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-468" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-468', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L802"></a><tt class="py-lineno"> 802</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'string'</tt> </tt>
-<a name="L803"></a><tt class="py-lineno"> 803</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L804"></a><tt class="py-lineno"> 804</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-469" class="py-name"><a title="lxml.etree._Comment.tag
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-469', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-470" class="py-name" targets="Class lxml.etree.CommentBase=lxml.etree.CommentBase-class.html"><a title="lxml.etree.CommentBase" class="py-name" href="#" onclick="return doclink('link-470', 'CommentBase', 'link-470');">CommentBase</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L801"></a><tt class="py-lineno"> 801</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'comment'</tt> </tt>
+<a name="L802"></a><tt class="py-lineno"> 802</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-471" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-471', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L803"></a><tt class="py-lineno"> 803</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'string'</tt> </tt>
+<a name="L804"></a><tt class="py-lineno"> 804</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L805"></a><tt class="py-lineno"> 805</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-472" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-469', 'tag', 'link-48');">tag</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L805"></a><tt class="py-lineno"> 805</tt> <tt class="py-line"> </tt>
-<a name="L806"></a><tt class="py-lineno"> 806</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
-<a name="L807"></a><tt class="py-lineno"> 807</tt> <tt class="py-line"><tt class="py-comment"># form handling</tt> </tt>
-<a name="L808"></a><tt class="py-lineno"> 808</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
-<a name="L809"></a><tt class="py-lineno"> 809</tt> <tt class="py-line"> </tt>
-<a name="FormElement"></a><div id="FormElement-def"><a name="L810"></a><tt class="py-lineno"> 810</tt> <a class="py-toggle" href="#" id="FormElement-toggle" onclick="return toggle('FormElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html">FormElement</a><tt class="py-op">(</tt><tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="FormElement-expanded"><a name="L811"></a><tt class="py-lineno"> 811</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L812"></a><tt class="py-lineno"> 812</tt> <tt class="py-line"><tt class="py-docstring"> Represents a <form> element.</tt> </tt>
-<a name="L813"></a><tt class="py-lineno"> 813</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L814"></a><tt class="py-lineno"> 814</tt> <tt class="py-line"> </tt>
-<a name="FormElement.inputs"></a><div id="FormElement.inputs-def"><a name="L815"></a><tt class="py-lineno"> 815</tt> <a class="py-toggle" href="#" id="FormElement.inputs-toggle" onclick="return toggle('FormElement.inputs');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#inputs">inputs</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement.inputs-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement.inputs-expanded"><a name="L816"></a><tt class="py-lineno"> 816</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L817"></a><tt class="py-lineno"> 817</tt> <tt class="py-line"><tt class="py-docstring"> Returns an accessor for all the input elements in the form.</tt> </tt>
-<a name="L818"></a><tt class="py-lineno"> 818</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L819"></a><tt class="py-lineno"> 819</tt> <tt class="py-line"><tt class="py-docstring"> See `InputGetter` for more information about the object.</tt> </tt>
-<a name="L820"></a><tt class="py-lineno"> 820</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L821"></a><tt class="py-lineno"> 821</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-470" class="py-name" targets="Class lxml.html.InputGetter=lxml.html.InputGetter-class.html"><a title="lxml.html.InputGetter" class="py-name" href="#" onclick="return doclink('link-470', 'InputGetter', 'link-470');">InputGetter</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L822"></a><tt class="py-lineno"> 822</tt> <tt class="py-line"> <tt id="link-471" class="py-name" targets="Variable lxml.html.FormElement.inputs=lxml.html.FormElement-class.html#inputs"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-471', 'inputs', 'link-471');">inputs</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-472" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-472', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-473" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-473', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">.</tt><tt id="link-474" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-474', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L823"></a><tt class="py-lineno"> 823</tt> <tt class="py-line"> </tt>
-<a name="FormElement._fields__get"></a><div id="FormElement._fields__get-def"><a name="L824"></a><tt class="py-lineno"> 824</tt> <a class="py-toggle" href="#" id="FormElement._fields__get-toggle" onclick="return toggle('FormElement._fields__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_fields__get">_fields__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._fields__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._fields__get-expanded"><a name="L825"></a><tt class="py-lineno"> 825</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L826"></a><tt class="py-lineno"> 826</tt> <tt class="py-line"><tt class="py-docstring"> Dictionary-like object that represents all the fields in this</tt> </tt>
-<a name="L827"></a><tt class="py-lineno"> 827</tt> <tt class="py-line"><tt class="py-docstring"> form. You can set values in this dictionary to effect the</tt> </tt>
-<a name="L828"></a><tt class="py-lineno"> 828</tt> <tt class="py-line"><tt class="py-docstring"> form.</tt> </tt>
-<a name="L829"></a><tt class="py-lineno"> 829</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L830"></a><tt class="py-lineno"> 830</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-475" class="py-name" targets="Class lxml.html.FieldsDict=lxml.html.FieldsDict-class.html"><a title="lxml.html.FieldsDict" class="py-name" href="#" onclick="return doclink('link-475', 'FieldsDict', 'link-475');">FieldsDict</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-476" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-476', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="FormElement._fields__set"></a><div id="FormElement._fields__set-def"><a name="L831"></a><tt class="py-lineno"> 831</tt> <a class="py-toggle" href="#" id="FormElement._fields__set-toggle" onclick="return toggle('FormElement._fields__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_fields__set">_fields__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._fields__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._fields__set-expanded"><a name="L832"></a><tt class="py-lineno"> 832</tt> <tt class="py-line"> <tt class="py-name">prev_keys</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-477" class="py-name" targets="Variable lxml.html.FormElement.fields=lxml.html.FormElement-class.html#fields"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-477', 'fields', 'link-477');">fields</a></tt><tt class="py-op">.</tt><tt id="link-478" class="py-name"><a title="lxml.etree._Attrib.keys
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-472', 'tag', 'link-49');">tag</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L806"></a><tt class="py-lineno"> 806</tt> <tt class="py-line"> </tt>
+<a name="L807"></a><tt class="py-lineno"> 807</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
+<a name="L808"></a><tt class="py-lineno"> 808</tt> <tt class="py-line"><tt class="py-comment"># form handling</tt> </tt>
+<a name="L809"></a><tt class="py-lineno"> 809</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
+<a name="L810"></a><tt class="py-lineno"> 810</tt> <tt class="py-line"> </tt>
+<a name="FormElement"></a><div id="FormElement-def"><a name="L811"></a><tt class="py-lineno"> 811</tt> <a class="py-toggle" href="#" id="FormElement-toggle" onclick="return toggle('FormElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html">FormElement</a><tt class="py-op">(</tt><tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="FormElement-expanded"><a name="L812"></a><tt class="py-lineno"> 812</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L813"></a><tt class="py-lineno"> 813</tt> <tt class="py-line"><tt class="py-docstring"> Represents a <form> element.</tt> </tt>
+<a name="L814"></a><tt class="py-lineno"> 814</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L815"></a><tt class="py-lineno"> 815</tt> <tt class="py-line"> </tt>
+<a name="FormElement.inputs"></a><div id="FormElement.inputs-def"><a name="L816"></a><tt class="py-lineno"> 816</tt> <a class="py-toggle" href="#" id="FormElement.inputs-toggle" onclick="return toggle('FormElement.inputs');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#inputs">inputs</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement.inputs-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement.inputs-expanded"><a name="L817"></a><tt class="py-lineno"> 817</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L818"></a><tt class="py-lineno"> 818</tt> <tt class="py-line"><tt class="py-docstring"> Returns an accessor for all the input elements in the form.</tt> </tt>
+<a name="L819"></a><tt class="py-lineno"> 819</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L820"></a><tt class="py-lineno"> 820</tt> <tt class="py-line"><tt class="py-docstring"> See `InputGetter` for more information about the object.</tt> </tt>
+<a name="L821"></a><tt class="py-lineno"> 821</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L822"></a><tt class="py-lineno"> 822</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-473" class="py-name" targets="Class lxml.html.InputGetter=lxml.html.InputGetter-class.html"><a title="lxml.html.InputGetter" class="py-name" href="#" onclick="return doclink('link-473', 'InputGetter', 'link-473');">InputGetter</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L823"></a><tt class="py-lineno"> 823</tt> <tt class="py-line"> <tt id="link-474" class="py-name" targets="Variable lxml.html.FormElement.inputs=lxml.html.FormElement-class.html#inputs"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-474', 'inputs', 'link-474');">inputs</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-475" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-475', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-476" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-476', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">.</tt><tt id="link-477" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-477', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L824"></a><tt class="py-lineno"> 824</tt> <tt class="py-line"> </tt>
+<a name="FormElement._fields__get"></a><div id="FormElement._fields__get-def"><a name="L825"></a><tt class="py-lineno"> 825</tt> <a class="py-toggle" href="#" id="FormElement._fields__get-toggle" onclick="return toggle('FormElement._fields__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_fields__get">_fields__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._fields__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._fields__get-expanded"><a name="L826"></a><tt class="py-lineno"> 826</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L827"></a><tt class="py-lineno"> 827</tt> <tt class="py-line"><tt class="py-docstring"> Dictionary-like object that represents all the fields in this</tt> </tt>
+<a name="L828"></a><tt class="py-lineno"> 828</tt> <tt class="py-line"><tt class="py-docstring"> form. You can set values in this dictionary to effect the</tt> </tt>
+<a name="L829"></a><tt class="py-lineno"> 829</tt> <tt class="py-line"><tt class="py-docstring"> form.</tt> </tt>
+<a name="L830"></a><tt class="py-lineno"> 830</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L831"></a><tt class="py-lineno"> 831</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-478" class="py-name" targets="Class lxml.html.FieldsDict=lxml.html.FieldsDict-class.html"><a title="lxml.html.FieldsDict" class="py-name" href="#" onclick="return doclink('link-478', 'FieldsDict', 'link-478');">FieldsDict</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-479" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-479', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="FormElement._fields__set"></a><div id="FormElement._fields__set-def"><a name="L832"></a><tt class="py-lineno"> 832</tt> <a class="py-toggle" href="#" id="FormElement._fields__set-toggle" onclick="return toggle('FormElement._fields__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_fields__set">_fields__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._fields__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._fields__set-expanded"><a name="L833"></a><tt class="py-lineno"> 833</tt> <tt class="py-line"> <tt class="py-name">prev_keys</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-480" class="py-name" targets="Variable lxml.html.FormElement.fields=lxml.html.FormElement-class.html#fields"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-480', 'fields', 'link-480');">fields</a></tt><tt class="py-op">.</tt><tt id="link-481" class="py-name"><a title="lxml.etree._Attrib.keys
lxml.etree._Element.keys
lxml.etree._IDDict.keys
lxml.html.FieldsDict.keys
-lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-478', 'keys', 'link-272');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L833"></a><tt class="py-lineno"> 833</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">key</tt><tt class="py-op">,</tt> <tt id="link-479" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-481', 'keys', 'link-275');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L834"></a><tt class="py-lineno"> 834</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">key</tt><tt class="py-op">,</tt> <tt id="link-482" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-479', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">in</tt> <tt id="link-480" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-482', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">in</tt> <tt id="link-483" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-480', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-481" class="py-name"><a title="lxml.etree._Attrib.items
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-483', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-484" class="py-name"><a title="lxml.etree._Attrib.items
lxml.etree._Element.items
-lxml.etree._IDDict.items" class="py-name" href="#" onclick="return doclink('link-481', 'items', 'link-279');">items</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L834"></a><tt class="py-lineno"> 834</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">key</tt> <tt class="py-keyword">in</tt> <tt class="py-name">prev_keys</tt><tt class="py-op">:</tt> </tt>
-<a name="L835"></a><tt class="py-lineno"> 835</tt> <tt class="py-line"> <tt class="py-name">prev_keys</tt><tt class="py-op">.</tt><tt id="link-482" class="py-name"><a title="lxml.etree._Element.remove
+lxml.etree._IDDict.items" class="py-name" href="#" onclick="return doclink('link-484', 'items', 'link-282');">items</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L835"></a><tt class="py-lineno"> 835</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">key</tt> <tt class="py-keyword">in</tt> <tt class="py-name">prev_keys</tt><tt class="py-op">:</tt> </tt>
+<a name="L836"></a><tt class="py-lineno"> 836</tt> <tt class="py-line"> <tt class="py-name">prev_keys</tt><tt class="py-op">.</tt><tt id="link-485" class="py-name"><a title="lxml.etree._Element.remove
lxml.html.CheckboxValues.remove
-lxml.html.MultipleSelectOptions.remove" class="py-name" href="#" onclick="return doclink('link-482', 'remove', 'link-108');">remove</a></tt><tt class="py-op">(</tt><tt class="py-name">key</tt><tt class="py-op">)</tt> </tt>
-<a name="L836"></a><tt class="py-lineno"> 836</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-483" class="py-name"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-483', 'fields', 'link-477');">fields</a></tt><tt class="py-op">[</tt><tt class="py-name">key</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-484" class="py-name"><a title="lxml.html.CheckboxGroup.value
-lxml.html.InputElement.value
-lxml.html.RadioGroup.value
-lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-484', 'value', 'link-172');">value</a></tt> </tt>
-<a name="L837"></a><tt class="py-lineno"> 837</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">key</tt> <tt class="py-keyword">in</tt> <tt class="py-name">prev_keys</tt><tt class="py-op">:</tt> </tt>
-<a name="L838"></a><tt class="py-lineno"> 838</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">key</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L839"></a><tt class="py-lineno"> 839</tt> <tt class="py-line"> <tt class="py-comment"># Case of an unnamed input; these aren't really</tt> </tt>
-<a name="L840"></a><tt class="py-lineno"> 840</tt> <tt class="py-line"> <tt class="py-comment"># expressed in form_values() anyway.</tt> </tt>
-<a name="L841"></a><tt class="py-lineno"> 841</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
-<a name="L842"></a><tt class="py-lineno"> 842</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-485" class="py-name"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-485', 'fields', 'link-477');">fields</a></tt><tt class="py-op">[</tt><tt class="py-name">key</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-</div><a name="L843"></a><tt class="py-lineno"> 843</tt> <tt class="py-line"> </tt>
-<a name="L844"></a><tt class="py-lineno"> 844</tt> <tt class="py-line"> <tt id="link-486" class="py-name"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-486', 'fields', 'link-477');">fields</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-487" class="py-name" targets="Method lxml.html.FormElement._fields__get()=lxml.html.FormElement-class.html#_fields__get"><a title="lxml.html.FormElement._fields__get" class="py-name" href="#" onclick="return doclink('link-487', '_fields__get', 'link-487');">_fields__get</a></tt><tt class="py-op">,</tt> <tt id="link-488" class="py-name" targets="Method lxml.html.FormElement._fields__set()=lxml.html.FormElement-class.html#_fields__set"><a title="lxml.html.FormElement._fields__set" class="py-name" href="#" onclick="return doclink('link-488', '_fields__set', 'link-488');">_fields__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-489" class="py-name"><a title="lxml.html.FormElement._fields__get" class="py-name" href="#" onclick="return doclink('link-489', '_fields__get', 'link-487');">_fields__get</a></tt><tt class="py-op">.</tt><tt id="link-490" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-490', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L845"></a><tt class="py-lineno"> 845</tt> <tt class="py-line"> </tt>
-<a name="FormElement._name"></a><div id="FormElement._name-def"><a name="L846"></a><tt class="py-lineno"> 846</tt> <a class="py-toggle" href="#" id="FormElement._name-toggle" onclick="return toggle('FormElement._name');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_name">_name</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._name-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._name-expanded"><a name="L847"></a><tt class="py-lineno"> 847</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-491" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.MultipleSelectOptions.remove" class="py-name" href="#" onclick="return doclink('link-485', 'remove', 'link-109');">remove</a></tt><tt class="py-op">(</tt><tt class="py-name">key</tt><tt class="py-op">)</tt> </tt>
+<a name="L837"></a><tt class="py-lineno"> 837</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-486" class="py-name"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-486', 'fields', 'link-480');">fields</a></tt><tt class="py-op">[</tt><tt class="py-name">key</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-487" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputElement.value
+lxml.html.RadioGroup.value
+lxml.html.SelectElement.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-487', 'value', 'link-173');">value</a></tt> </tt>
+<a name="L838"></a><tt class="py-lineno"> 838</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">key</tt> <tt class="py-keyword">in</tt> <tt class="py-name">prev_keys</tt><tt class="py-op">:</tt> </tt>
+<a name="L839"></a><tt class="py-lineno"> 839</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">key</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L840"></a><tt class="py-lineno"> 840</tt> <tt class="py-line"> <tt class="py-comment"># Case of an unnamed input; these aren't really</tt> </tt>
+<a name="L841"></a><tt class="py-lineno"> 841</tt> <tt class="py-line"> <tt class="py-comment"># expressed in form_values() anyway.</tt> </tt>
+<a name="L842"></a><tt class="py-lineno"> 842</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
+<a name="L843"></a><tt class="py-lineno"> 843</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-488" class="py-name"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-488', 'fields', 'link-480');">fields</a></tt><tt class="py-op">[</tt><tt class="py-name">key</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+</div><a name="L844"></a><tt class="py-lineno"> 844</tt> <tt class="py-line"> </tt>
+<a name="L845"></a><tt class="py-lineno"> 845</tt> <tt class="py-line"> <tt id="link-489" class="py-name"><a title="lxml.html.FormElement.fields" class="py-name" href="#" onclick="return doclink('link-489', 'fields', 'link-480');">fields</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-490" class="py-name" targets="Method lxml.html.FormElement._fields__get()=lxml.html.FormElement-class.html#_fields__get"><a title="lxml.html.FormElement._fields__get" class="py-name" href="#" onclick="return doclink('link-490', '_fields__get', 'link-490');">_fields__get</a></tt><tt class="py-op">,</tt> <tt id="link-491" class="py-name" targets="Method lxml.html.FormElement._fields__set()=lxml.html.FormElement-class.html#_fields__set"><a title="lxml.html.FormElement._fields__set" class="py-name" href="#" onclick="return doclink('link-491', '_fields__set', 'link-491');">_fields__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-492" class="py-name"><a title="lxml.html.FormElement._fields__get" class="py-name" href="#" onclick="return doclink('link-492', '_fields__get', 'link-490');">_fields__get</a></tt><tt class="py-op">.</tt><tt id="link-493" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-493', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L846"></a><tt class="py-lineno"> 846</tt> <tt class="py-line"> </tt>
+<a name="FormElement._name"></a><div id="FormElement._name-def"><a name="L847"></a><tt class="py-lineno"> 847</tt> <a class="py-toggle" href="#" id="FormElement._name-toggle" onclick="return toggle('FormElement._name');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_name">_name</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._name-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._name-expanded"><a name="L848"></a><tt class="py-lineno"> 848</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-494" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-491', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L848"></a><tt class="py-lineno"> 848</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-492" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-494', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L849"></a><tt class="py-lineno"> 849</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-495" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-492', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">)</tt> </tt>
-<a name="L849"></a><tt class="py-lineno"> 849</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-493" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-495', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">)</tt> </tt>
+<a name="L850"></a><tt class="py-lineno"> 850</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-496" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-493', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L850"></a><tt class="py-lineno"> 850</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'#'</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-494" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-496', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L851"></a><tt class="py-lineno"> 851</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'#'</tt> <tt class="py-op">+</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-497" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-494', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
-<a name="L851"></a><tt class="py-lineno"> 851</tt> <tt class="py-line"> <tt id="link-495" class="py-name"><a title="lxml.html.HtmlMixin.forms
-lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-495', 'forms', 'link-64');">forms</a></tt> <tt class="py-op">=</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-496" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-496', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-497" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-497', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt class="py-string">'form'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L852"></a><tt class="py-lineno"> 852</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-498" class="py-name"><a title="lxml.html.HtmlMixin.forms
-lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-498', 'forms', 'link-64');">forms</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L853"></a><tt class="py-lineno"> 853</tt> <tt class="py-line"> <tt id="link-499" class="py-name"><a title="lxml.html.HtmlMixin.forms
-lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-499', 'forms', 'link-64');">forms</a></tt> <tt class="py-op">=</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-500" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-500', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-501" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-501', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt class="py-string">'{%s}form'</tt> <tt class="py-op">%</tt> <tt id="link-502" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-502', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L854"></a><tt class="py-lineno"> 854</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-503" class="py-name"><a title="str" class="py-name" href="#" onclick="return doclink('link-503', 'str', 'link-11');">str</a></tt><tt class="py-op">(</tt><tt id="link-504" class="py-name"><a title="lxml.html.HtmlMixin.forms
-lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-504', 'forms', 'link-64');">forms</a></tt><tt class="py-op">.</tt><tt id="link-505" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-505', 'index', 'link-130');">index</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L855"></a><tt class="py-lineno"> 855</tt> <tt class="py-line"> </tt>
-<a name="FormElement.form_values"></a><div id="FormElement.form_values-def"><a name="L856"></a><tt class="py-lineno"> 856</tt> <a class="py-toggle" href="#" id="FormElement.form_values-toggle" onclick="return toggle('FormElement.form_values');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#form_values">form_values</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement.form_values-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement.form_values-expanded"><a name="L857"></a><tt class="py-lineno"> 857</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L858"></a><tt class="py-lineno"> 858</tt> <tt class="py-line"><tt class="py-docstring"> Return a list of tuples of the field values for the form.</tt> </tt>
-<a name="L859"></a><tt class="py-lineno"> 859</tt> <tt class="py-line"><tt class="py-docstring"> This is suitable to be passed to ``urllib.urlencode()``.</tt> </tt>
-<a name="L860"></a><tt class="py-lineno"> 860</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L861"></a><tt class="py-lineno"> 861</tt> <tt class="py-line"> <tt class="py-name">results</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
-<a name="L862"></a><tt class="py-lineno"> 862</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-506" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-506', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L863"></a><tt class="py-lineno"> 863</tt> <tt class="py-line"> <tt id="link-507" class="py-name"><a title="lxml.etree.DTD.name
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-497', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
+<a name="L852"></a><tt class="py-lineno"> 852</tt> <tt class="py-line"> <tt id="link-498" class="py-name"><a title="lxml.html.HtmlMixin.forms
+lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-498', 'forms', 'link-65');">forms</a></tt> <tt class="py-op">=</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-499" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-499', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-500" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-500', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt class="py-string">'form'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L853"></a><tt class="py-lineno"> 853</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-501" class="py-name"><a title="lxml.html.HtmlMixin.forms
+lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-501', 'forms', 'link-65');">forms</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L854"></a><tt class="py-lineno"> 854</tt> <tt class="py-line"> <tt id="link-502" class="py-name"><a title="lxml.html.HtmlMixin.forms
+lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-502', 'forms', 'link-65');">forms</a></tt> <tt class="py-op">=</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-503" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-503', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-504" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-504', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt class="py-string">'{%s}form'</tt> <tt class="py-op">%</tt> <tt id="link-505" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-505', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L855"></a><tt class="py-lineno"> 855</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-506" class="py-name"><a title="str" class="py-name" href="#" onclick="return doclink('link-506', 'str', 'link-11');">str</a></tt><tt class="py-op">(</tt><tt id="link-507" class="py-name"><a title="lxml.html.HtmlMixin.forms
+lxml.html.clean.Cleaner.forms" class="py-name" href="#" onclick="return doclink('link-507', 'forms', 'link-65');">forms</a></tt><tt class="py-op">.</tt><tt id="link-508" class="py-name"><a title="lxml.etree._Element.index" class="py-name" href="#" onclick="return doclink('link-508', 'index', 'link-131');">index</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L856"></a><tt class="py-lineno"> 856</tt> <tt class="py-line"> </tt>
+<a name="FormElement.form_values"></a><div id="FormElement.form_values-def"><a name="L857"></a><tt class="py-lineno"> 857</tt> <a class="py-toggle" href="#" id="FormElement.form_values-toggle" onclick="return toggle('FormElement.form_values');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#form_values">form_values</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement.form_values-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement.form_values-expanded"><a name="L858"></a><tt class="py-lineno"> 858</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L859"></a><tt class="py-lineno"> 859</tt> <tt class="py-line"><tt class="py-docstring"> Return a list of tuples of the field values for the form.</tt> </tt>
+<a name="L860"></a><tt class="py-lineno"> 860</tt> <tt class="py-line"><tt class="py-docstring"> This is suitable to be passed to ``urllib.urlencode()``.</tt> </tt>
+<a name="L861"></a><tt class="py-lineno"> 861</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L862"></a><tt class="py-lineno"> 862</tt> <tt class="py-line"> <tt class="py-name">results</tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
+<a name="L863"></a><tt class="py-lineno"> 863</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-509" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-509', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L864"></a><tt class="py-lineno"> 864</tt> <tt class="py-line"> <tt id="link-510" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-507', 'name', 'link-230');">name</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-508" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-510', 'name', 'link-233');">name</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-511" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-508', 'name', 'link-230');">name</a></tt> </tt>
-<a name="L864"></a><tt class="py-lineno"> 864</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-509" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-511', 'name', 'link-233');">name</a></tt> </tt>
+<a name="L865"></a><tt class="py-lineno"> 865</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-512" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-509', 'name', 'link-230');">name</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L865"></a><tt class="py-lineno"> 865</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
-<a name="L866"></a><tt class="py-lineno"> 866</tt> <tt class="py-line"> <tt id="link-510" class="py-name"><a title="lxml.etree._Comment.tag
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-512', 'name', 'link-233');">name</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L866"></a><tt class="py-lineno"> 866</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
+<a name="L867"></a><tt class="py-lineno"> 867</tt> <tt class="py-line"> <tt id="link-513" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-510', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-511" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-513', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">_nons</tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-514" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-511', 'tag', 'link-48');">tag</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L867"></a><tt class="py-lineno"> 867</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-512" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-514', 'tag', 'link-49');">tag</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L868"></a><tt class="py-lineno"> 868</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-515" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-512', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'textarea'</tt><tt class="py-op">:</tt> </tt>
-<a name="L868"></a><tt class="py-lineno"> 868</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-513" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-513', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-514" class="py-name"><a title="lxml.etree.DTD.name
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-515', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'textarea'</tt><tt class="py-op">:</tt> </tt>
+<a name="L869"></a><tt class="py-lineno"> 869</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-516" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-516', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-517" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-514', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-515" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-517', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-518" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-515', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L869"></a><tt class="py-lineno"> 869</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-516" class="py-name"><a title="lxml.etree._Comment.tag
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-518', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L870"></a><tt class="py-lineno"> 870</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-519" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-516', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'select'</tt><tt class="py-op">:</tt> </tt>
-<a name="L870"></a><tt class="py-lineno"> 870</tt> <tt class="py-line"> <tt id="link-517" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-519', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'select'</tt><tt class="py-op">:</tt> </tt>
+<a name="L871"></a><tt class="py-lineno"> 871</tt> <tt class="py-line"> <tt id="link-520" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-517', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-518" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-520', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-521" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-518', 'value', 'link-172');">value</a></tt> </tt>
-<a name="L871"></a><tt class="py-lineno"> 871</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-519" class="py-name" targets="Variable lxml.html.SelectElement.multiple=lxml.html.SelectElement-class.html#multiple"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-519', 'multiple', 'link-519');">multiple</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L872"></a><tt class="py-lineno"> 872</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-520" class="py-name" targets="Variable lxml.tests.test_objectify.v=lxml.tests.test_objectify-module.html#v"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-520', 'v', 'link-520');">v</a></tt> <tt class="py-keyword">in</tt> <tt id="link-521" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-521', 'value', 'link-173');">value</a></tt> </tt>
+<a name="L872"></a><tt class="py-lineno"> 872</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-522" class="py-name" targets="Variable lxml.html.SelectElement.multiple=lxml.html.SelectElement-class.html#multiple"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-522', 'multiple', 'link-522');">multiple</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L873"></a><tt class="py-lineno"> 873</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt id="link-523" class="py-name" targets="Variable lxml.tests.test_objectify.v=lxml.tests.test_objectify-module.html#v"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-523', 'v', 'link-523');">v</a></tt> <tt class="py-keyword">in</tt> <tt id="link-524" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-521', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L873"></a><tt class="py-lineno"> 873</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-522" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-522', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-523" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-524', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L874"></a><tt class="py-lineno"> 874</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-525" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-525', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-526" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-523', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt id="link-524" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-524', 'v', 'link-520');">v</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L874"></a><tt class="py-lineno"> 874</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-525" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-526', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt id="link-527" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-527', 'v', 'link-523');">v</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L875"></a><tt class="py-lineno"> 875</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-528" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-525', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L875"></a><tt class="py-lineno"> 875</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-526" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-526', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-527" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-528', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L876"></a><tt class="py-lineno"> 876</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-529" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-529', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-530" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-527', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-528" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-530', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-531" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-528', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L876"></a><tt class="py-lineno"> 876</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L877"></a><tt class="py-lineno"> 877</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt id="link-529" class="py-name"><a title="lxml.etree._Comment.tag
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-531', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L877"></a><tt class="py-lineno"> 877</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L878"></a><tt class="py-lineno"> 878</tt> <tt class="py-line"> <tt class="py-keyword">assert</tt> <tt id="link-532" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-529', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'input'</tt><tt class="py-op">,</tt> <tt class="py-op">(</tt> </tt>
-<a name="L878"></a><tt class="py-lineno"> 878</tt> <tt class="py-line"> <tt class="py-string">"Unexpected tag: %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">el</tt><tt class="py-op">)</tt> </tt>
-<a name="L879"></a><tt class="py-lineno"> 879</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-530" class="py-name" targets="Variable lxml.html.InputElement.checkable=lxml.html.InputElement-class.html#checkable"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-530', 'checkable', 'link-530');">checkable</a></tt> <tt class="py-keyword">and</tt> <tt class="py-keyword">not</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-531" class="py-name" targets="Variable lxml.html.InputElement.checked=lxml.html.InputElement-class.html#checked"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-531', 'checked', 'link-531');">checked</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L880"></a><tt class="py-lineno"> 880</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
-<a name="L881"></a><tt class="py-lineno"> 881</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-532" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-532', 'type', 'link-237');">type</a></tt> <tt class="py-keyword">in</tt> <tt class="py-op">(</tt><tt class="py-string">'submit'</tt><tt class="py-op">,</tt> <tt class="py-string">'image'</tt><tt class="py-op">,</tt> <tt class="py-string">'reset'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L882"></a><tt class="py-lineno"> 882</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
-<a name="L883"></a><tt class="py-lineno"> 883</tt> <tt class="py-line"> <tt id="link-533" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-532', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'input'</tt><tt class="py-op">,</tt> <tt class="py-op">(</tt> </tt>
+<a name="L879"></a><tt class="py-lineno"> 879</tt> <tt class="py-line"> <tt class="py-string">"Unexpected tag: %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">el</tt><tt class="py-op">)</tt> </tt>
+<a name="L880"></a><tt class="py-lineno"> 880</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-533" class="py-name" targets="Variable lxml.html.InputElement.checkable=lxml.html.InputElement-class.html#checkable"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-533', 'checkable', 'link-533');">checkable</a></tt> <tt class="py-keyword">and</tt> <tt class="py-keyword">not</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-534" class="py-name" targets="Variable lxml.html.InputElement.checked=lxml.html.InputElement-class.html#checked"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-534', 'checked', 'link-534');">checked</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L881"></a><tt class="py-lineno"> 881</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
+<a name="L882"></a><tt class="py-lineno"> 882</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-535" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-535', 'type', 'link-240');">type</a></tt> <tt class="py-keyword">in</tt> <tt class="py-op">(</tt><tt class="py-string">'submit'</tt><tt class="py-op">,</tt> <tt class="py-string">'image'</tt><tt class="py-op">,</tt> <tt class="py-string">'reset'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L883"></a><tt class="py-lineno"> 883</tt> <tt class="py-line"> <tt class="py-keyword">continue</tt> </tt>
+<a name="L884"></a><tt class="py-lineno"> 884</tt> <tt class="py-line"> <tt id="link-536" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-533', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-534" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-536', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-537" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-534', 'value', 'link-172');">value</a></tt> </tt>
-<a name="L884"></a><tt class="py-lineno"> 884</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-535" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-537', 'value', 'link-173');">value</a></tt> </tt>
+<a name="L885"></a><tt class="py-lineno"> 885</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-538" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-535', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L885"></a><tt class="py-lineno"> 885</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-536" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-536', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-537" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-538', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L886"></a><tt class="py-lineno"> 886</tt> <tt class="py-line"> <tt class="py-name">results</tt><tt class="py-op">.</tt><tt id="link-539" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-539', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt class="py-op">(</tt><tt id="link-540" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-537', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-538" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-540', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-541" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-538', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L886"></a><tt class="py-lineno"> 886</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">results</tt> </tt>
-</div><a name="L887"></a><tt class="py-lineno"> 887</tt> <tt class="py-line"> </tt>
-<a name="FormElement._action__get"></a><div id="FormElement._action__get-def"><a name="L888"></a><tt class="py-lineno"> 888</tt> <a class="py-toggle" href="#" id="FormElement._action__get-toggle" onclick="return toggle('FormElement._action__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_action__get">_action__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._action__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._action__get-expanded"><a name="L889"></a><tt class="py-lineno"> 889</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L890"></a><tt class="py-lineno"> 890</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the form's ``action`` attribute.</tt> </tt>
-<a name="L891"></a><tt class="py-lineno"> 891</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L892"></a><tt class="py-lineno"> 892</tt> <tt class="py-line"> <tt id="link-539" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-539', 'base_url', 'link-59');">base_url</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-540" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-540', 'base_url', 'link-59');">base_url</a></tt> </tt>
-<a name="L893"></a><tt class="py-lineno"> 893</tt> <tt class="py-line"> <tt id="link-541" class="py-name" targets="Variable lxml.html.FormElement.action=lxml.html.FormElement-class.html#action"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-541', 'action', 'link-541');">action</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-542" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-541', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L887"></a><tt class="py-lineno"> 887</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">results</tt> </tt>
+</div><a name="L888"></a><tt class="py-lineno"> 888</tt> <tt class="py-line"> </tt>
+<a name="FormElement._action__get"></a><div id="FormElement._action__get-def"><a name="L889"></a><tt class="py-lineno"> 889</tt> <a class="py-toggle" href="#" id="FormElement._action__get-toggle" onclick="return toggle('FormElement._action__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_action__get">_action__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._action__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._action__get-expanded"><a name="L890"></a><tt class="py-lineno"> 890</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L891"></a><tt class="py-lineno"> 891</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the form's ``action`` attribute.</tt> </tt>
+<a name="L892"></a><tt class="py-lineno"> 892</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L893"></a><tt class="py-lineno"> 893</tt> <tt class="py-line"> <tt id="link-542" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-542', 'base_url', 'link-60');">base_url</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-543" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-543', 'base_url', 'link-60');">base_url</a></tt> </tt>
+<a name="L894"></a><tt class="py-lineno"> 894</tt> <tt class="py-line"> <tt id="link-544" class="py-name" targets="Variable lxml.html.FormElement.action=lxml.html.FormElement-class.html#action"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-544', 'action', 'link-544');">action</a></tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-545" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-542', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'action'</tt><tt class="py-op">)</tt> </tt>
-<a name="L894"></a><tt class="py-lineno"> 894</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-543" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-543', 'base_url', 'link-59');">base_url</a></tt> <tt class="py-keyword">and</tt> <tt id="link-544" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-544', 'action', 'link-541');">action</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L895"></a><tt class="py-lineno"> 895</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-545" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-545', 'base_url', 'link-59');">base_url</a></tt><tt class="py-op">,</tt> <tt id="link-546" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-546', 'action', 'link-541');">action</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L896"></a><tt class="py-lineno"> 896</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L897"></a><tt class="py-lineno"> 897</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-547" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-547', 'action', 'link-541');">action</a></tt> </tt>
-</div><a name="FormElement._action__set"></a><div id="FormElement._action__set-def"><a name="L898"></a><tt class="py-lineno"> 898</tt> <a class="py-toggle" href="#" id="FormElement._action__set-toggle" onclick="return toggle('FormElement._action__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_action__set">_action__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._action__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._action__set-expanded"><a name="L899"></a><tt class="py-lineno"> 899</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-548" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-548', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'action'</tt><tt class="py-op">,</tt> <tt id="link-549" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-545', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'action'</tt><tt class="py-op">)</tt> </tt>
+<a name="L895"></a><tt class="py-lineno"> 895</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-546" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-546', 'base_url', 'link-60');">base_url</a></tt> <tt class="py-keyword">and</tt> <tt id="link-547" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-547', 'action', 'link-544');">action</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L896"></a><tt class="py-lineno"> 896</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urljoin</tt><tt class="py-op">(</tt><tt id="link-548" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-548', 'base_url', 'link-60');">base_url</a></tt><tt class="py-op">,</tt> <tt id="link-549" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-549', 'action', 'link-544');">action</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L897"></a><tt class="py-lineno"> 897</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L898"></a><tt class="py-lineno"> 898</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-550" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-550', 'action', 'link-544');">action</a></tt> </tt>
+</div><a name="FormElement._action__set"></a><div id="FormElement._action__set-def"><a name="L899"></a><tt class="py-lineno"> 899</tt> <a class="py-toggle" href="#" id="FormElement._action__set-toggle" onclick="return toggle('FormElement._action__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_action__set">_action__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._action__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._action__set-expanded"><a name="L900"></a><tt class="py-lineno"> 900</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-551" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-551', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'action'</tt><tt class="py-op">,</tt> <tt id="link-552" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-549', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="FormElement._action__del"></a><div id="FormElement._action__del-def"><a name="L900"></a><tt class="py-lineno"> 900</tt> <a class="py-toggle" href="#" id="FormElement._action__del-toggle" onclick="return toggle('FormElement._action__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_action__del">_action__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._action__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._action__del-expanded"><a name="L901"></a><tt class="py-lineno"> 901</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'action'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-550" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-552', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="FormElement._action__del"></a><div id="FormElement._action__del-def"><a name="L901"></a><tt class="py-lineno"> 901</tt> <a class="py-toggle" href="#" id="FormElement._action__del-toggle" onclick="return toggle('FormElement._action__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_action__del">_action__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._action__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._action__del-expanded"><a name="L902"></a><tt class="py-lineno"> 902</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'action'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-553" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-550', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L902"></a><tt class="py-lineno"> 902</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-551" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-553', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L903"></a><tt class="py-lineno"> 903</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-554" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-551', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'action'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L903"></a><tt class="py-lineno"> 903</tt> <tt class="py-line"> <tt id="link-552" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-552', 'action', 'link-541');">action</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-553" class="py-name" targets="Method lxml.html.FormElement._action__get()=lxml.html.FormElement-class.html#_action__get"><a title="lxml.html.FormElement._action__get" class="py-name" href="#" onclick="return doclink('link-553', '_action__get', 'link-553');">_action__get</a></tt><tt class="py-op">,</tt> <tt id="link-554" class="py-name" targets="Method lxml.html.FormElement._action__set()=lxml.html.FormElement-class.html#_action__set"><a title="lxml.html.FormElement._action__set" class="py-name" href="#" onclick="return doclink('link-554', '_action__set', 'link-554');">_action__set</a></tt><tt class="py-op">,</tt> <tt id="link-555" class="py-name" targets="Method lxml.html.FormElement._action__del()=lxml.html.FormElement-class.html#_action__del"><a title="lxml.html.FormElement._action__del" class="py-name" href="#" onclick="return doclink('link-555', '_action__del', 'link-555');">_action__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-556" class="py-name"><a title="lxml.html.FormElement._action__get" class="py-name" href="#" onclick="return doclink('link-556', '_action__get', 'link-553');">_action__get</a></tt><tt class="py-op">.</tt><tt id="link-557" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-557', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L904"></a><tt class="py-lineno"> 904</tt> <tt class="py-line"> </tt>
-<a name="FormElement._method__get"></a><div id="FormElement._method__get-def"><a name="L905"></a><tt class="py-lineno"> 905</tt> <a class="py-toggle" href="#" id="FormElement._method__get-toggle" onclick="return toggle('FormElement._method__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_method__get">_method__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._method__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._method__get-expanded"><a name="L906"></a><tt class="py-lineno"> 906</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L907"></a><tt class="py-lineno"> 907</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the form's method. Always returns a capitalized</tt> </tt>
-<a name="L908"></a><tt class="py-lineno"> 908</tt> <tt class="py-line"><tt class="py-docstring"> string, and defaults to ``'GET'``</tt> </tt>
-<a name="L909"></a><tt class="py-lineno"> 909</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L910"></a><tt class="py-lineno"> 910</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-558" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-554', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'action'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L904"></a><tt class="py-lineno"> 904</tt> <tt class="py-line"> <tt id="link-555" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-555', 'action', 'link-544');">action</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-556" class="py-name" targets="Method lxml.html.FormElement._action__get()=lxml.html.FormElement-class.html#_action__get"><a title="lxml.html.FormElement._action__get" class="py-name" href="#" onclick="return doclink('link-556', '_action__get', 'link-556');">_action__get</a></tt><tt class="py-op">,</tt> <tt id="link-557" class="py-name" targets="Method lxml.html.FormElement._action__set()=lxml.html.FormElement-class.html#_action__set"><a title="lxml.html.FormElement._action__set" class="py-name" href="#" onclick="return doclink('link-557', '_action__set', 'link-557');">_action__set</a></tt><tt class="py-op">,</tt> <tt id="link-558" class="py-name" targets="Method lxml.html.FormElement._action__del()=lxml.html.FormElement-class.html#_action__del"><a title="lxml.html.FormElement._action__del" class="py-name" href="#" onclick="return doclink('link-558', '_action__del', 'link-558');">_action__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-559" class="py-name"><a title="lxml.html.FormElement._action__get" class="py-name" href="#" onclick="return doclink('link-559', '_action__get', 'link-556');">_action__get</a></tt><tt class="py-op">.</tt><tt id="link-560" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-560', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L905"></a><tt class="py-lineno"> 905</tt> <tt class="py-line"> </tt>
+<a name="FormElement._method__get"></a><div id="FormElement._method__get-def"><a name="L906"></a><tt class="py-lineno"> 906</tt> <a class="py-toggle" href="#" id="FormElement._method__get-toggle" onclick="return toggle('FormElement._method__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_method__get">_method__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._method__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._method__get-expanded"><a name="L907"></a><tt class="py-lineno"> 907</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L908"></a><tt class="py-lineno"> 908</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the form's method. Always returns a capitalized</tt> </tt>
+<a name="L909"></a><tt class="py-lineno"> 909</tt> <tt class="py-line"><tt class="py-docstring"> string, and defaults to ``'GET'``</tt> </tt>
+<a name="L910"></a><tt class="py-lineno"> 910</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L911"></a><tt class="py-lineno"> 911</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-561" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-558', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'method'</tt><tt class="py-op">,</tt> <tt class="py-string">'GET'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">upper</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-</div><a name="FormElement._method__set"></a><div id="FormElement._method__set-def"><a name="L911"></a><tt class="py-lineno"> 911</tt> <a class="py-toggle" href="#" id="FormElement._method__set-toggle" onclick="return toggle('FormElement._method__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_method__set">_method__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FormElement._method__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._method__set-expanded"><a name="L912"></a><tt class="py-lineno"> 912</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-559" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-559', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'method'</tt><tt class="py-op">,</tt> <tt id="link-560" class="py-name"><a title="lxml.html.CheckboxGroup.value
-lxml.html.InputElement.value
-lxml.html.RadioGroup.value
-lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-560', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt class="py-name">upper</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L913"></a><tt class="py-lineno"> 913</tt> <tt class="py-line"> <tt id="link-561" class="py-name" targets="Variable lxml.html.FormElement.method=lxml.html.FormElement-class.html#method"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-561', 'method', 'link-561');">method</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-562" class="py-name" targets="Method lxml.html.FormElement._method__get()=lxml.html.FormElement-class.html#_method__get"><a title="lxml.html.FormElement._method__get" class="py-name" href="#" onclick="return doclink('link-562', '_method__get', 'link-562');">_method__get</a></tt><tt class="py-op">,</tt> <tt id="link-563" class="py-name" targets="Method lxml.html.FormElement._method__set()=lxml.html.FormElement-class.html#_method__set"><a title="lxml.html.FormElement._method__set" class="py-name" href="#" onclick="return doclink('link-563', '_method__set', 'link-563');">_method__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-564" class="py-name"><a title="lxml.html.FormElement._method__get" class="py-name" href="#" onclick="return doclink('link-564', '_method__get', 'link-562');">_method__get</a></tt><tt class="py-op">.</tt><tt id="link-565" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-565', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L914"></a><tt class="py-lineno"> 914</tt> <tt class="py-line"> </tt>
-<a name="L915"></a><tt class="py-lineno"> 915</tt> <tt class="py-line"><tt id="link-566" class="py-name" targets="Class lxml.html.HtmlElementClassLookup=lxml.html.HtmlElementClassLookup-class.html"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-566', 'HtmlElementClassLookup', 'link-566');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-567" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-567', '_default_element_classes', 'link-263');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'form'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-568" class="py-name" targets="Class lxml.html.FormElement=lxml.html.FormElement-class.html"><a title="lxml.html.FormElement" class="py-name" href="#" onclick="return doclink('link-568', 'FormElement', 'link-568');">FormElement</a></tt> </tt>
-<a name="L916"></a><tt class="py-lineno"> 916</tt> <tt class="py-line"> </tt>
-<a name="submit_form"></a><div id="submit_form-def"><a name="L917"></a><tt class="py-lineno"> 917</tt> <a class="py-toggle" href="#" id="submit_form-toggle" onclick="return toggle('submit_form');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#submit_form">submit_form</a><tt class="py-op">(</tt><tt class="py-param">form</tt><tt class="py-op">,</tt> <tt class="py-param">extra_values</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">open_http</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="submit_form-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="submit_form-expanded"><a name="L918"></a><tt class="py-lineno"> 918</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L919"></a><tt class="py-lineno"> 919</tt> <tt class="py-line"><tt class="py-docstring"> Helper function to submit a form. Returns a file-like object, as from</tt> </tt>
-<a name="L920"></a><tt class="py-lineno"> 920</tt> <tt class="py-line"><tt class="py-docstring"> ``urllib.urlopen()``. This object also has a ``.geturl()`` function,</tt> </tt>
-<a name="L921"></a><tt class="py-lineno"> 921</tt> <tt class="py-line"><tt class="py-docstring"> which shows the URL if there were any redirects.</tt> </tt>
-<a name="L922"></a><tt class="py-lineno"> 922</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L923"></a><tt class="py-lineno"> 923</tt> <tt class="py-line"><tt class="py-docstring"> You can use this like::</tt> </tt>
-<a name="L924"></a><tt class="py-lineno"> 924</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L925"></a><tt class="py-lineno"> 925</tt> <tt class="py-line"><tt class="py-docstring"> form = doc.forms[0]</tt> </tt>
-<a name="L926"></a><tt class="py-lineno"> 926</tt> <tt class="py-line"><tt class="py-docstring"> form.inputs['foo'].value = 'bar' # etc</tt> </tt>
-<a name="L927"></a><tt class="py-lineno"> 927</tt> <tt class="py-line"><tt class="py-docstring"> response = form.submit()</tt> </tt>
-<a name="L928"></a><tt class="py-lineno"> 928</tt> <tt class="py-line"><tt class="py-docstring"> doc = parse(response)</tt> </tt>
-<a name="L929"></a><tt class="py-lineno"> 929</tt> <tt class="py-line"><tt class="py-docstring"> doc.make_links_absolute(response.geturl())</tt> </tt>
-<a name="L930"></a><tt class="py-lineno"> 930</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L931"></a><tt class="py-lineno"> 931</tt> <tt class="py-line"><tt class="py-docstring"> To change the HTTP requester, pass a function as ``open_http`` keyword</tt> </tt>
-<a name="L932"></a><tt class="py-lineno"> 932</tt> <tt class="py-line"><tt class="py-docstring"> argument that opens the URL for you. The function must have the following</tt> </tt>
-<a name="L933"></a><tt class="py-lineno"> 933</tt> <tt class="py-line"><tt class="py-docstring"> signature::</tt> </tt>
-<a name="L934"></a><tt class="py-lineno"> 934</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L935"></a><tt class="py-lineno"> 935</tt> <tt class="py-line"><tt class="py-docstring"> open_http(method, URL, values)</tt> </tt>
-<a name="L936"></a><tt class="py-lineno"> 936</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L937"></a><tt class="py-lineno"> 937</tt> <tt class="py-line"><tt class="py-docstring"> The action is one of 'GET' or 'POST', the URL is the target URL as a</tt> </tt>
-<a name="L938"></a><tt class="py-lineno"> 938</tt> <tt class="py-line"><tt class="py-docstring"> string, and the values are a sequence of ``(name, value)`` tuples with the</tt> </tt>
-<a name="L939"></a><tt class="py-lineno"> 939</tt> <tt class="py-line"><tt class="py-docstring"> form data.</tt> </tt>
-<a name="L940"></a><tt class="py-lineno"> 940</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L941"></a><tt class="py-lineno"> 941</tt> <tt class="py-line"> <tt id="link-569" class="py-name" targets="Method lxml.etree._Attrib.values()=lxml.etree._Attrib-class.html#values,Method lxml.etree._Element.values()=lxml.etree._Element-class.html#values,Method lxml.etree._IDDict.values()=lxml.etree._IDDict-class.html#values"><a title="lxml.etree._Attrib.values
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-561', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'method'</tt><tt class="py-op">,</tt> <tt class="py-string">'GET'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">upper</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+</div><a name="FormElement._method__set"></a><div id="FormElement._method__set-def"><a name="L912"></a><tt class="py-lineno"> 912</tt> <a class="py-toggle" href="#" id="FormElement._method__set-toggle" onclick="return toggle('FormElement._method__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FormElement-class.html#_method__set">_method__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FormElement._method__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FormElement._method__set-expanded"><a name="L913"></a><tt class="py-lineno"> 913</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-562" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-562', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'method'</tt><tt class="py-op">,</tt> <tt id="link-563" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputElement.value
+lxml.html.RadioGroup.value
+lxml.html.SelectElement.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-563', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt class="py-name">upper</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L914"></a><tt class="py-lineno"> 914</tt> <tt class="py-line"> <tt id="link-564" class="py-name" targets="Variable lxml.html.FormElement.method=lxml.html.FormElement-class.html#method"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-564', 'method', 'link-564');">method</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-565" class="py-name" targets="Method lxml.html.FormElement._method__get()=lxml.html.FormElement-class.html#_method__get"><a title="lxml.html.FormElement._method__get" class="py-name" href="#" onclick="return doclink('link-565', '_method__get', 'link-565');">_method__get</a></tt><tt class="py-op">,</tt> <tt id="link-566" class="py-name" targets="Method lxml.html.FormElement._method__set()=lxml.html.FormElement-class.html#_method__set"><a title="lxml.html.FormElement._method__set" class="py-name" href="#" onclick="return doclink('link-566', '_method__set', 'link-566');">_method__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-567" class="py-name"><a title="lxml.html.FormElement._method__get" class="py-name" href="#" onclick="return doclink('link-567', '_method__get', 'link-565');">_method__get</a></tt><tt class="py-op">.</tt><tt id="link-568" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-568', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L915"></a><tt class="py-lineno"> 915</tt> <tt class="py-line"> </tt>
+<a name="L916"></a><tt class="py-lineno"> 916</tt> <tt class="py-line"><tt id="link-569" class="py-name" targets="Class lxml.html.HtmlElementClassLookup=lxml.html.HtmlElementClassLookup-class.html"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-569', 'HtmlElementClassLookup', 'link-569');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-570" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-570', '_default_element_classes', 'link-266');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'form'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-571" class="py-name" targets="Class lxml.html.FormElement=lxml.html.FormElement-class.html"><a title="lxml.html.FormElement" class="py-name" href="#" onclick="return doclink('link-571', 'FormElement', 'link-571');">FormElement</a></tt> </tt>
+<a name="L917"></a><tt class="py-lineno"> 917</tt> <tt class="py-line"> </tt>
+<a name="submit_form"></a><div id="submit_form-def"><a name="L918"></a><tt class="py-lineno"> 918</tt> <a class="py-toggle" href="#" id="submit_form-toggle" onclick="return toggle('submit_form');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#submit_form">submit_form</a><tt class="py-op">(</tt><tt class="py-param">form</tt><tt class="py-op">,</tt> <tt class="py-param">extra_values</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">open_http</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="submit_form-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="submit_form-expanded"><a name="L919"></a><tt class="py-lineno"> 919</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L920"></a><tt class="py-lineno"> 920</tt> <tt class="py-line"><tt class="py-docstring"> Helper function to submit a form. Returns a file-like object, as from</tt> </tt>
+<a name="L921"></a><tt class="py-lineno"> 921</tt> <tt class="py-line"><tt class="py-docstring"> ``urllib.urlopen()``. This object also has a ``.geturl()`` function,</tt> </tt>
+<a name="L922"></a><tt class="py-lineno"> 922</tt> <tt class="py-line"><tt class="py-docstring"> which shows the URL if there were any redirects.</tt> </tt>
+<a name="L923"></a><tt class="py-lineno"> 923</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L924"></a><tt class="py-lineno"> 924</tt> <tt class="py-line"><tt class="py-docstring"> You can use this like::</tt> </tt>
+<a name="L925"></a><tt class="py-lineno"> 925</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L926"></a><tt class="py-lineno"> 926</tt> <tt class="py-line"><tt class="py-docstring"> form = doc.forms[0]</tt> </tt>
+<a name="L927"></a><tt class="py-lineno"> 927</tt> <tt class="py-line"><tt class="py-docstring"> form.inputs['foo'].value = 'bar' # etc</tt> </tt>
+<a name="L928"></a><tt class="py-lineno"> 928</tt> <tt class="py-line"><tt class="py-docstring"> response = form.submit()</tt> </tt>
+<a name="L929"></a><tt class="py-lineno"> 929</tt> <tt class="py-line"><tt class="py-docstring"> doc = parse(response)</tt> </tt>
+<a name="L930"></a><tt class="py-lineno"> 930</tt> <tt class="py-line"><tt class="py-docstring"> doc.make_links_absolute(response.geturl())</tt> </tt>
+<a name="L931"></a><tt class="py-lineno"> 931</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L932"></a><tt class="py-lineno"> 932</tt> <tt class="py-line"><tt class="py-docstring"> To change the HTTP requester, pass a function as ``open_http`` keyword</tt> </tt>
+<a name="L933"></a><tt class="py-lineno"> 933</tt> <tt class="py-line"><tt class="py-docstring"> argument that opens the URL for you. The function must have the following</tt> </tt>
+<a name="L934"></a><tt class="py-lineno"> 934</tt> <tt class="py-line"><tt class="py-docstring"> signature::</tt> </tt>
+<a name="L935"></a><tt class="py-lineno"> 935</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L936"></a><tt class="py-lineno"> 936</tt> <tt class="py-line"><tt class="py-docstring"> open_http(method, URL, values)</tt> </tt>
+<a name="L937"></a><tt class="py-lineno"> 937</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L938"></a><tt class="py-lineno"> 938</tt> <tt class="py-line"><tt class="py-docstring"> The action is one of 'GET' or 'POST', the URL is the target URL as a</tt> </tt>
+<a name="L939"></a><tt class="py-lineno"> 939</tt> <tt class="py-line"><tt class="py-docstring"> string, and the values are a sequence of ``(name, value)`` tuples with the</tt> </tt>
+<a name="L940"></a><tt class="py-lineno"> 940</tt> <tt class="py-line"><tt class="py-docstring"> form data.</tt> </tt>
+<a name="L941"></a><tt class="py-lineno"> 941</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L942"></a><tt class="py-lineno"> 942</tt> <tt class="py-line"> <tt id="link-572" class="py-name" targets="Method lxml.etree._Attrib.values()=lxml.etree._Attrib-class.html#values,Method lxml.etree._Element.values()=lxml.etree._Element-class.html#values,Method lxml.etree._IDDict.values()=lxml.etree._IDDict-class.html#values"><a title="lxml.etree._Attrib.values
lxml.etree._Element.values
-lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-569', 'values', 'link-569');">values</a></tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-570" class="py-name" targets="Method lxml.html.FormElement.form_values()=lxml.html.FormElement-class.html#form_values"><a title="lxml.html.FormElement.form_values" class="py-name" href="#" onclick="return doclink('link-570', 'form_values', 'link-570');">form_values</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L942"></a><tt class="py-lineno"> 942</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">extra_values</tt><tt class="py-op">:</tt> </tt>
-<a name="L943"></a><tt class="py-lineno"> 943</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-571" class="py-name" targets="Method lxml.objectify.ObjectPath.hasattr()=lxml.objectify.ObjectPath-class.html#hasattr"><a title="lxml.objectify.ObjectPath.hasattr" class="py-name" href="#" onclick="return doclink('link-571', 'hasattr', 'link-571');">hasattr</a></tt><tt class="py-op">(</tt><tt class="py-name">extra_values</tt><tt class="py-op">,</tt> <tt class="py-string">'items'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L944"></a><tt class="py-lineno"> 944</tt> <tt class="py-line"> <tt class="py-name">extra_values</tt> <tt class="py-op">=</tt> <tt class="py-name">extra_values</tt><tt class="py-op">.</tt><tt id="link-572" class="py-name"><a title="lxml.etree._Attrib.items
+lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-572', 'values', 'link-572');">values</a></tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-573" class="py-name" targets="Method lxml.html.FormElement.form_values()=lxml.html.FormElement-class.html#form_values"><a title="lxml.html.FormElement.form_values" class="py-name" href="#" onclick="return doclink('link-573', 'form_values', 'link-573');">form_values</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L943"></a><tt class="py-lineno"> 943</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">extra_values</tt><tt class="py-op">:</tt> </tt>
+<a name="L944"></a><tt class="py-lineno"> 944</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-574" class="py-name" targets="Method lxml.objectify.ObjectPath.hasattr()=lxml.objectify.ObjectPath-class.html#hasattr"><a title="lxml.objectify.ObjectPath.hasattr" class="py-name" href="#" onclick="return doclink('link-574', 'hasattr', 'link-574');">hasattr</a></tt><tt class="py-op">(</tt><tt class="py-name">extra_values</tt><tt class="py-op">,</tt> <tt class="py-string">'items'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L945"></a><tt class="py-lineno"> 945</tt> <tt class="py-line"> <tt class="py-name">extra_values</tt> <tt class="py-op">=</tt> <tt class="py-name">extra_values</tt><tt class="py-op">.</tt><tt id="link-575" class="py-name"><a title="lxml.etree._Attrib.items
lxml.etree._Element.items
-lxml.etree._IDDict.items" class="py-name" href="#" onclick="return doclink('link-572', 'items', 'link-279');">items</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L945"></a><tt class="py-lineno"> 945</tt> <tt class="py-line"> <tt id="link-573" class="py-name"><a title="lxml.etree._Attrib.values
+lxml.etree._IDDict.items" class="py-name" href="#" onclick="return doclink('link-575', 'items', 'link-282');">items</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L946"></a><tt class="py-lineno"> 946</tt> <tt class="py-line"> <tt id="link-576" class="py-name"><a title="lxml.etree._Attrib.values
lxml.etree._Element.values
-lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-573', 'values', 'link-569');">values</a></tt><tt class="py-op">.</tt><tt id="link-574" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-574', 'extend', 'link-355');">extend</a></tt><tt class="py-op">(</tt><tt class="py-name">extra_values</tt><tt class="py-op">)</tt> </tt>
-<a name="L946"></a><tt class="py-lineno"> 946</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">open_http</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L947"></a><tt class="py-lineno"> 947</tt> <tt class="py-line"> <tt class="py-name">open_http</tt> <tt class="py-op">=</tt> <tt class="py-name">open_http_urllib</tt> </tt>
-<a name="L948"></a><tt class="py-lineno"> 948</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-575" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-575', 'action', 'link-541');">action</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L949"></a><tt class="py-lineno"> 949</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-576" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-576', 'action', 'link-541');">action</a></tt> </tt>
-<a name="L950"></a><tt class="py-lineno"> 950</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L951"></a><tt class="py-lineno"> 951</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-577" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-577', 'base_url', 'link-59');">base_url</a></tt> </tt>
-<a name="L952"></a><tt class="py-lineno"> 952</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">open_http</tt><tt class="py-op">(</tt><tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-578" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-578', 'method', 'link-561');">method</a></tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-579" class="py-name"><a title="lxml.etree._Attrib.values
+lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-576', 'values', 'link-572');">values</a></tt><tt class="py-op">.</tt><tt id="link-577" class="py-name"><a title="lxml.etree._Element.extend" class="py-name" href="#" onclick="return doclink('link-577', 'extend', 'link-358');">extend</a></tt><tt class="py-op">(</tt><tt class="py-name">extra_values</tt><tt class="py-op">)</tt> </tt>
+<a name="L947"></a><tt class="py-lineno"> 947</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">open_http</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L948"></a><tt class="py-lineno"> 948</tt> <tt class="py-line"> <tt class="py-name">open_http</tt> <tt class="py-op">=</tt> <tt class="py-name">open_http_urllib</tt> </tt>
+<a name="L949"></a><tt class="py-lineno"> 949</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-578" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-578', 'action', 'link-544');">action</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L950"></a><tt class="py-lineno"> 950</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-579" class="py-name"><a title="lxml.html.FormElement.action" class="py-name" href="#" onclick="return doclink('link-579', 'action', 'link-544');">action</a></tt> </tt>
+<a name="L951"></a><tt class="py-lineno"> 951</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L952"></a><tt class="py-lineno"> 952</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-580" class="py-name"><a title="lxml.html.HtmlMixin.base_url" class="py-name" href="#" onclick="return doclink('link-580', 'base_url', 'link-60');">base_url</a></tt> </tt>
+<a name="L953"></a><tt class="py-lineno"> 953</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">open_http</tt><tt class="py-op">(</tt><tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-581" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-581', 'method', 'link-564');">method</a></tt><tt class="py-op">,</tt> <tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-582" class="py-name"><a title="lxml.etree._Attrib.values
lxml.etree._Element.values
-lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-579', 'values', 'link-569');">values</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L953"></a><tt class="py-lineno"> 953</tt> <tt class="py-line"> </tt>
-<a name="open_http_urllib"></a><div id="open_http_urllib-def"><a name="L954"></a><tt class="py-lineno"> 954</tt> <a class="py-toggle" href="#" id="open_http_urllib-toggle" onclick="return toggle('open_http_urllib');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#open_http_urllib">open_http_urllib</a><tt class="py-op">(</tt><tt class="py-param">method</tt><tt class="py-op">,</tt> <tt class="py-param">url</tt><tt class="py-op">,</tt> <tt class="py-param">values</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="open_http_urllib-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="open_http_urllib-expanded"><a name="L955"></a><tt class="py-lineno"> 955</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">url</tt><tt class="py-op">:</tt> </tt>
-<a name="L956"></a><tt class="py-lineno"> 956</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt><tt class="py-string">"cannot submit, no URL provided"</tt><tt class="py-op">)</tt> </tt>
-<a name="L957"></a><tt class="py-lineno"> 957</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: should test that it's not a relative URL or something</tt> </tt>
-<a name="L958"></a><tt class="py-lineno"> 958</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
-<a name="L959"></a><tt class="py-lineno"> 959</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt class="py-name">urllib</tt> <tt class="py-keyword">import</tt> <tt class="py-name">urlencode</tt><tt class="py-op">,</tt> <tt class="py-name">urlopen</tt> </tt>
-<a name="L960"></a><tt class="py-lineno"> 960</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">ImportError</tt><tt class="py-op">:</tt> <tt class="py-comment"># Python 3</tt> </tt>
-<a name="L961"></a><tt class="py-lineno"> 961</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt class="py-name">urllib</tt><tt class="py-op">.</tt><tt class="py-name">request</tt> <tt class="py-keyword">import</tt> <tt class="py-name">urlopen</tt> </tt>
-<a name="L962"></a><tt class="py-lineno"> 962</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt class="py-name">urllib</tt><tt class="py-op">.</tt><tt id="link-580" class="py-name"><a title="lxml.etree._ElementTree.parse
+lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-582', 'values', 'link-572');">values</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L954"></a><tt class="py-lineno"> 954</tt> <tt class="py-line"> </tt>
+<a name="open_http_urllib"></a><div id="open_http_urllib-def"><a name="L955"></a><tt class="py-lineno"> 955</tt> <a class="py-toggle" href="#" id="open_http_urllib-toggle" onclick="return toggle('open_http_urllib');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#open_http_urllib">open_http_urllib</a><tt class="py-op">(</tt><tt class="py-param">method</tt><tt class="py-op">,</tt> <tt class="py-param">url</tt><tt class="py-op">,</tt> <tt class="py-param">values</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="open_http_urllib-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="open_http_urllib-expanded"><a name="L956"></a><tt class="py-lineno"> 956</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">url</tt><tt class="py-op">:</tt> </tt>
+<a name="L957"></a><tt class="py-lineno"> 957</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt><tt class="py-string">"cannot submit, no URL provided"</tt><tt class="py-op">)</tt> </tt>
+<a name="L958"></a><tt class="py-lineno"> 958</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: should test that it's not a relative URL or something</tt> </tt>
+<a name="L959"></a><tt class="py-lineno"> 959</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
+<a name="L960"></a><tt class="py-lineno"> 960</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt class="py-name">urllib</tt> <tt class="py-keyword">import</tt> <tt class="py-name">urlencode</tt><tt class="py-op">,</tt> <tt class="py-name">urlopen</tt> </tt>
+<a name="L961"></a><tt class="py-lineno"> 961</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">ImportError</tt><tt class="py-op">:</tt> <tt class="py-comment"># Python 3</tt> </tt>
+<a name="L962"></a><tt class="py-lineno"> 962</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt class="py-name">urllib</tt><tt class="py-op">.</tt><tt class="py-name">request</tt> <tt class="py-keyword">import</tt> <tt class="py-name">urlopen</tt> </tt>
+<a name="L963"></a><tt class="py-lineno"> 963</tt> <tt class="py-line"> <tt class="py-keyword">from</tt> <tt class="py-name">urllib</tt><tt class="py-op">.</tt><tt id="link-583" class="py-name"><a title="lxml.etree._ElementTree.parse
lxml.etree.parse
lxml.html.ElementSoup.parse
lxml.html.html5parser.parse
lxml.html.soupparser.parse
lxml.objectify.parse
-lxml.tests.common_imports.HelperTestCase.parse" class="py-name" href="#" onclick="return doclink('link-580', 'parse', 'link-0');">parse</a></tt> <tt class="py-keyword">import</tt> <tt class="py-name">urlencode</tt> </tt>
-<a name="L963"></a><tt class="py-lineno"> 963</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-581" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-581', 'method', 'link-561');">method</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'GET'</tt><tt class="py-op">:</tt> </tt>
-<a name="L964"></a><tt class="py-lineno"> 964</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'?'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">url</tt><tt class="py-op">:</tt> </tt>
-<a name="L965"></a><tt class="py-lineno"> 965</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">+=</tt> <tt class="py-string">'&'</tt> </tt>
-<a name="L966"></a><tt class="py-lineno"> 966</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L967"></a><tt class="py-lineno"> 967</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">+=</tt> <tt class="py-string">'?'</tt> </tt>
-<a name="L968"></a><tt class="py-lineno"> 968</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">+=</tt> <tt class="py-name">urlencode</tt><tt class="py-op">(</tt><tt id="link-582" class="py-name"><a title="lxml.etree._Attrib.values
+lxml.tests.common_imports.HelperTestCase.parse" class="py-name" href="#" onclick="return doclink('link-583', 'parse', 'link-0');">parse</a></tt> <tt class="py-keyword">import</tt> <tt class="py-name">urlencode</tt> </tt>
+<a name="L964"></a><tt class="py-lineno"> 964</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-584" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-584', 'method', 'link-564');">method</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'GET'</tt><tt class="py-op">:</tt> </tt>
+<a name="L965"></a><tt class="py-lineno"> 965</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'?'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">url</tt><tt class="py-op">:</tt> </tt>
+<a name="L966"></a><tt class="py-lineno"> 966</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">+=</tt> <tt class="py-string">'&'</tt> </tt>
+<a name="L967"></a><tt class="py-lineno"> 967</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L968"></a><tt class="py-lineno"> 968</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">+=</tt> <tt class="py-string">'?'</tt> </tt>
+<a name="L969"></a><tt class="py-lineno"> 969</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">+=</tt> <tt class="py-name">urlencode</tt><tt class="py-op">(</tt><tt id="link-585" class="py-name"><a title="lxml.etree._Attrib.values
lxml.etree._Element.values
-lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-582', 'values', 'link-569');">values</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L969"></a><tt class="py-lineno"> 969</tt> <tt class="py-line"> <tt id="link-583" class="py-name" targets="Method lxml.etree.TreeBuilder.data()=lxml.etree.TreeBuilder-class.html#data"><a title="lxml.etree.TreeBuilder.data" class="py-name" href="#" onclick="return doclink('link-583', 'data', 'link-583');">data</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-<a name="L970"></a><tt class="py-lineno"> 970</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L971"></a><tt class="py-lineno"> 971</tt> <tt class="py-line"> <tt id="link-584" class="py-name"><a title="lxml.etree.TreeBuilder.data" class="py-name" href="#" onclick="return doclink('link-584', 'data', 'link-583');">data</a></tt> <tt class="py-op">=</tt> <tt class="py-name">urlencode</tt><tt class="py-op">(</tt><tt id="link-585" class="py-name"><a title="lxml.etree._Attrib.values
+lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-585', 'values', 'link-572');">values</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L970"></a><tt class="py-lineno"> 970</tt> <tt class="py-line"> <tt id="link-586" class="py-name" targets="Method lxml.etree.TreeBuilder.data()=lxml.etree.TreeBuilder-class.html#data"><a title="lxml.etree.TreeBuilder.data" class="py-name" href="#" onclick="return doclink('link-586', 'data', 'link-586');">data</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+<a name="L971"></a><tt class="py-lineno"> 971</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L972"></a><tt class="py-lineno"> 972</tt> <tt class="py-line"> <tt id="link-587" class="py-name"><a title="lxml.etree.TreeBuilder.data" class="py-name" href="#" onclick="return doclink('link-587', 'data', 'link-586');">data</a></tt> <tt class="py-op">=</tt> <tt class="py-name">urlencode</tt><tt class="py-op">(</tt><tt id="link-588" class="py-name"><a title="lxml.etree._Attrib.values
lxml.etree._Element.values
-lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-585', 'values', 'link-569');">values</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L972"></a><tt class="py-lineno"> 972</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urlopen</tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-586" class="py-name"><a title="lxml.etree.TreeBuilder.data" class="py-name" href="#" onclick="return doclink('link-586', 'data', 'link-583');">data</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L973"></a><tt class="py-lineno"> 973</tt> <tt class="py-line"> </tt>
-<a name="FieldsDict"></a><div id="FieldsDict-def"><a name="L974"></a><tt class="py-lineno"> 974</tt> <a class="py-toggle" href="#" id="FieldsDict-toggle" onclick="return toggle('FieldsDict');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html">FieldsDict</a><tt class="py-op">(</tt><tt class="py-base-class">DictMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="FieldsDict-expanded"><a name="L975"></a><tt class="py-lineno"> 975</tt> <tt class="py-line"> </tt>
-<a name="FieldsDict.__init__"></a><div id="FieldsDict.__init__-def"><a name="L976"></a><tt class="py-lineno"> 976</tt> <a class="py-toggle" href="#" id="FieldsDict.__init__-toggle" onclick="return toggle('FieldsDict.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">inputs</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__init__-expanded"><a name="L977"></a><tt class="py-lineno"> 977</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-587" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-587', 'inputs', 'link-471');">inputs</a></tt> <tt class="py-op">=</tt> <tt id="link-588" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-588', 'inputs', 'link-471');">inputs</a></tt> </tt>
-</div><a name="FieldsDict.__getitem__"></a><div id="FieldsDict.__getitem__-def"><a name="L978"></a><tt class="py-lineno"> 978</tt> <a class="py-toggle" href="#" id="FieldsDict.__getitem__-toggle" onclick="return toggle('FieldsDict.__getitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__getitem__">__getitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__getitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__getitem__-expanded"><a name="L979"></a><tt class="py-lineno"> 979</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-589" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-589', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">[</tt><tt class="py-name">item</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-590" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._IDDict.values" class="py-name" href="#" onclick="return doclink('link-588', 'values', 'link-572');">values</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L973"></a><tt class="py-lineno"> 973</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">urlopen</tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">,</tt> <tt id="link-589" class="py-name"><a title="lxml.etree.TreeBuilder.data" class="py-name" href="#" onclick="return doclink('link-589', 'data', 'link-586');">data</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L974"></a><tt class="py-lineno"> 974</tt> <tt class="py-line"> </tt>
+<a name="FieldsDict"></a><div id="FieldsDict-def"><a name="L975"></a><tt class="py-lineno"> 975</tt> <a class="py-toggle" href="#" id="FieldsDict-toggle" onclick="return toggle('FieldsDict');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html">FieldsDict</a><tt class="py-op">(</tt><tt class="py-base-class">DictMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="FieldsDict-expanded"><a name="L976"></a><tt class="py-lineno"> 976</tt> <tt class="py-line"> </tt>
+<a name="FieldsDict.__init__"></a><div id="FieldsDict.__init__-def"><a name="L977"></a><tt class="py-lineno"> 977</tt> <a class="py-toggle" href="#" id="FieldsDict.__init__-toggle" onclick="return toggle('FieldsDict.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">inputs</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__init__-expanded"><a name="L978"></a><tt class="py-lineno"> 978</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-590" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-590', 'inputs', 'link-474');">inputs</a></tt> <tt class="py-op">=</tt> <tt id="link-591" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-591', 'inputs', 'link-474');">inputs</a></tt> </tt>
+</div><a name="FieldsDict.__getitem__"></a><div id="FieldsDict.__getitem__-def"><a name="L979"></a><tt class="py-lineno"> 979</tt> <a class="py-toggle" href="#" id="FieldsDict.__getitem__-toggle" onclick="return toggle('FieldsDict.__getitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__getitem__">__getitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__getitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__getitem__-expanded"><a name="L980"></a><tt class="py-lineno"> 980</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-592" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-592', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">[</tt><tt class="py-name">item</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-593" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-590', 'value', 'link-172');">value</a></tt> </tt>
-</div><a name="FieldsDict.__setitem__"></a><div id="FieldsDict.__setitem__-def"><a name="L980"></a><tt class="py-lineno"> 980</tt> <a class="py-toggle" href="#" id="FieldsDict.__setitem__-toggle" onclick="return toggle('FieldsDict.__setitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__setitem__">__setitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__setitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__setitem__-expanded"><a name="L981"></a><tt class="py-lineno"> 981</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-591" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-591', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">[</tt><tt class="py-name">item</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-592" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-593', 'value', 'link-173');">value</a></tt> </tt>
+</div><a name="FieldsDict.__setitem__"></a><div id="FieldsDict.__setitem__-def"><a name="L981"></a><tt class="py-lineno"> 981</tt> <a class="py-toggle" href="#" id="FieldsDict.__setitem__-toggle" onclick="return toggle('FieldsDict.__setitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__setitem__">__setitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__setitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__setitem__-expanded"><a name="L982"></a><tt class="py-lineno"> 982</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-594" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-594', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">[</tt><tt class="py-name">item</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-595" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-592', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-593" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-595', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-596" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-593', 'value', 'link-172');">value</a></tt> </tt>
-</div><a name="FieldsDict.__delitem__"></a><div id="FieldsDict.__delitem__-def"><a name="L982"></a><tt class="py-lineno"> 982</tt> <a class="py-toggle" href="#" id="FieldsDict.__delitem__-toggle" onclick="return toggle('FieldsDict.__delitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__delitem__">__delitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__delitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__delitem__-expanded"><a name="L983"></a><tt class="py-lineno"> 983</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
-<a name="L984"></a><tt class="py-lineno"> 984</tt> <tt class="py-line"> <tt class="py-string">"You cannot remove keys from ElementDict"</tt><tt class="py-op">)</tt> </tt>
-</div><a name="FieldsDict.keys"></a><div id="FieldsDict.keys-def"><a name="L985"></a><tt class="py-lineno"> 985</tt> <a class="py-toggle" href="#" id="FieldsDict.keys-toggle" onclick="return toggle('FieldsDict.keys');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#keys">keys</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.keys-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.keys-expanded"><a name="L986"></a><tt class="py-lineno"> 986</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-594" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-594', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">.</tt><tt id="link-595" class="py-name"><a title="lxml.etree._Attrib.keys
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-596', 'value', 'link-173');">value</a></tt> </tt>
+</div><a name="FieldsDict.__delitem__"></a><div id="FieldsDict.__delitem__-def"><a name="L983"></a><tt class="py-lineno"> 983</tt> <a class="py-toggle" href="#" id="FieldsDict.__delitem__-toggle" onclick="return toggle('FieldsDict.__delitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__delitem__">__delitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__delitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__delitem__-expanded"><a name="L984"></a><tt class="py-lineno"> 984</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
+<a name="L985"></a><tt class="py-lineno"> 985</tt> <tt class="py-line"> <tt class="py-string">"You cannot remove keys from ElementDict"</tt><tt class="py-op">)</tt> </tt>
+</div><a name="FieldsDict.keys"></a><div id="FieldsDict.keys-def"><a name="L986"></a><tt class="py-lineno"> 986</tt> <a class="py-toggle" href="#" id="FieldsDict.keys-toggle" onclick="return toggle('FieldsDict.keys');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#keys">keys</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.keys-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.keys-expanded"><a name="L987"></a><tt class="py-lineno"> 987</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-597" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-597', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">.</tt><tt id="link-598" class="py-name"><a title="lxml.etree._Attrib.keys
lxml.etree._Element.keys
lxml.etree._IDDict.keys
lxml.html.FieldsDict.keys
-lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-595', 'keys', 'link-272');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-</div><a name="FieldsDict.__contains__"></a><div id="FieldsDict.__contains__-def"><a name="L987"></a><tt class="py-lineno"> 987</tt> <a class="py-toggle" href="#" id="FieldsDict.__contains__-toggle" onclick="return toggle('FieldsDict.__contains__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__contains__">__contains__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__contains__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__contains__-expanded"><a name="L988"></a><tt class="py-lineno"> 988</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">item</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-596" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-596', 'inputs', 'link-471');">inputs</a></tt> </tt>
-</div><a name="FieldsDict.__iter__"></a><div id="FieldsDict.__iter__-def"><a name="L989"></a><tt class="py-lineno"> 989</tt> <a class="py-toggle" href="#" id="FieldsDict.__iter__-toggle" onclick="return toggle('FieldsDict.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__iter__-expanded"><a name="L990"></a><tt class="py-lineno"> 990</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-597" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-597', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-598" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-598', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">.</tt><tt id="link-599" class="py-name"><a title="lxml.etree._Attrib.keys
+lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-598', 'keys', 'link-275');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+</div><a name="FieldsDict.__contains__"></a><div id="FieldsDict.__contains__-def"><a name="L988"></a><tt class="py-lineno"> 988</tt> <a class="py-toggle" href="#" id="FieldsDict.__contains__-toggle" onclick="return toggle('FieldsDict.__contains__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__contains__">__contains__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__contains__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__contains__-expanded"><a name="L989"></a><tt class="py-lineno"> 989</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">item</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-599" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-599', 'inputs', 'link-474');">inputs</a></tt> </tt>
+</div><a name="FieldsDict.__iter__"></a><div id="FieldsDict.__iter__-def"><a name="L990"></a><tt class="py-lineno"> 990</tt> <a class="py-toggle" href="#" id="FieldsDict.__iter__-toggle" onclick="return toggle('FieldsDict.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__iter__-expanded"><a name="L991"></a><tt class="py-lineno"> 991</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-600" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-600', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-601" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-601', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">.</tt><tt id="link-602" class="py-name"><a title="lxml.etree._Attrib.keys
lxml.etree._Element.keys
lxml.etree._IDDict.keys
lxml.html.FieldsDict.keys
-lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-599', 'keys', 'link-272');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div><a name="FieldsDict.__len__"></a><div id="FieldsDict.__len__-def"><a name="L991"></a><tt class="py-lineno"> 991</tt> <a class="py-toggle" href="#" id="FieldsDict.__len__-toggle" onclick="return toggle('FieldsDict.__len__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__len__">__len__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__len__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__len__-expanded"><a name="L992"></a><tt class="py-lineno"> 992</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-600" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-600', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L993"></a><tt class="py-lineno"> 993</tt> <tt class="py-line"> </tt>
-<a name="FieldsDict.__repr__"></a><div id="FieldsDict.__repr__-def"><a name="L994"></a><tt class="py-lineno"> 994</tt> <a class="py-toggle" href="#" id="FieldsDict.__repr__-toggle" onclick="return toggle('FieldsDict.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="FieldsDict.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__repr__-expanded"><a name="L995"></a><tt class="py-lineno"> 995</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s for form %s>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
-<a name="L996"></a><tt class="py-lineno"> 996</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
-<a name="L997"></a><tt class="py-lineno"> 997</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-601" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-601', 'inputs', 'link-471');">inputs</a></tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-602" class="py-name" targets="Method lxml.html.FormElement._name()=lxml.html.FormElement-class.html#_name"><a title="lxml.html.FormElement._name" class="py-name" href="#" onclick="return doclink('link-602', '_name', 'link-602');">_name</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L998"></a><tt class="py-lineno"> 998</tt> <tt class="py-line"> </tt>
-<a name="InputGetter"></a><div id="InputGetter-def"><a name="L999"></a><tt class="py-lineno"> 999</tt> <a class="py-toggle" href="#" id="InputGetter-toggle" onclick="return toggle('InputGetter');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html">InputGetter</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputGetter-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="InputGetter-expanded"><a name="L1000"></a><tt class="py-lineno">1000</tt> <tt class="py-line"> </tt>
-<a name="L1001"></a><tt class="py-lineno">1001</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1002"></a><tt class="py-lineno">1002</tt> <tt class="py-line"><tt class="py-docstring"> An accessor that represents all the input fields in a form.</tt> </tt>
-<a name="L1003"></a><tt class="py-lineno">1003</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1004"></a><tt class="py-lineno">1004</tt> <tt class="py-line"><tt class="py-docstring"> You can get fields by name from this, with</tt> </tt>
-<a name="L1005"></a><tt class="py-lineno">1005</tt> <tt class="py-line"><tt class="py-docstring"> ``form.inputs['field_name']``. If there are a set of checkboxes</tt> </tt>
-<a name="L1006"></a><tt class="py-lineno">1006</tt> <tt class="py-line"><tt class="py-docstring"> with the same name, they are returned as a list (a `CheckboxGroup`</tt> </tt>
-<a name="L1007"></a><tt class="py-lineno">1007</tt> <tt class="py-line"><tt class="py-docstring"> which also allows value setting). Radio inputs are handled</tt> </tt>
-<a name="L1008"></a><tt class="py-lineno">1008</tt> <tt class="py-line"><tt class="py-docstring"> similarly.</tt> </tt>
-<a name="L1009"></a><tt class="py-lineno">1009</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1010"></a><tt class="py-lineno">1010</tt> <tt class="py-line"><tt class="py-docstring"> You can also iterate over this to get all input elements. This</tt> </tt>
-<a name="L1011"></a><tt class="py-lineno">1011</tt> <tt class="py-line"><tt class="py-docstring"> won't return the same thing as if you get all the names, as</tt> </tt>
-<a name="L1012"></a><tt class="py-lineno">1012</tt> <tt class="py-line"><tt class="py-docstring"> checkboxes and radio elements are returned individually.</tt> </tt>
-<a name="L1013"></a><tt class="py-lineno">1013</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1014"></a><tt class="py-lineno">1014</tt> <tt class="py-line"> </tt>
-<a name="L1015"></a><tt class="py-lineno">1015</tt> <tt class="py-line"> <tt id="link-603" class="py-name" targets="Variable lxml.html.InputGetter._name_xpath=lxml.html.InputGetter-class.html#_name_xpath,Variable lxml.html.formfill._name_xpath=lxml.html.formfill-module.html#_name_xpath"><a title="lxml.html.InputGetter._name_xpath
-lxml.html.formfill._name_xpath" class="py-name" href="#" onclick="return doclink('link-603', '_name_xpath', 'link-603');">_name_xpath</a></tt> <tt class="py-op">=</tt> <tt id="link-604" class="py-name"><a title="lxml.etree
+lxml.html.InputGetter.keys" class="py-name" href="#" onclick="return doclink('link-602', 'keys', 'link-275');">keys</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div><a name="FieldsDict.__len__"></a><div id="FieldsDict.__len__-def"><a name="L992"></a><tt class="py-lineno"> 992</tt> <a class="py-toggle" href="#" id="FieldsDict.__len__-toggle" onclick="return toggle('FieldsDict.__len__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__len__">__len__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__len__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__len__-expanded"><a name="L993"></a><tt class="py-lineno"> 993</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-603" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-603', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L994"></a><tt class="py-lineno"> 994</tt> <tt class="py-line"> </tt>
+<a name="FieldsDict.__repr__"></a><div id="FieldsDict.__repr__-def"><a name="L995"></a><tt class="py-lineno"> 995</tt> <a class="py-toggle" href="#" id="FieldsDict.__repr__-toggle" onclick="return toggle('FieldsDict.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.FieldsDict-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="FieldsDict.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="FieldsDict.__repr__-expanded"><a name="L996"></a><tt class="py-lineno"> 996</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s for form %s>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
+<a name="L997"></a><tt class="py-lineno"> 997</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
+<a name="L998"></a><tt class="py-lineno"> 998</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-604" class="py-name"><a title="lxml.html.FormElement.inputs" class="py-name" href="#" onclick="return doclink('link-604', 'inputs', 'link-474');">inputs</a></tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-605" class="py-name" targets="Method lxml.html.FormElement._name()=lxml.html.FormElement-class.html#_name"><a title="lxml.html.FormElement._name" class="py-name" href="#" onclick="return doclink('link-605', '_name', 'link-605');">_name</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L999"></a><tt class="py-lineno"> 999</tt> <tt class="py-line"> </tt>
+<a name="InputGetter"></a><div id="InputGetter-def"><a name="L1000"></a><tt class="py-lineno">1000</tt> <a class="py-toggle" href="#" id="InputGetter-toggle" onclick="return toggle('InputGetter');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html">InputGetter</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputGetter-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="InputGetter-expanded"><a name="L1001"></a><tt class="py-lineno">1001</tt> <tt class="py-line"> </tt>
+<a name="L1002"></a><tt class="py-lineno">1002</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1003"></a><tt class="py-lineno">1003</tt> <tt class="py-line"><tt class="py-docstring"> An accessor that represents all the input fields in a form.</tt> </tt>
+<a name="L1004"></a><tt class="py-lineno">1004</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1005"></a><tt class="py-lineno">1005</tt> <tt class="py-line"><tt class="py-docstring"> You can get fields by name from this, with</tt> </tt>
+<a name="L1006"></a><tt class="py-lineno">1006</tt> <tt class="py-line"><tt class="py-docstring"> ``form.inputs['field_name']``. If there are a set of checkboxes</tt> </tt>
+<a name="L1007"></a><tt class="py-lineno">1007</tt> <tt class="py-line"><tt class="py-docstring"> with the same name, they are returned as a list (a `CheckboxGroup`</tt> </tt>
+<a name="L1008"></a><tt class="py-lineno">1008</tt> <tt class="py-line"><tt class="py-docstring"> which also allows value setting). Radio inputs are handled</tt> </tt>
+<a name="L1009"></a><tt class="py-lineno">1009</tt> <tt class="py-line"><tt class="py-docstring"> similarly.</tt> </tt>
+<a name="L1010"></a><tt class="py-lineno">1010</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1011"></a><tt class="py-lineno">1011</tt> <tt class="py-line"><tt class="py-docstring"> You can also iterate over this to get all input elements. This</tt> </tt>
+<a name="L1012"></a><tt class="py-lineno">1012</tt> <tt class="py-line"><tt class="py-docstring"> won't return the same thing as if you get all the names, as</tt> </tt>
+<a name="L1013"></a><tt class="py-lineno">1013</tt> <tt class="py-line"><tt class="py-docstring"> checkboxes and radio elements are returned individually.</tt> </tt>
+<a name="L1014"></a><tt class="py-lineno">1014</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1015"></a><tt class="py-lineno">1015</tt> <tt class="py-line"> </tt>
+<a name="L1016"></a><tt class="py-lineno">1016</tt> <tt class="py-line"> <tt id="link-606" class="py-name" targets="Variable lxml.html.InputGetter._name_xpath=lxml.html.InputGetter-class.html#_name_xpath,Variable lxml.html.formfill._name_xpath=lxml.html.formfill-module.html#_name_xpath"><a title="lxml.html.InputGetter._name_xpath
+lxml.html.formfill._name_xpath" class="py-name" href="#" onclick="return doclink('link-606', '_name_xpath', 'link-606');">_name_xpath</a></tt> <tt class="py-op">=</tt> <tt id="link-607" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-604', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-605" class="py-name"><a title="lxml.etree.XPath" class="py-name" href="#" onclick="return doclink('link-605', 'XPath', 'link-19');">XPath</a></tt><tt class="py-op">(</tt><tt class="py-string">".//*[@name = $name and (local-name(.) = 'select' or local-name(.) = 'input' or local-name(.) = 'textarea')]"</tt><tt class="py-op">)</tt> </tt>
-<a name="L1016"></a><tt class="py-lineno">1016</tt> <tt class="py-line"> <tt id="link-606" class="py-name" targets="Variable lxml.html.InputGetter._all_xpath=lxml.html.InputGetter-class.html#_all_xpath"><a title="lxml.html.InputGetter._all_xpath" class="py-name" href="#" onclick="return doclink('link-606', '_all_xpath', 'link-606');">_all_xpath</a></tt> <tt class="py-op">=</tt> <tt id="link-607" class="py-name"><a title="lxml.etree
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-607', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-608" class="py-name"><a title="lxml.etree.XPath" class="py-name" href="#" onclick="return doclink('link-608', 'XPath', 'link-19');">XPath</a></tt><tt class="py-op">(</tt><tt class="py-string">".//*[@name = $name and (local-name(.) = 'select' or local-name(.) = 'input' or local-name(.) = 'textarea')]"</tt><tt class="py-op">)</tt> </tt>
+<a name="L1017"></a><tt class="py-lineno">1017</tt> <tt class="py-line"> <tt id="link-609" class="py-name" targets="Variable lxml.html.InputGetter._all_xpath=lxml.html.InputGetter-class.html#_all_xpath"><a title="lxml.html.InputGetter._all_xpath" class="py-name" href="#" onclick="return doclink('link-609', '_all_xpath', 'link-609');">_all_xpath</a></tt> <tt class="py-op">=</tt> <tt id="link-610" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-607', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-608" class="py-name"><a title="lxml.etree.XPath" class="py-name" href="#" onclick="return doclink('link-608', 'XPath', 'link-19');">XPath</a></tt><tt class="py-op">(</tt><tt class="py-string">".//*[local-name() = 'select' or local-name() = 'input' or local-name() = 'textarea']"</tt><tt class="py-op">)</tt> </tt>
-<a name="L1017"></a><tt class="py-lineno">1017</tt> <tt class="py-line"> </tt>
-<a name="InputGetter.__init__"></a><div id="InputGetter.__init__-def"><a name="L1018"></a><tt class="py-lineno">1018</tt> <a class="py-toggle" href="#" id="InputGetter.__init__-toggle" onclick="return toggle('InputGetter.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">form</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputGetter.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__init__-expanded"><a name="L1019"></a><tt class="py-lineno">1019</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt> </tt>
-</div><a name="L1020"></a><tt class="py-lineno">1020</tt> <tt class="py-line"> </tt>
-<a name="InputGetter.__repr__"></a><div id="InputGetter.__repr__-def"><a name="L1021"></a><tt class="py-lineno">1021</tt> <a class="py-toggle" href="#" id="InputGetter.__repr__-toggle" onclick="return toggle('InputGetter.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputGetter.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__repr__-expanded"><a name="L1022"></a><tt class="py-lineno">1022</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s for form %s>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
-<a name="L1023"></a><tt class="py-lineno">1023</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
-<a name="L1024"></a><tt class="py-lineno">1024</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-609" class="py-name"><a title="lxml.html.FormElement._name" class="py-name" href="#" onclick="return doclink('link-609', '_name', 'link-602');">_name</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1025"></a><tt class="py-lineno">1025</tt> <tt class="py-line"> </tt>
-<a name="L1026"></a><tt class="py-lineno">1026</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: there should be more methods, and it's unclear if this is</tt> </tt>
-<a name="L1027"></a><tt class="py-lineno">1027</tt> <tt class="py-line"> <tt class="py-comment">## a dictionary-like object or list-like object</tt> </tt>
-<a name="L1028"></a><tt class="py-lineno">1028</tt> <tt class="py-line"> </tt>
-<a name="InputGetter.__getitem__"></a><div id="InputGetter.__getitem__-def"><a name="L1029"></a><tt class="py-lineno">1029</tt> <a class="py-toggle" href="#" id="InputGetter.__getitem__-toggle" onclick="return toggle('InputGetter.__getitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__getitem__">__getitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputGetter.__getitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__getitem__-expanded"><a name="L1030"></a><tt class="py-lineno">1030</tt> <tt class="py-line"> <tt class="py-name">results</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-610" class="py-name"><a title="lxml.html.InputGetter._name_xpath
-lxml.html.formfill._name_xpath" class="py-name" href="#" onclick="return doclink('link-610', '_name_xpath', 'link-603');">_name_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">,</tt> <tt id="link-611" class="py-name"><a title="lxml.etree.DTD.name
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-610', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-611" class="py-name"><a title="lxml.etree.XPath" class="py-name" href="#" onclick="return doclink('link-611', 'XPath', 'link-19');">XPath</a></tt><tt class="py-op">(</tt><tt class="py-string">".//*[local-name() = 'select' or local-name() = 'input' or local-name() = 'textarea']"</tt><tt class="py-op">)</tt> </tt>
+<a name="L1018"></a><tt class="py-lineno">1018</tt> <tt class="py-line"> </tt>
+<a name="InputGetter.__init__"></a><div id="InputGetter.__init__-def"><a name="L1019"></a><tt class="py-lineno">1019</tt> <a class="py-toggle" href="#" id="InputGetter.__init__-toggle" onclick="return toggle('InputGetter.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">form</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputGetter.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__init__-expanded"><a name="L1020"></a><tt class="py-lineno">1020</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt> <tt class="py-op">=</tt> <tt class="py-name">form</tt> </tt>
+</div><a name="L1021"></a><tt class="py-lineno">1021</tt> <tt class="py-line"> </tt>
+<a name="InputGetter.__repr__"></a><div id="InputGetter.__repr__-def"><a name="L1022"></a><tt class="py-lineno">1022</tt> <a class="py-toggle" href="#" id="InputGetter.__repr__-toggle" onclick="return toggle('InputGetter.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputGetter.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__repr__-expanded"><a name="L1023"></a><tt class="py-lineno">1023</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s for form %s>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
+<a name="L1024"></a><tt class="py-lineno">1024</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
+<a name="L1025"></a><tt class="py-lineno">1025</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">.</tt><tt id="link-612" class="py-name"><a title="lxml.html.FormElement._name" class="py-name" href="#" onclick="return doclink('link-612', '_name', 'link-605');">_name</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1026"></a><tt class="py-lineno">1026</tt> <tt class="py-line"> </tt>
+<a name="L1027"></a><tt class="py-lineno">1027</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: there should be more methods, and it's unclear if this is</tt> </tt>
+<a name="L1028"></a><tt class="py-lineno">1028</tt> <tt class="py-line"> <tt class="py-comment">## a dictionary-like object or list-like object</tt> </tt>
+<a name="L1029"></a><tt class="py-lineno">1029</tt> <tt class="py-line"> </tt>
+<a name="InputGetter.__getitem__"></a><div id="InputGetter.__getitem__-def"><a name="L1030"></a><tt class="py-lineno">1030</tt> <a class="py-toggle" href="#" id="InputGetter.__getitem__-toggle" onclick="return toggle('InputGetter.__getitem__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__getitem__">__getitem__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputGetter.__getitem__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__getitem__-expanded"><a name="L1031"></a><tt class="py-lineno">1031</tt> <tt class="py-line"> <tt class="py-name">results</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-613" class="py-name"><a title="lxml.html.InputGetter._name_xpath
+lxml.html.formfill._name_xpath" class="py-name" href="#" onclick="return doclink('link-613', '_name_xpath', 'link-606');">_name_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">,</tt> <tt id="link-614" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-611', 'name', 'link-230');">name</a></tt><tt class="py-op">=</tt><tt id="link-612" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-614', 'name', 'link-233');">name</a></tt><tt class="py-op">=</tt><tt id="link-615" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-612', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1031"></a><tt class="py-lineno">1031</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">results</tt><tt class="py-op">:</tt> </tt>
-<a name="L1032"></a><tt class="py-lineno">1032</tt> <tt class="py-line"> <tt id="link-613" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-613', 'type', 'link-237');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-name">results</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-614" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-615', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1032"></a><tt class="py-lineno">1032</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">results</tt><tt class="py-op">:</tt> </tt>
+<a name="L1033"></a><tt class="py-lineno">1033</tt> <tt class="py-line"> <tt id="link-616" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-616', 'type', 'link-240');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-name">results</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-617" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-614', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'type'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1033"></a><tt class="py-lineno">1033</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-615" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-615', 'type', 'link-237');">type</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'radio'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
-<a name="L1034"></a><tt class="py-lineno">1034</tt> <tt class="py-line"> <tt class="py-name">group</tt> <tt class="py-op">=</tt> <tt id="link-616" class="py-name" targets="Class lxml.html.RadioGroup=lxml.html.RadioGroup-class.html"><a title="lxml.html.RadioGroup" class="py-name" href="#" onclick="return doclink('link-616', 'RadioGroup', 'link-616');">RadioGroup</a></tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> </tt>
-<a name="L1035"></a><tt class="py-lineno">1035</tt> <tt class="py-line"> <tt class="py-name">group</tt><tt class="py-op">.</tt><tt id="link-617" class="py-name"><a title="lxml.etree.DTD.name
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-617', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'type'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1034"></a><tt class="py-lineno">1034</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-618" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-618', 'type', 'link-240');">type</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'radio'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
+<a name="L1035"></a><tt class="py-lineno">1035</tt> <tt class="py-line"> <tt class="py-name">group</tt> <tt class="py-op">=</tt> <tt id="link-619" class="py-name" targets="Class lxml.html.RadioGroup=lxml.html.RadioGroup-class.html"><a title="lxml.html.RadioGroup" class="py-name" href="#" onclick="return doclink('link-619', 'RadioGroup', 'link-619');">RadioGroup</a></tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> </tt>
+<a name="L1036"></a><tt class="py-lineno">1036</tt> <tt class="py-line"> <tt class="py-name">group</tt><tt class="py-op">.</tt><tt id="link-620" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-617', 'name', 'link-230');">name</a></tt> <tt class="py-op">=</tt> <tt id="link-618" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-620', 'name', 'link-233');">name</a></tt> <tt class="py-op">=</tt> <tt id="link-621" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-618', 'name', 'link-230');">name</a></tt> </tt>
-<a name="L1036"></a><tt class="py-lineno">1036</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">group</tt> </tt>
-<a name="L1037"></a><tt class="py-lineno">1037</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-619" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-619', 'type', 'link-237');">type</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'checkbox'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
-<a name="L1038"></a><tt class="py-lineno">1038</tt> <tt class="py-line"> <tt class="py-name">group</tt> <tt class="py-op">=</tt> <tt id="link-620" class="py-name" targets="Class lxml.html.CheckboxGroup=lxml.html.CheckboxGroup-class.html"><a title="lxml.html.CheckboxGroup" class="py-name" href="#" onclick="return doclink('link-620', 'CheckboxGroup', 'link-620');">CheckboxGroup</a></tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> </tt>
-<a name="L1039"></a><tt class="py-lineno">1039</tt> <tt class="py-line"> <tt class="py-name">group</tt><tt class="py-op">.</tt><tt id="link-621" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-621', 'name', 'link-233');">name</a></tt> </tt>
+<a name="L1037"></a><tt class="py-lineno">1037</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">group</tt> </tt>
+<a name="L1038"></a><tt class="py-lineno">1038</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt id="link-622" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-622', 'type', 'link-240');">type</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'checkbox'</tt> <tt class="py-keyword">and</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> <tt class="py-op">></tt> <tt class="py-number">1</tt><tt class="py-op">:</tt> </tt>
+<a name="L1039"></a><tt class="py-lineno">1039</tt> <tt class="py-line"> <tt class="py-name">group</tt> <tt class="py-op">=</tt> <tt id="link-623" class="py-name" targets="Class lxml.html.CheckboxGroup=lxml.html.CheckboxGroup-class.html"><a title="lxml.html.CheckboxGroup" class="py-name" href="#" onclick="return doclink('link-623', 'CheckboxGroup', 'link-623');">CheckboxGroup</a></tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> </tt>
+<a name="L1040"></a><tt class="py-lineno">1040</tt> <tt class="py-line"> <tt class="py-name">group</tt><tt class="py-op">.</tt><tt id="link-624" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-621', 'name', 'link-230');">name</a></tt> <tt class="py-op">=</tt> <tt id="link-622" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-624', 'name', 'link-233');">name</a></tt> <tt class="py-op">=</tt> <tt id="link-625" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-622', 'name', 'link-230');">name</a></tt> </tt>
-<a name="L1040"></a><tt class="py-lineno">1040</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">group</tt> </tt>
-<a name="L1041"></a><tt class="py-lineno">1041</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1042"></a><tt class="py-lineno">1042</tt> <tt class="py-line"> <tt class="py-comment"># I don't like throwing away elements like this</tt> </tt>
-<a name="L1043"></a><tt class="py-lineno">1043</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">results</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
-<a name="L1044"></a><tt class="py-lineno">1044</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1045"></a><tt class="py-lineno">1045</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1046"></a><tt class="py-lineno">1046</tt> <tt class="py-line"> <tt class="py-string">"No input element with the name %r"</tt> <tt class="py-op">%</tt> <tt id="link-623" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-625', 'name', 'link-233');">name</a></tt> </tt>
+<a name="L1041"></a><tt class="py-lineno">1041</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">group</tt> </tt>
+<a name="L1042"></a><tt class="py-lineno">1042</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1043"></a><tt class="py-lineno">1043</tt> <tt class="py-line"> <tt class="py-comment"># I don't like throwing away elements like this</tt> </tt>
+<a name="L1044"></a><tt class="py-lineno">1044</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">results</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> </tt>
+<a name="L1045"></a><tt class="py-lineno">1045</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1046"></a><tt class="py-lineno">1046</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1047"></a><tt class="py-lineno">1047</tt> <tt class="py-line"> <tt class="py-string">"No input element with the name %r"</tt> <tt class="py-op">%</tt> <tt id="link-626" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-623', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1047"></a><tt class="py-lineno">1047</tt> <tt class="py-line"> </tt>
-<a name="InputGetter.__contains__"></a><div id="InputGetter.__contains__-def"><a name="L1048"></a><tt class="py-lineno">1048</tt> <a class="py-toggle" href="#" id="InputGetter.__contains__-toggle" onclick="return toggle('InputGetter.__contains__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__contains__">__contains__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputGetter.__contains__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__contains__-expanded"><a name="L1049"></a><tt class="py-lineno">1049</tt> <tt class="py-line"> <tt class="py-name">results</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-624" class="py-name"><a title="lxml.html.InputGetter._name_xpath
-lxml.html.formfill._name_xpath" class="py-name" href="#" onclick="return doclink('link-624', '_name_xpath', 'link-603');">_name_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">,</tt> <tt id="link-625" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-626', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1048"></a><tt class="py-lineno">1048</tt> <tt class="py-line"> </tt>
+<a name="InputGetter.__contains__"></a><div id="InputGetter.__contains__-def"><a name="L1049"></a><tt class="py-lineno">1049</tt> <a class="py-toggle" href="#" id="InputGetter.__contains__-toggle" onclick="return toggle('InputGetter.__contains__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__contains__">__contains__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">name</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputGetter.__contains__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__contains__-expanded"><a name="L1050"></a><tt class="py-lineno">1050</tt> <tt class="py-line"> <tt class="py-name">results</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-627" class="py-name"><a title="lxml.html.InputGetter._name_xpath
+lxml.html.formfill._name_xpath" class="py-name" href="#" onclick="return doclink('link-627', '_name_xpath', 'link-606');">_name_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">,</tt> <tt id="link-628" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-625', 'name', 'link-230');">name</a></tt><tt class="py-op">=</tt><tt id="link-626" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-628', 'name', 'link-233');">name</a></tt><tt class="py-op">=</tt><tt id="link-629" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-626', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1050"></a><tt class="py-lineno">1050</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">bool</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1051"></a><tt class="py-lineno">1051</tt> <tt class="py-line"> </tt>
-<a name="InputGetter.keys"></a><div id="InputGetter.keys-def"><a name="L1052"></a><tt class="py-lineno">1052</tt> <a class="py-toggle" href="#" id="InputGetter.keys-toggle" onclick="return toggle('InputGetter.keys');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#keys">keys</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputGetter.keys-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.keys-expanded"><a name="L1053"></a><tt class="py-lineno">1053</tt> <tt class="py-line"> <tt class="py-name">names</tt> <tt class="py-op">=</tt> <tt id="link-627" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-627', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1054"></a><tt class="py-lineno">1054</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
-<a name="L1055"></a><tt class="py-lineno">1055</tt> <tt class="py-line"> <tt class="py-name">names</tt><tt class="py-op">.</tt><tt id="link-628" class="py-name" targets="Method lxml.html.CheckboxValues.add()=lxml.html.CheckboxValues-class.html#add,Method lxml.html.MultipleSelectOptions.add()=lxml.html.MultipleSelectOptions-class.html#add"><a title="lxml.html.CheckboxValues.add
-lxml.html.MultipleSelectOptions.add" class="py-name" href="#" onclick="return doclink('link-628', 'add', 'link-628');">add</a></tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-629" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-629', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1051"></a><tt class="py-lineno">1051</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">bool</tt><tt class="py-op">(</tt><tt class="py-name">results</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1052"></a><tt class="py-lineno">1052</tt> <tt class="py-line"> </tt>
+<a name="InputGetter.keys"></a><div id="InputGetter.keys-def"><a name="L1053"></a><tt class="py-lineno">1053</tt> <a class="py-toggle" href="#" id="InputGetter.keys-toggle" onclick="return toggle('InputGetter.keys');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#keys">keys</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputGetter.keys-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.keys-expanded"><a name="L1054"></a><tt class="py-lineno">1054</tt> <tt class="py-line"> <tt class="py-name">names</tt> <tt class="py-op">=</tt> <tt id="link-630" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-630', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1055"></a><tt class="py-lineno">1055</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
+<a name="L1056"></a><tt class="py-lineno">1056</tt> <tt class="py-line"> <tt class="py-name">names</tt><tt class="py-op">.</tt><tt id="link-631" class="py-name" targets="Method lxml.html.CheckboxValues.add()=lxml.html.CheckboxValues-class.html#add,Method lxml.html.MultipleSelectOptions.add()=lxml.html.MultipleSelectOptions-class.html#add"><a title="lxml.html.CheckboxValues.add
+lxml.html.MultipleSelectOptions.add" class="py-name" href="#" onclick="return doclink('link-631', 'add', 'link-631');">add</a></tt><tt class="py-op">(</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-632" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-629', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1056"></a><tt class="py-lineno">1056</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">None</tt> <tt class="py-keyword">in</tt> <tt class="py-name">names</tt><tt class="py-op">:</tt> </tt>
-<a name="L1057"></a><tt class="py-lineno">1057</tt> <tt class="py-line"> <tt class="py-name">names</tt><tt class="py-op">.</tt><tt id="link-630" class="py-name"><a title="lxml.etree._Element.remove
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-632', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1057"></a><tt class="py-lineno">1057</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">None</tt> <tt class="py-keyword">in</tt> <tt class="py-name">names</tt><tt class="py-op">:</tt> </tt>
+<a name="L1058"></a><tt class="py-lineno">1058</tt> <tt class="py-line"> <tt class="py-name">names</tt><tt class="py-op">.</tt><tt id="link-633" class="py-name"><a title="lxml.etree._Element.remove
lxml.html.CheckboxValues.remove
-lxml.html.MultipleSelectOptions.remove" class="py-name" href="#" onclick="return doclink('link-630', 'remove', 'link-108');">remove</a></tt><tt class="py-op">(</tt><tt class="py-name">None</tt><tt class="py-op">)</tt> </tt>
-<a name="L1058"></a><tt class="py-lineno">1058</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">names</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1059"></a><tt class="py-lineno">1059</tt> <tt class="py-line"> </tt>
-<a name="InputGetter.__iter__"></a><div id="InputGetter.__iter__-def"><a name="L1060"></a><tt class="py-lineno">1060</tt> <a class="py-toggle" href="#" id="InputGetter.__iter__-toggle" onclick="return toggle('InputGetter.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputGetter.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__iter__-expanded"><a name="L1061"></a><tt class="py-lineno">1061</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: kind of dumb to turn a list into an iterator, only</tt> </tt>
-<a name="L1062"></a><tt class="py-lineno">1062</tt> <tt class="py-line"> <tt class="py-comment">## to have it likely turned back into a list again :(</tt> </tt>
-<a name="L1063"></a><tt class="py-lineno">1063</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-631" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-631', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-632" class="py-name"><a title="lxml.html.InputGetter._all_xpath" class="py-name" href="#" onclick="return doclink('link-632', '_all_xpath', 'link-606');">_all_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1064"></a><tt class="py-lineno">1064</tt> <tt class="py-line"> </tt>
-<a name="InputMixin"></a><div id="InputMixin-def"><a name="L1065"></a><tt class="py-lineno">1065</tt> <a class="py-toggle" href="#" id="InputMixin-toggle" onclick="return toggle('InputMixin');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html">InputMixin</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputMixin-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="InputMixin-expanded"><a name="L1066"></a><tt class="py-lineno">1066</tt> <tt class="py-line"> </tt>
-<a name="L1067"></a><tt class="py-lineno">1067</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1068"></a><tt class="py-lineno">1068</tt> <tt class="py-line"><tt class="py-docstring"> Mix-in for all input elements (input, select, and textarea)</tt> </tt>
-<a name="L1069"></a><tt class="py-lineno">1069</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1070"></a><tt class="py-lineno">1070</tt> <tt class="py-line"> </tt>
+lxml.html.MultipleSelectOptions.remove" class="py-name" href="#" onclick="return doclink('link-633', 'remove', 'link-109');">remove</a></tt><tt class="py-op">(</tt><tt class="py-name">None</tt><tt class="py-op">)</tt> </tt>
+<a name="L1059"></a><tt class="py-lineno">1059</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">list</tt><tt class="py-op">(</tt><tt class="py-name">names</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1060"></a><tt class="py-lineno">1060</tt> <tt class="py-line"> </tt>
+<a name="InputGetter.__iter__"></a><div id="InputGetter.__iter__-def"><a name="L1061"></a><tt class="py-lineno">1061</tt> <a class="py-toggle" href="#" id="InputGetter.__iter__-toggle" onclick="return toggle('InputGetter.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputGetter-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputGetter.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputGetter.__iter__-expanded"><a name="L1062"></a><tt class="py-lineno">1062</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: kind of dumb to turn a list into an iterator, only</tt> </tt>
+<a name="L1063"></a><tt class="py-lineno">1063</tt> <tt class="py-line"> <tt class="py-comment">## to have it likely turned back into a list again :(</tt> </tt>
+<a name="L1064"></a><tt class="py-lineno">1064</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-634" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-634', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-635" class="py-name"><a title="lxml.html.InputGetter._all_xpath" class="py-name" href="#" onclick="return doclink('link-635', '_all_xpath', 'link-609');">_all_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">form</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1065"></a><tt class="py-lineno">1065</tt> <tt class="py-line"> </tt>
+<a name="InputMixin"></a><div id="InputMixin-def"><a name="L1066"></a><tt class="py-lineno">1066</tt> <a class="py-toggle" href="#" id="InputMixin-toggle" onclick="return toggle('InputMixin');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html">InputMixin</a><tt class="py-op">(</tt><tt class="py-base-class">object</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputMixin-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="InputMixin-expanded"><a name="L1067"></a><tt class="py-lineno">1067</tt> <tt class="py-line"> </tt>
+<a name="L1068"></a><tt class="py-lineno">1068</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1069"></a><tt class="py-lineno">1069</tt> <tt class="py-line"><tt class="py-docstring"> Mix-in for all input elements (input, select, and textarea)</tt> </tt>
+<a name="L1070"></a><tt class="py-lineno">1070</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
<a name="L1071"></a><tt class="py-lineno">1071</tt> <tt class="py-line"> </tt>
-<a name="InputMixin._name__get"></a><div id="InputMixin._name__get-def"><a name="L1072"></a><tt class="py-lineno">1072</tt> <a class="py-toggle" href="#" id="InputMixin._name__get-toggle" onclick="return toggle('InputMixin._name__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#_name__get">_name__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputMixin._name__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin._name__get-expanded"><a name="L1073"></a><tt class="py-lineno">1073</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1074"></a><tt class="py-lineno">1074</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the name of the element</tt> </tt>
-<a name="L1075"></a><tt class="py-lineno">1075</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1076"></a><tt class="py-lineno">1076</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-633" class="py-name"><a title="lxml.etree._Attrib.get
+<a name="L1072"></a><tt class="py-lineno">1072</tt> <tt class="py-line"> </tt>
+<a name="InputMixin._name__get"></a><div id="InputMixin._name__get-def"><a name="L1073"></a><tt class="py-lineno">1073</tt> <a class="py-toggle" href="#" id="InputMixin._name__get-toggle" onclick="return toggle('InputMixin._name__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#_name__get">_name__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputMixin._name__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin._name__get-expanded"><a name="L1074"></a><tt class="py-lineno">1074</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1075"></a><tt class="py-lineno">1075</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the name of the element</tt> </tt>
+<a name="L1076"></a><tt class="py-lineno">1076</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1077"></a><tt class="py-lineno">1077</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-636" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-633', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">)</tt> </tt>
-</div><a name="InputMixin._name__set"></a><div id="InputMixin._name__set-def"><a name="L1077"></a><tt class="py-lineno">1077</tt> <a class="py-toggle" href="#" id="InputMixin._name__set-toggle" onclick="return toggle('InputMixin._name__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#_name__set">_name__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputMixin._name__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin._name__set-expanded"><a name="L1078"></a><tt class="py-lineno">1078</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-634" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-634', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">,</tt> <tt id="link-635" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-636', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">)</tt> </tt>
+</div><a name="InputMixin._name__set"></a><div id="InputMixin._name__set-def"><a name="L1078"></a><tt class="py-lineno">1078</tt> <a class="py-toggle" href="#" id="InputMixin._name__set-toggle" onclick="return toggle('InputMixin._name__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#_name__set">_name__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputMixin._name__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin._name__set-expanded"><a name="L1079"></a><tt class="py-lineno">1079</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-637" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-637', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'name'</tt><tt class="py-op">,</tt> <tt id="link-638" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-635', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="InputMixin._name__del"></a><div id="InputMixin._name__del-def"><a name="L1079"></a><tt class="py-lineno">1079</tt> <a class="py-toggle" href="#" id="InputMixin._name__del-toggle" onclick="return toggle('InputMixin._name__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#_name__del">_name__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputMixin._name__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin._name__del-expanded"><a name="L1080"></a><tt class="py-lineno">1080</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'name'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-636" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-638', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="InputMixin._name__del"></a><div id="InputMixin._name__del-def"><a name="L1080"></a><tt class="py-lineno">1080</tt> <a class="py-toggle" href="#" id="InputMixin._name__del-toggle" onclick="return toggle('InputMixin._name__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#_name__del">_name__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputMixin._name__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin._name__del-expanded"><a name="L1081"></a><tt class="py-lineno">1081</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'name'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-639" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-636', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1081"></a><tt class="py-lineno">1081</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-637" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-639', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1082"></a><tt class="py-lineno">1082</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-640" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-637', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'name'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1082"></a><tt class="py-lineno">1082</tt> <tt class="py-line"> <tt id="link-638" class="py-name"><a title="lxml.etree.DTD.name
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-640', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'name'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1083"></a><tt class="py-lineno">1083</tt> <tt class="py-line"> <tt id="link-641" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-638', 'name', 'link-230');">name</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-639" class="py-name" targets="Method lxml.html.InputMixin._name__get()=lxml.html.InputMixin-class.html#_name__get"><a title="lxml.html.InputMixin._name__get" class="py-name" href="#" onclick="return doclink('link-639', '_name__get', 'link-639');">_name__get</a></tt><tt class="py-op">,</tt> <tt id="link-640" class="py-name" targets="Method lxml.html.InputMixin._name__set()=lxml.html.InputMixin-class.html#_name__set"><a title="lxml.html.InputMixin._name__set" class="py-name" href="#" onclick="return doclink('link-640', '_name__set', 'link-640');">_name__set</a></tt><tt class="py-op">,</tt> <tt id="link-641" class="py-name" targets="Method lxml.html.InputMixin._name__del()=lxml.html.InputMixin-class.html#_name__del"><a title="lxml.html.InputMixin._name__del" class="py-name" href="#" onclick="return doclink('link-641', '_name__del', 'link-641');">_name__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-642" class="py-name"><a title="lxml.html.InputMixin._name__get" class="py-name" href="#" onclick="return doclink('link-642', '_name__get', 'link-639');">_name__get</a></tt><tt class="py-op">.</tt><tt id="link-643" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-643', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1083"></a><tt class="py-lineno">1083</tt> <tt class="py-line"> </tt>
-<a name="InputMixin.__repr__"></a><div id="InputMixin.__repr__-def"><a name="L1084"></a><tt class="py-lineno">1084</tt> <a class="py-toggle" href="#" id="InputMixin.__repr__-toggle" onclick="return toggle('InputMixin.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputMixin.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin.__repr__-expanded"><a name="L1085"></a><tt class="py-lineno">1085</tt> <tt class="py-line"> <tt id="link-644" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-644', 'type', 'link-237');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-name">getattr</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-string">'type'</tt><tt class="py-op">,</tt> <tt class="py-name">None</tt><tt class="py-op">)</tt> </tt>
-<a name="L1086"></a><tt class="py-lineno">1086</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-645" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-645', 'type', 'link-237');">type</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1087"></a><tt class="py-lineno">1087</tt> <tt class="py-line"> <tt id="link-646" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-646', 'type', 'link-237');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-string">' type=%r'</tt> <tt class="py-op">%</tt> <tt id="link-647" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-647', 'type', 'link-237');">type</a></tt> </tt>
-<a name="L1088"></a><tt class="py-lineno">1088</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1089"></a><tt class="py-lineno">1089</tt> <tt class="py-line"> <tt id="link-648" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-648', 'type', 'link-237');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1090"></a><tt class="py-lineno">1090</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s %x name=%r%s>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
-<a name="L1091"></a><tt class="py-lineno">1091</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-649" class="py-name"><a title="lxml.etree.DTD.name
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-641', 'name', 'link-233');">name</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-642" class="py-name" targets="Method lxml.html.InputMixin._name__get()=lxml.html.InputMixin-class.html#_name__get"><a title="lxml.html.InputMixin._name__get" class="py-name" href="#" onclick="return doclink('link-642', '_name__get', 'link-642');">_name__get</a></tt><tt class="py-op">,</tt> <tt id="link-643" class="py-name" targets="Method lxml.html.InputMixin._name__set()=lxml.html.InputMixin-class.html#_name__set"><a title="lxml.html.InputMixin._name__set" class="py-name" href="#" onclick="return doclink('link-643', '_name__set', 'link-643');">_name__set</a></tt><tt class="py-op">,</tt> <tt id="link-644" class="py-name" targets="Method lxml.html.InputMixin._name__del()=lxml.html.InputMixin-class.html#_name__del"><a title="lxml.html.InputMixin._name__del" class="py-name" href="#" onclick="return doclink('link-644', '_name__del', 'link-644');">_name__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-645" class="py-name"><a title="lxml.html.InputMixin._name__get" class="py-name" href="#" onclick="return doclink('link-645', '_name__get', 'link-642');">_name__get</a></tt><tt class="py-op">.</tt><tt id="link-646" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-646', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1084"></a><tt class="py-lineno">1084</tt> <tt class="py-line"> </tt>
+<a name="InputMixin.__repr__"></a><div id="InputMixin.__repr__-def"><a name="L1085"></a><tt class="py-lineno">1085</tt> <a class="py-toggle" href="#" id="InputMixin.__repr__-toggle" onclick="return toggle('InputMixin.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputMixin-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputMixin.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputMixin.__repr__-expanded"><a name="L1086"></a><tt class="py-lineno">1086</tt> <tt class="py-line"> <tt id="link-647" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-647', 'type', 'link-240');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-name">getattr</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">,</tt> <tt class="py-string">'type'</tt><tt class="py-op">,</tt> <tt class="py-name">None</tt><tt class="py-op">)</tt> </tt>
+<a name="L1087"></a><tt class="py-lineno">1087</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-648" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-648', 'type', 'link-240');">type</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1088"></a><tt class="py-lineno">1088</tt> <tt class="py-line"> <tt id="link-649" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-649', 'type', 'link-240');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-string">' type=%r'</tt> <tt class="py-op">%</tt> <tt id="link-650" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-650', 'type', 'link-240');">type</a></tt> </tt>
+<a name="L1089"></a><tt class="py-lineno">1089</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1090"></a><tt class="py-lineno">1090</tt> <tt class="py-line"> <tt id="link-651" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-651', 'type', 'link-240');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1091"></a><tt class="py-lineno">1091</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s %x name=%r%s>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
+<a name="L1092"></a><tt class="py-lineno">1092</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-652" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-649', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt id="link-650" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-650', 'type', 'link-237');">type</a></tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1092"></a><tt class="py-lineno">1092</tt> <tt class="py-line"> </tt>
-<a name="TextareaElement"></a><div id="TextareaElement-def"><a name="L1093"></a><tt class="py-lineno">1093</tt> <a class="py-toggle" href="#" id="TextareaElement-toggle" onclick="return toggle('TextareaElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html">TextareaElement</a><tt class="py-op">(</tt><tt class="py-base-class">InputMixin</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="TextareaElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="TextareaElement-expanded"><a name="L1094"></a><tt class="py-lineno">1094</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1095"></a><tt class="py-lineno">1095</tt> <tt class="py-line"><tt class="py-docstring"> ``<textarea>`` element. You can get the name with ``.name`` and</tt> </tt>
-<a name="L1096"></a><tt class="py-lineno">1096</tt> <tt class="py-line"><tt class="py-docstring"> get/set the value with ``.value``</tt> </tt>
-<a name="L1097"></a><tt class="py-lineno">1097</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1098"></a><tt class="py-lineno">1098</tt> <tt class="py-line"> </tt>
-<a name="TextareaElement._value__get"></a><div id="TextareaElement._value__get-def"><a name="L1099"></a><tt class="py-lineno">1099</tt> <a class="py-toggle" href="#" id="TextareaElement._value__get-toggle" onclick="return toggle('TextareaElement._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="TextareaElement._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="TextareaElement._value__get-expanded"><a name="L1100"></a><tt class="py-lineno">1100</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1101"></a><tt class="py-lineno">1101</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value (which is the contents of this element)</tt> </tt>
-<a name="L1102"></a><tt class="py-lineno">1102</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1103"></a><tt class="py-lineno">1103</tt> <tt class="py-line"> <tt class="py-name">content</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-651" class="py-name"><a title="lxml.etree.QName.text
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-652', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt id="link-653" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-653', 'type', 'link-240');">type</a></tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1093"></a><tt class="py-lineno">1093</tt> <tt class="py-line"> </tt>
+<a name="TextareaElement"></a><div id="TextareaElement-def"><a name="L1094"></a><tt class="py-lineno">1094</tt> <a class="py-toggle" href="#" id="TextareaElement-toggle" onclick="return toggle('TextareaElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html">TextareaElement</a><tt class="py-op">(</tt><tt class="py-base-class">InputMixin</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="TextareaElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="TextareaElement-expanded"><a name="L1095"></a><tt class="py-lineno">1095</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1096"></a><tt class="py-lineno">1096</tt> <tt class="py-line"><tt class="py-docstring"> ``<textarea>`` element. You can get the name with ``.name`` and</tt> </tt>
+<a name="L1097"></a><tt class="py-lineno">1097</tt> <tt class="py-line"><tt class="py-docstring"> get/set the value with ``.value``</tt> </tt>
+<a name="L1098"></a><tt class="py-lineno">1098</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1099"></a><tt class="py-lineno">1099</tt> <tt class="py-line"> </tt>
+<a name="TextareaElement._value__get"></a><div id="TextareaElement._value__get-def"><a name="L1100"></a><tt class="py-lineno">1100</tt> <a class="py-toggle" href="#" id="TextareaElement._value__get-toggle" onclick="return toggle('TextareaElement._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="TextareaElement._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="TextareaElement._value__get-expanded"><a name="L1101"></a><tt class="py-lineno">1101</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1102"></a><tt class="py-lineno">1102</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value (which is the contents of this element)</tt> </tt>
+<a name="L1103"></a><tt class="py-lineno">1103</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1104"></a><tt class="py-lineno">1104</tt> <tt class="py-line"> <tt class="py-name">content</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-654" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-651', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1104"></a><tt class="py-lineno">1104</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-652" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-654', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1105"></a><tt class="py-lineno">1105</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-655" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-652', 'tag', 'link-48');">tag</a></tt><tt class="py-op">.</tt><tt class="py-name">startswith</tt><tt class="py-op">(</tt><tt class="py-string">"{%s}"</tt> <tt class="py-op">%</tt> <tt id="link-653" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-653', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1105"></a><tt class="py-lineno">1105</tt> <tt class="py-line"> <tt class="py-name">serialisation_method</tt> <tt class="py-op">=</tt> <tt class="py-string">'xml'</tt> </tt>
-<a name="L1106"></a><tt class="py-lineno">1106</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1107"></a><tt class="py-lineno">1107</tt> <tt class="py-line"> <tt class="py-name">serialisation_method</tt> <tt class="py-op">=</tt> <tt class="py-string">'html'</tt> </tt>
-<a name="L1108"></a><tt class="py-lineno">1108</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
-<a name="L1109"></a><tt class="py-lineno">1109</tt> <tt class="py-line"> <tt class="py-comment"># it's rare that we actually get here, so let's not use ''.join()</tt> </tt>
-<a name="L1110"></a><tt class="py-lineno">1110</tt> <tt class="py-line"> <tt class="py-name">content</tt> <tt class="py-op">+=</tt> <tt id="link-654" class="py-name"><a title="lxml.etree
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-655', 'tag', 'link-49');">tag</a></tt><tt class="py-op">.</tt><tt class="py-name">startswith</tt><tt class="py-op">(</tt><tt class="py-string">"{%s}"</tt> <tt class="py-op">%</tt> <tt id="link-656" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-656', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1106"></a><tt class="py-lineno">1106</tt> <tt class="py-line"> <tt class="py-name">serialisation_method</tt> <tt class="py-op">=</tt> <tt class="py-string">'xml'</tt> </tt>
+<a name="L1107"></a><tt class="py-lineno">1107</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1108"></a><tt class="py-lineno">1108</tt> <tt class="py-line"> <tt class="py-name">serialisation_method</tt> <tt class="py-op">=</tt> <tt class="py-string">'html'</tt> </tt>
+<a name="L1109"></a><tt class="py-lineno">1109</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
+<a name="L1110"></a><tt class="py-lineno">1110</tt> <tt class="py-line"> <tt class="py-comment"># it's rare that we actually get here, so let's not use ''.join()</tt> </tt>
+<a name="L1111"></a><tt class="py-lineno">1111</tt> <tt class="py-line"> <tt class="py-name">content</tt> <tt class="py-op">+=</tt> <tt id="link-657" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-654', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-655" class="py-name"><a title="lxml.etree.XSLT.tostring
-lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-655', 'tostring', 'link-44');">tostring</a></tt><tt class="py-op">(</tt> </tt>
-<a name="L1111"></a><tt class="py-lineno">1111</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-656" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-656', 'method', 'link-561');">method</a></tt><tt class="py-op">=</tt><tt class="py-name">serialisation_method</tt><tt class="py-op">,</tt> <tt id="link-657" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-657', 'encoding', 'link-45');">encoding</a></tt><tt class="py-op">=</tt><tt class="py-string">'unicode'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1112"></a><tt class="py-lineno">1112</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">content</tt> </tt>
-</div><a name="TextareaElement._value__set"></a><div id="TextareaElement._value__set-def"><a name="L1113"></a><tt class="py-lineno">1113</tt> <a class="py-toggle" href="#" id="TextareaElement._value__set-toggle" onclick="return toggle('TextareaElement._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="TextareaElement._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="TextareaElement._value__set-expanded"><a name="L1114"></a><tt class="py-lineno">1114</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
-<a name="L1115"></a><tt class="py-lineno">1115</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-658" class="py-name"><a title="lxml.etree.QName.text
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-657', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-658" class="py-name"><a title="lxml.etree.XSLT.tostring
+lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-658', 'tostring', 'link-45');">tostring</a></tt><tt class="py-op">(</tt> </tt>
+<a name="L1112"></a><tt class="py-lineno">1112</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">,</tt> <tt id="link-659" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-659', 'method', 'link-564');">method</a></tt><tt class="py-op">=</tt><tt class="py-name">serialisation_method</tt><tt class="py-op">,</tt> <tt id="link-660" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-660', 'encoding', 'link-46');">encoding</a></tt><tt class="py-op">=</tt><tt class="py-string">'unicode'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1113"></a><tt class="py-lineno">1113</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">content</tt> </tt>
+</div><a name="TextareaElement._value__set"></a><div id="TextareaElement._value__set-def"><a name="L1114"></a><tt class="py-lineno">1114</tt> <a class="py-toggle" href="#" id="TextareaElement._value__set-toggle" onclick="return toggle('TextareaElement._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="TextareaElement._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="TextareaElement._value__set-expanded"><a name="L1115"></a><tt class="py-lineno">1115</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
+<a name="L1116"></a><tt class="py-lineno">1116</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-661" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-658', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt id="link-659" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-661', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt id="link-662" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-659', 'value', 'link-172');">value</a></tt> </tt>
-</div><a name="TextareaElement._value__del"></a><div id="TextareaElement._value__del-def"><a name="L1116"></a><tt class="py-lineno">1116</tt> <a class="py-toggle" href="#" id="TextareaElement._value__del-toggle" onclick="return toggle('TextareaElement._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="TextareaElement._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="TextareaElement._value__del-expanded"><a name="L1117"></a><tt class="py-lineno">1117</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-660" class="py-name"><a title="lxml.etree.QName.text
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-662', 'value', 'link-173');">value</a></tt> </tt>
+</div><a name="TextareaElement._value__del"></a><div id="TextareaElement._value__del-def"><a name="L1117"></a><tt class="py-lineno">1117</tt> <a class="py-toggle" href="#" id="TextareaElement._value__del-toggle" onclick="return toggle('TextareaElement._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.TextareaElement-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="TextareaElement._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="TextareaElement._value__del-expanded"><a name="L1118"></a><tt class="py-lineno">1118</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-663" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-660', 'text', 'link-102');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1118"></a><tt class="py-lineno">1118</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1119"></a><tt class="py-lineno">1119</tt> <tt class="py-line"> <tt id="link-661" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-663', 'text', 'link-103');">text</a></tt> <tt class="py-op">=</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1119"></a><tt class="py-lineno">1119</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1120"></a><tt class="py-lineno">1120</tt> <tt class="py-line"> <tt id="link-664" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-661', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-662" class="py-name" targets="Method lxml.html.CheckboxGroup._value__get()=lxml.html.CheckboxGroup-class.html#_value__get,Method lxml.html.InputElement._value__get()=lxml.html.InputElement-class.html#_value__get,Method lxml.html.RadioGroup._value__get()=lxml.html.RadioGroup-class.html#_value__get,Method lxml.html.SelectElement._value__get()=lxml.html.SelectElement-class.html#_value__get,Method lxml.html.TextareaElement._value__get()=lxml.html.TextareaElement-class.html#_value__get"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-664', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-665" class="py-name" targets="Method lxml.html.CheckboxGroup._value__get()=lxml.html.CheckboxGroup-class.html#_value__get,Method lxml.html.InputElement._value__get()=lxml.html.InputElement-class.html#_value__get,Method lxml.html.RadioGroup._value__get()=lxml.html.RadioGroup-class.html#_value__get,Method lxml.html.SelectElement._value__get()=lxml.html.SelectElement-class.html#_value__get,Method lxml.html.TextareaElement._value__get()=lxml.html.TextareaElement-class.html#_value__get"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-662', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-663" class="py-name" targets="Method lxml.html.CheckboxGroup._value__set()=lxml.html.CheckboxGroup-class.html#_value__set,Method lxml.html.InputElement._value__set()=lxml.html.InputElement-class.html#_value__set,Method lxml.html.RadioGroup._value__set()=lxml.html.RadioGroup-class.html#_value__set,Method lxml.html.SelectElement._value__set()=lxml.html.SelectElement-class.html#_value__set,Method lxml.html.TextareaElement._value__set()=lxml.html.TextareaElement-class.html#_value__set"><a title="lxml.html.CheckboxGroup._value__set
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-665', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-666" class="py-name" targets="Method lxml.html.CheckboxGroup._value__set()=lxml.html.CheckboxGroup-class.html#_value__set,Method lxml.html.InputElement._value__set()=lxml.html.InputElement-class.html#_value__set,Method lxml.html.RadioGroup._value__set()=lxml.html.RadioGroup-class.html#_value__set,Method lxml.html.SelectElement._value__set()=lxml.html.SelectElement-class.html#_value__set,Method lxml.html.TextareaElement._value__set()=lxml.html.TextareaElement-class.html#_value__set"><a title="lxml.html.CheckboxGroup._value__set
lxml.html.InputElement._value__set
lxml.html.RadioGroup._value__set
lxml.html.SelectElement._value__set
-lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-663', '_value__set', 'link-663');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-664" class="py-name" targets="Method lxml.html.CheckboxGroup._value__del()=lxml.html.CheckboxGroup-class.html#_value__del,Method lxml.html.InputElement._value__del()=lxml.html.InputElement-class.html#_value__del,Method lxml.html.RadioGroup._value__del()=lxml.html.RadioGroup-class.html#_value__del,Method lxml.html.SelectElement._value__del()=lxml.html.SelectElement-class.html#_value__del,Method lxml.html.TextareaElement._value__del()=lxml.html.TextareaElement-class.html#_value__del"><a title="lxml.html.CheckboxGroup._value__del
+lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-666', '_value__set', 'link-666');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-667" class="py-name" targets="Method lxml.html.CheckboxGroup._value__del()=lxml.html.CheckboxGroup-class.html#_value__del,Method lxml.html.InputElement._value__del()=lxml.html.InputElement-class.html#_value__del,Method lxml.html.RadioGroup._value__del()=lxml.html.RadioGroup-class.html#_value__del,Method lxml.html.SelectElement._value__del()=lxml.html.SelectElement-class.html#_value__del,Method lxml.html.TextareaElement._value__del()=lxml.html.TextareaElement-class.html#_value__del"><a title="lxml.html.CheckboxGroup._value__del
lxml.html.InputElement._value__del
lxml.html.RadioGroup._value__del
lxml.html.SelectElement._value__del
-lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-664', '_value__del', 'link-664');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-665" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-667', '_value__del', 'link-667');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-668" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-665', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-666" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-666', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1120"></a><tt class="py-lineno">1120</tt> <tt class="py-line"> </tt>
-<a name="L1121"></a><tt class="py-lineno">1121</tt> <tt class="py-line"><tt id="link-667" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-667', 'HtmlElementClassLookup', 'link-566');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-668" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-668', '_default_element_classes', 'link-263');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'textarea'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-669" class="py-name" targets="Class lxml.html.TextareaElement=lxml.html.TextareaElement-class.html"><a title="lxml.html.TextareaElement" class="py-name" href="#" onclick="return doclink('link-669', 'TextareaElement', 'link-669');">TextareaElement</a></tt> </tt>
-<a name="L1122"></a><tt class="py-lineno">1122</tt> <tt class="py-line"> </tt>
-<a name="SelectElement"></a><div id="SelectElement-def"><a name="L1123"></a><tt class="py-lineno">1123</tt> <a class="py-toggle" href="#" id="SelectElement-toggle" onclick="return toggle('SelectElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html">SelectElement</a><tt class="py-op">(</tt><tt class="py-base-class">InputMixin</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="SelectElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="SelectElement-expanded"><a name="L1124"></a><tt class="py-lineno">1124</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1125"></a><tt class="py-lineno">1125</tt> <tt class="py-line"><tt class="py-docstring"> ``<select>`` element. You can get the name with ``.name``.</tt> </tt>
-<a name="L1126"></a><tt class="py-lineno">1126</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1127"></a><tt class="py-lineno">1127</tt> <tt class="py-line"><tt class="py-docstring"> ``.value`` will be the value of the selected option, unless this</tt> </tt>
-<a name="L1128"></a><tt class="py-lineno">1128</tt> <tt class="py-line"><tt class="py-docstring"> is a multi-select element (``<select multiple>``), in which case</tt> </tt>
-<a name="L1129"></a><tt class="py-lineno">1129</tt> <tt class="py-line"><tt class="py-docstring"> it will be a set-like object. In either case ``.value_options``</tt> </tt>
-<a name="L1130"></a><tt class="py-lineno">1130</tt> <tt class="py-line"><tt class="py-docstring"> gives the possible values.</tt> </tt>
-<a name="L1131"></a><tt class="py-lineno">1131</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1132"></a><tt class="py-lineno">1132</tt> <tt class="py-line"><tt class="py-docstring"> The boolean attribute ``.multiple`` shows if this is a</tt> </tt>
-<a name="L1133"></a><tt class="py-lineno">1133</tt> <tt class="py-line"><tt class="py-docstring"> multi-select.</tt> </tt>
-<a name="L1134"></a><tt class="py-lineno">1134</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1135"></a><tt class="py-lineno">1135</tt> <tt class="py-line"> </tt>
-<a name="SelectElement._value__get"></a><div id="SelectElement._value__get-def"><a name="L1136"></a><tt class="py-lineno">1136</tt> <a class="py-toggle" href="#" id="SelectElement._value__get-toggle" onclick="return toggle('SelectElement._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="SelectElement._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._value__get-expanded"><a name="L1137"></a><tt class="py-lineno">1137</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1138"></a><tt class="py-lineno">1138</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value of this select (the selected option).</tt> </tt>
-<a name="L1139"></a><tt class="py-lineno">1139</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1140"></a><tt class="py-lineno">1140</tt> <tt class="py-line"><tt class="py-docstring"> If this is a multi-select, this is a set-like object that</tt> </tt>
-<a name="L1141"></a><tt class="py-lineno">1141</tt> <tt class="py-line"><tt class="py-docstring"> represents all the selected options.</tt> </tt>
-<a name="L1142"></a><tt class="py-lineno">1142</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1143"></a><tt class="py-lineno">1143</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-670" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-670', 'multiple', 'link-519');">multiple</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1144"></a><tt class="py-lineno">1144</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-671" class="py-name" targets="Class lxml.html.MultipleSelectOptions=lxml.html.MultipleSelectOptions-class.html"><a title="lxml.html.MultipleSelectOptions" class="py-name" href="#" onclick="return doclink('link-671', 'MultipleSelectOptions', 'link-671');">MultipleSelectOptions</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-<a name="L1145"></a><tt class="py-lineno">1145</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-672" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-672', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1146"></a><tt class="py-lineno">1146</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-673" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-668', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-669" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-669', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1121"></a><tt class="py-lineno">1121</tt> <tt class="py-line"> </tt>
+<a name="L1122"></a><tt class="py-lineno">1122</tt> <tt class="py-line"><tt id="link-670" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-670', 'HtmlElementClassLookup', 'link-569');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-671" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-671', '_default_element_classes', 'link-266');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'textarea'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-672" class="py-name" targets="Class lxml.html.TextareaElement=lxml.html.TextareaElement-class.html"><a title="lxml.html.TextareaElement" class="py-name" href="#" onclick="return doclink('link-672', 'TextareaElement', 'link-672');">TextareaElement</a></tt> </tt>
+<a name="L1123"></a><tt class="py-lineno">1123</tt> <tt class="py-line"> </tt>
+<a name="SelectElement"></a><div id="SelectElement-def"><a name="L1124"></a><tt class="py-lineno">1124</tt> <a class="py-toggle" href="#" id="SelectElement-toggle" onclick="return toggle('SelectElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html">SelectElement</a><tt class="py-op">(</tt><tt class="py-base-class">InputMixin</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="SelectElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="SelectElement-expanded"><a name="L1125"></a><tt class="py-lineno">1125</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1126"></a><tt class="py-lineno">1126</tt> <tt class="py-line"><tt class="py-docstring"> ``<select>`` element. You can get the name with ``.name``.</tt> </tt>
+<a name="L1127"></a><tt class="py-lineno">1127</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1128"></a><tt class="py-lineno">1128</tt> <tt class="py-line"><tt class="py-docstring"> ``.value`` will be the value of the selected option, unless this</tt> </tt>
+<a name="L1129"></a><tt class="py-lineno">1129</tt> <tt class="py-line"><tt class="py-docstring"> is a multi-select element (``<select multiple>``), in which case</tt> </tt>
+<a name="L1130"></a><tt class="py-lineno">1130</tt> <tt class="py-line"><tt class="py-docstring"> it will be a set-like object. In either case ``.value_options``</tt> </tt>
+<a name="L1131"></a><tt class="py-lineno">1131</tt> <tt class="py-line"><tt class="py-docstring"> gives the possible values.</tt> </tt>
+<a name="L1132"></a><tt class="py-lineno">1132</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1133"></a><tt class="py-lineno">1133</tt> <tt class="py-line"><tt class="py-docstring"> The boolean attribute ``.multiple`` shows if this is a</tt> </tt>
+<a name="L1134"></a><tt class="py-lineno">1134</tt> <tt class="py-line"><tt class="py-docstring"> multi-select.</tt> </tt>
+<a name="L1135"></a><tt class="py-lineno">1135</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1136"></a><tt class="py-lineno">1136</tt> <tt class="py-line"> </tt>
+<a name="SelectElement._value__get"></a><div id="SelectElement._value__get-def"><a name="L1137"></a><tt class="py-lineno">1137</tt> <a class="py-toggle" href="#" id="SelectElement._value__get-toggle" onclick="return toggle('SelectElement._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="SelectElement._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._value__get-expanded"><a name="L1138"></a><tt class="py-lineno">1138</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1139"></a><tt class="py-lineno">1139</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value of this select (the selected option).</tt> </tt>
+<a name="L1140"></a><tt class="py-lineno">1140</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1141"></a><tt class="py-lineno">1141</tt> <tt class="py-line"><tt class="py-docstring"> If this is a multi-select, this is a set-like object that</tt> </tt>
+<a name="L1142"></a><tt class="py-lineno">1142</tt> <tt class="py-line"><tt class="py-docstring"> represents all the selected options.</tt> </tt>
+<a name="L1143"></a><tt class="py-lineno">1143</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1144"></a><tt class="py-lineno">1144</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-673" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-673', 'multiple', 'link-522');">multiple</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1145"></a><tt class="py-lineno">1145</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-674" class="py-name" targets="Class lxml.html.MultipleSelectOptions=lxml.html.MultipleSelectOptions-class.html"><a title="lxml.html.MultipleSelectOptions" class="py-name" href="#" onclick="return doclink('link-674', 'MultipleSelectOptions', 'link-674');">MultipleSelectOptions</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+<a name="L1146"></a><tt class="py-lineno">1146</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-675" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-675', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1147"></a><tt class="py-lineno">1147</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-676" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-673', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'selected'</tt><tt class="py-op">)</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1147"></a><tt class="py-lineno">1147</tt> <tt class="py-line"> <tt id="link-674" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-676', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'selected'</tt><tt class="py-op">)</tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1148"></a><tt class="py-lineno">1148</tt> <tt class="py-line"> <tt id="link-677" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-674', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-675" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-677', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-678" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-675', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1148"></a><tt class="py-lineno">1148</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-676" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-678', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1149"></a><tt class="py-lineno">1149</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-679" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-676', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1149"></a><tt class="py-lineno">1149</tt> <tt class="py-line"> <tt id="link-677" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-679', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1150"></a><tt class="py-lineno">1150</tt> <tt class="py-line"> <tt id="link-680" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-677', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-678" class="py-name"><a title="lxml.etree.QName.text
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-680', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-681" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-678', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1150"></a><tt class="py-lineno">1150</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-679" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-681', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1151"></a><tt class="py-lineno">1151</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-682" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-679', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1151"></a><tt class="py-lineno">1151</tt> <tt class="py-line"> <tt id="link-680" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-682', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1152"></a><tt class="py-lineno">1152</tt> <tt class="py-line"> <tt id="link-683" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-680', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-681" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-683', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-684" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-681', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-682" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-682', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1152"></a><tt class="py-lineno">1152</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-683" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-684', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-685" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-685', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1153"></a><tt class="py-lineno">1153</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-686" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-683', 'value', 'link-172');">value</a></tt> </tt>
-<a name="L1153"></a><tt class="py-lineno">1153</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-</div><a name="L1154"></a><tt class="py-lineno">1154</tt> <tt class="py-line"> </tt>
-<a name="SelectElement._value__set"></a><div id="SelectElement._value__set-def"><a name="L1155"></a><tt class="py-lineno">1155</tt> <a class="py-toggle" href="#" id="SelectElement._value__set-toggle" onclick="return toggle('SelectElement._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="SelectElement._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._value__set-expanded"><a name="L1156"></a><tt class="py-lineno">1156</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-684" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-684', 'multiple', 'link-519');">multiple</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1157"></a><tt class="py-lineno">1157</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-685" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-686', 'value', 'link-173');">value</a></tt> </tt>
+<a name="L1154"></a><tt class="py-lineno">1154</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
+</div><a name="L1155"></a><tt class="py-lineno">1155</tt> <tt class="py-line"> </tt>
+<a name="SelectElement._value__set"></a><div id="SelectElement._value__set-def"><a name="L1156"></a><tt class="py-lineno">1156</tt> <a class="py-toggle" href="#" id="SelectElement._value__set-toggle" onclick="return toggle('SelectElement._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="SelectElement._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._value__set-expanded"><a name="L1157"></a><tt class="py-lineno">1157</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-687" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-687', 'multiple', 'link-522');">multiple</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1158"></a><tt class="py-lineno">1158</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-688" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-685', 'value', 'link-172');">value</a></tt><tt class="py-op">,</tt> <tt id="link-686" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-686', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1158"></a><tt class="py-lineno">1158</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1159"></a><tt class="py-lineno">1159</tt> <tt class="py-line"> <tt class="py-string">"You must pass in a sequence"</tt><tt class="py-op">)</tt> </tt>
-<a name="L1160"></a><tt class="py-lineno">1160</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-687" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-688', 'value', 'link-173');">value</a></tt><tt class="py-op">,</tt> <tt id="link-689" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-689', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1159"></a><tt class="py-lineno">1159</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1160"></a><tt class="py-lineno">1160</tt> <tt class="py-line"> <tt class="py-string">"You must pass in a sequence"</tt><tt class="py-op">)</tt> </tt>
+<a name="L1161"></a><tt class="py-lineno">1161</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-690" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-687', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-688" class="py-name" targets="Method lxml.etree._Attrib.clear()=lxml.etree._Attrib-class.html#clear,Method lxml.etree._Element.clear()=lxml.etree._Element-class.html#clear,Method lxml.etree._ErrorLog.clear()=lxml.etree._ErrorLog-class.html#clear"><a title="lxml.etree._Attrib.clear
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-690', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-691" class="py-name" targets="Method lxml.etree._Attrib.clear()=lxml.etree._Attrib-class.html#clear,Method lxml.etree._Element.clear()=lxml.etree._Element-class.html#clear,Method lxml.etree._ErrorLog.clear()=lxml.etree._ErrorLog-class.html#clear"><a title="lxml.etree._Attrib.clear
lxml.etree._Element.clear
-lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-688', 'clear', 'link-688');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1161"></a><tt class="py-lineno">1161</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-689" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-691', 'clear', 'link-691');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1162"></a><tt class="py-lineno">1162</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-692" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-689', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-690" class="py-name" targets="Method lxml.etree._Attrib.update()=lxml.etree._Attrib-class.html#update"><a title="lxml.etree._Attrib.update" class="py-name" href="#" onclick="return doclink('link-690', 'update', 'link-690');">update</a></tt><tt class="py-op">(</tt><tt id="link-691" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-692', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-693" class="py-name" targets="Method lxml.etree._Attrib.update()=lxml.etree._Attrib-class.html#update"><a title="lxml.etree._Attrib.update" class="py-name" href="#" onclick="return doclink('link-693', 'update', 'link-693');">update</a></tt><tt class="py-op">(</tt><tt id="link-694" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-691', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1162"></a><tt class="py-lineno">1162</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> </tt>
-<a name="L1163"></a><tt class="py-lineno">1163</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-692" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-694', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1163"></a><tt class="py-lineno">1163</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> </tt>
+<a name="L1164"></a><tt class="py-lineno">1164</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-695" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-692', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1164"></a><tt class="py-lineno">1164</tt> <tt class="py-line"> <tt id="link-693" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-695', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1165"></a><tt class="py-lineno">1165</tt> <tt class="py-line"> <tt id="link-696" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-693', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-694" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-696', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-697" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-694', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-695" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-695', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1165"></a><tt class="py-lineno">1165</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-696" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-696', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1166"></a><tt class="py-lineno">1166</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-697" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-697', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-698" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-698', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1166"></a><tt class="py-lineno">1166</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-699" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-699', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1167"></a><tt class="py-lineno">1167</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-700" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-697', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1167"></a><tt class="py-lineno">1167</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1168"></a><tt class="py-lineno">1168</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-698" class="py-name"><a title="lxml.etree.QName.text
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-700', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1168"></a><tt class="py-lineno">1168</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1169"></a><tt class="py-lineno">1169</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-701" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-698', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1169"></a><tt class="py-lineno">1169</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
-<a name="L1170"></a><tt class="py-lineno">1170</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-699" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-699', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1171"></a><tt class="py-lineno">1171</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-op">==</tt> <tt id="link-700" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-701', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1170"></a><tt class="py-lineno">1170</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
+<a name="L1171"></a><tt class="py-lineno">1171</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-702" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-702', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1172"></a><tt class="py-lineno">1172</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-op">==</tt> <tt id="link-703" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-700', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1172"></a><tt class="py-lineno">1172</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt> </tt>
-<a name="L1173"></a><tt class="py-lineno">1173</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
-<a name="L1174"></a><tt class="py-lineno">1174</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1175"></a><tt class="py-lineno">1175</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1176"></a><tt class="py-lineno">1176</tt> <tt class="py-line"> <tt class="py-string">"There is no option with the value of %r"</tt> <tt class="py-op">%</tt> <tt id="link-701" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-703', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1173"></a><tt class="py-lineno">1173</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt> </tt>
+<a name="L1174"></a><tt class="py-lineno">1174</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
+<a name="L1175"></a><tt class="py-lineno">1175</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1176"></a><tt class="py-lineno">1176</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1177"></a><tt class="py-lineno">1177</tt> <tt class="py-line"> <tt class="py-string">"There is no option with the value of %r"</tt> <tt class="py-op">%</tt> <tt id="link-704" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-701', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1177"></a><tt class="py-lineno">1177</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-702" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-702', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1178"></a><tt class="py-lineno">1178</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'selected'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-703" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-704', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1178"></a><tt class="py-lineno">1178</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-705" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-705', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1179"></a><tt class="py-lineno">1179</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'selected'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-706" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-703', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1179"></a><tt class="py-lineno">1179</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-704" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-706', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1180"></a><tt class="py-lineno">1180</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-707" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-704', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'selected'</tt><tt class="py-op">]</tt> </tt>
-<a name="L1180"></a><tt class="py-lineno">1180</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-705" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-707', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'selected'</tt><tt class="py-op">]</tt> </tt>
+<a name="L1181"></a><tt class="py-lineno">1181</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-708" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-705', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1181"></a><tt class="py-lineno">1181</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt><tt class="py-op">.</tt><tt id="link-706" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-706', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'selected'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1182"></a><tt class="py-lineno">1182</tt> <tt class="py-line"> </tt>
-<a name="SelectElement._value__del"></a><div id="SelectElement._value__del-def"><a name="L1183"></a><tt class="py-lineno">1183</tt> <a class="py-toggle" href="#" id="SelectElement._value__del-toggle" onclick="return toggle('SelectElement._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="SelectElement._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._value__del-expanded"><a name="L1184"></a><tt class="py-lineno">1184</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: should del be allowed at all?</tt> </tt>
-<a name="L1185"></a><tt class="py-lineno">1185</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-707" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-707', 'multiple', 'link-519');">multiple</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1186"></a><tt class="py-lineno">1186</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-708" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-708', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1182"></a><tt class="py-lineno">1182</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt><tt class="py-op">.</tt><tt id="link-709" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-709', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'selected'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1183"></a><tt class="py-lineno">1183</tt> <tt class="py-line"> </tt>
+<a name="SelectElement._value__del"></a><div id="SelectElement._value__del-def"><a name="L1184"></a><tt class="py-lineno">1184</tt> <a class="py-toggle" href="#" id="SelectElement._value__del-toggle" onclick="return toggle('SelectElement._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="SelectElement._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._value__del-expanded"><a name="L1185"></a><tt class="py-lineno">1185</tt> <tt class="py-line"> <tt class="py-comment"># FIXME: should del be allowed at all?</tt> </tt>
+<a name="L1186"></a><tt class="py-lineno">1186</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-710" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-710', 'multiple', 'link-522');">multiple</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1187"></a><tt class="py-lineno">1187</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-711" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-708', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-709" class="py-name"><a title="lxml.etree._Attrib.clear
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-711', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-712" class="py-name"><a title="lxml.etree._Attrib.clear
lxml.etree._Element.clear
-lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-709', 'clear', 'link-688');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1187"></a><tt class="py-lineno">1187</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1188"></a><tt class="py-lineno">1188</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-710" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-712', 'clear', 'link-691');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1188"></a><tt class="py-lineno">1188</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1189"></a><tt class="py-lineno">1189</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-713" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-710', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-</div><a name="L1189"></a><tt class="py-lineno">1189</tt> <tt class="py-line"> </tt>
-<a name="L1190"></a><tt class="py-lineno">1190</tt> <tt class="py-line"> <tt id="link-711" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-713', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+</div><a name="L1190"></a><tt class="py-lineno">1190</tt> <tt class="py-line"> </tt>
+<a name="L1191"></a><tt class="py-lineno">1191</tt> <tt class="py-line"> <tt id="link-714" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-711', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-712" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-714', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-715" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-712', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-713" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-715', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-716" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
lxml.html.InputElement._value__set
lxml.html.RadioGroup._value__set
lxml.html.SelectElement._value__set
-lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-713', '_value__set', 'link-663');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-714" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
+lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-716', '_value__set', 'link-666');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-717" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
lxml.html.InputElement._value__del
lxml.html.RadioGroup._value__del
lxml.html.SelectElement._value__del
-lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-714', '_value__del', 'link-664');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-715" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-717', '_value__del', 'link-667');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-718" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-715', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-716" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-716', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1191"></a><tt class="py-lineno">1191</tt> <tt class="py-line"> </tt>
-<a name="SelectElement.value_options"></a><div id="SelectElement.value_options-def"><a name="L1192"></a><tt class="py-lineno">1192</tt> <a class="py-toggle" href="#" id="SelectElement.value_options-toggle" onclick="return toggle('SelectElement.value_options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#value_options">value_options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="SelectElement.value_options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement.value_options-expanded"><a name="L1193"></a><tt class="py-lineno">1193</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1194"></a><tt class="py-lineno">1194</tt> <tt class="py-line"><tt class="py-docstring"> All the possible values this select can have (the ``value``</tt> </tt>
-<a name="L1195"></a><tt class="py-lineno">1195</tt> <tt class="py-line"><tt class="py-docstring"> attribute of all the ``<option>`` elements.</tt> </tt>
-<a name="L1196"></a><tt class="py-lineno">1196</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1197"></a><tt class="py-lineno">1197</tt> <tt class="py-line"> <tt id="link-717" class="py-name" targets="Variable lxml.etree.XSLTAccessControl.options=lxml.etree.XSLTAccessControl-class.html#options,Variable lxml.html.MultipleSelectOptions.options=lxml.html.MultipleSelectOptions-class.html#options"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-717', 'options', 'link-717');">options</a></tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
-<a name="L1198"></a><tt class="py-lineno">1198</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-718" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-718', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1199"></a><tt class="py-lineno">1199</tt> <tt class="py-line"> <tt id="link-719" class="py-name"><a title="lxml.html.CheckboxGroup.value
-lxml.html.InputElement.value
-lxml.html.RadioGroup.value
-lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-719', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-720" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-718', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-719" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-719', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1192"></a><tt class="py-lineno">1192</tt> <tt class="py-line"> </tt>
+<a name="SelectElement.value_options"></a><div id="SelectElement.value_options-def"><a name="L1193"></a><tt class="py-lineno">1193</tt> <a class="py-toggle" href="#" id="SelectElement.value_options-toggle" onclick="return toggle('SelectElement.value_options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#value_options">value_options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="SelectElement.value_options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement.value_options-expanded"><a name="L1194"></a><tt class="py-lineno">1194</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1195"></a><tt class="py-lineno">1195</tt> <tt class="py-line"><tt class="py-docstring"> All the possible values this select can have (the ``value``</tt> </tt>
+<a name="L1196"></a><tt class="py-lineno">1196</tt> <tt class="py-line"><tt class="py-docstring"> attribute of all the ``<option>`` elements.</tt> </tt>
+<a name="L1197"></a><tt class="py-lineno">1197</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1198"></a><tt class="py-lineno">1198</tt> <tt class="py-line"> <tt id="link-720" class="py-name" targets="Variable lxml.etree.XSLTAccessControl.options=lxml.etree.XSLTAccessControl-class.html#options,Variable lxml.html.MultipleSelectOptions.options=lxml.html.MultipleSelectOptions-class.html#options"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-720', 'options', 'link-720');">options</a></tt> <tt class="py-op">=</tt> <tt class="py-op">[</tt><tt class="py-op">]</tt> </tt>
+<a name="L1199"></a><tt class="py-lineno">1199</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-721" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-721', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1200"></a><tt class="py-lineno">1200</tt> <tt class="py-line"> <tt id="link-722" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputElement.value
+lxml.html.RadioGroup.value
+lxml.html.SelectElement.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-722', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-723" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-720', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1200"></a><tt class="py-lineno">1200</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-721" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-723', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1201"></a><tt class="py-lineno">1201</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-724" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-721', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1201"></a><tt class="py-lineno">1201</tt> <tt class="py-line"> <tt id="link-722" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-724', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1202"></a><tt class="py-lineno">1202</tt> <tt class="py-line"> <tt id="link-725" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-722', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-723" class="py-name"><a title="lxml.etree.QName.text
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-725', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-726" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-723', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1202"></a><tt class="py-lineno">1202</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-724" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-726', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1203"></a><tt class="py-lineno">1203</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-727" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-724', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1203"></a><tt class="py-lineno">1203</tt> <tt class="py-line"> <tt id="link-725" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-727', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1204"></a><tt class="py-lineno">1204</tt> <tt class="py-line"> <tt id="link-728" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-725', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-726" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-728', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt id="link-729" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-726', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-727" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-727', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1204"></a><tt class="py-lineno">1204</tt> <tt class="py-line"> <tt id="link-728" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-728', 'options', 'link-717');">options</a></tt><tt class="py-op">.</tt><tt id="link-729" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-729', 'append', 'link-273');">append</a></tt><tt class="py-op">(</tt><tt id="link-730" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-729', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-730" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-730', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1205"></a><tt class="py-lineno">1205</tt> <tt class="py-line"> <tt id="link-731" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-731', 'options', 'link-720');">options</a></tt><tt class="py-op">.</tt><tt id="link-732" class="py-name"><a title="lxml.etree._Element.append" class="py-name" href="#" onclick="return doclink('link-732', 'append', 'link-276');">append</a></tt><tt class="py-op">(</tt><tt id="link-733" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-730', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1205"></a><tt class="py-lineno">1205</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-731" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-731', 'options', 'link-717');">options</a></tt> </tt>
-</div><a name="L1206"></a><tt class="py-lineno">1206</tt> <tt class="py-line"> <tt id="link-732" class="py-name" targets="Variable lxml.html.CheckboxGroup.value_options=lxml.html.CheckboxGroup-class.html#value_options,Variable lxml.html.RadioGroup.value_options=lxml.html.RadioGroup-class.html#value_options,Variable lxml.html.SelectElement.value_options=lxml.html.SelectElement-class.html#value_options"><a title="lxml.html.CheckboxGroup.value_options
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-733', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1206"></a><tt class="py-lineno">1206</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-734" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-734', 'options', 'link-720');">options</a></tt> </tt>
+</div><a name="L1207"></a><tt class="py-lineno">1207</tt> <tt class="py-line"> <tt id="link-735" class="py-name" targets="Variable lxml.html.CheckboxGroup.value_options=lxml.html.CheckboxGroup-class.html#value_options,Variable lxml.html.RadioGroup.value_options=lxml.html.RadioGroup-class.html#value_options,Variable lxml.html.SelectElement.value_options=lxml.html.SelectElement-class.html#value_options"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-732', 'value_options', 'link-732');">value_options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-733" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-735', 'value_options', 'link-735');">value_options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-736" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-733', 'value_options', 'link-732');">value_options</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-734" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-736', 'value_options', 'link-735');">value_options</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-737" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-734', 'value_options', 'link-732');">value_options</a></tt><tt class="py-op">.</tt><tt id="link-735" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-735', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1207"></a><tt class="py-lineno">1207</tt> <tt class="py-line"> </tt>
-<a name="SelectElement._multiple__get"></a><div id="SelectElement._multiple__get-def"><a name="L1208"></a><tt class="py-lineno">1208</tt> <a class="py-toggle" href="#" id="SelectElement._multiple__get-toggle" onclick="return toggle('SelectElement._multiple__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_multiple__get">_multiple__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="SelectElement._multiple__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._multiple__get-expanded"><a name="L1209"></a><tt class="py-lineno">1209</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1210"></a><tt class="py-lineno">1210</tt> <tt class="py-line"><tt class="py-docstring"> Boolean attribute: is there a ``multiple`` attribute on this element.</tt> </tt>
-<a name="L1211"></a><tt class="py-lineno">1211</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1212"></a><tt class="py-lineno">1212</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'multiple'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-736" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-737', 'value_options', 'link-735');">value_options</a></tt><tt class="py-op">.</tt><tt id="link-738" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-738', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1208"></a><tt class="py-lineno">1208</tt> <tt class="py-line"> </tt>
+<a name="SelectElement._multiple__get"></a><div id="SelectElement._multiple__get-def"><a name="L1209"></a><tt class="py-lineno">1209</tt> <a class="py-toggle" href="#" id="SelectElement._multiple__get-toggle" onclick="return toggle('SelectElement._multiple__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_multiple__get">_multiple__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="SelectElement._multiple__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._multiple__get-expanded"><a name="L1210"></a><tt class="py-lineno">1210</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1211"></a><tt class="py-lineno">1211</tt> <tt class="py-line"><tt class="py-docstring"> Boolean attribute: is there a ``multiple`` attribute on this element.</tt> </tt>
+<a name="L1212"></a><tt class="py-lineno">1212</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1213"></a><tt class="py-lineno">1213</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'multiple'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-739" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-736', 'attrib', 'link-92');">attrib</a></tt> </tt>
-</div><a name="SelectElement._multiple__set"></a><div id="SelectElement._multiple__set-def"><a name="L1213"></a><tt class="py-lineno">1213</tt> <a class="py-toggle" href="#" id="SelectElement._multiple__set-toggle" onclick="return toggle('SelectElement._multiple__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_multiple__set">_multiple__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="SelectElement._multiple__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._multiple__set-expanded"><a name="L1214"></a><tt class="py-lineno">1214</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-737" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-739', 'attrib', 'link-93');">attrib</a></tt> </tt>
+</div><a name="SelectElement._multiple__set"></a><div id="SelectElement._multiple__set-def"><a name="L1214"></a><tt class="py-lineno">1214</tt> <a class="py-toggle" href="#" id="SelectElement._multiple__set-toggle" onclick="return toggle('SelectElement._multiple__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.SelectElement-class.html#_multiple__set">_multiple__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="SelectElement._multiple__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="SelectElement._multiple__set-expanded"><a name="L1215"></a><tt class="py-lineno">1215</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-740" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-737', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1215"></a><tt class="py-lineno">1215</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-738" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-738', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'multiple'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
-<a name="L1216"></a><tt class="py-lineno">1216</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-string">'multiple'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-739" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-740', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1216"></a><tt class="py-lineno">1216</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-741" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-741', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'multiple'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
+<a name="L1217"></a><tt class="py-lineno">1217</tt> <tt class="py-line"> <tt class="py-keyword">elif</tt> <tt class="py-string">'multiple'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-742" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-739', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1217"></a><tt class="py-lineno">1217</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-740" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-742', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1218"></a><tt class="py-lineno">1218</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-743" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-740', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'multiple'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1218"></a><tt class="py-lineno">1218</tt> <tt class="py-line"> <tt id="link-741" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-741', 'multiple', 'link-519');">multiple</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-742" class="py-name" targets="Method lxml.html.SelectElement._multiple__get()=lxml.html.SelectElement-class.html#_multiple__get"><a title="lxml.html.SelectElement._multiple__get" class="py-name" href="#" onclick="return doclink('link-742', '_multiple__get', 'link-742');">_multiple__get</a></tt><tt class="py-op">,</tt> <tt id="link-743" class="py-name" targets="Method lxml.html.SelectElement._multiple__set()=lxml.html.SelectElement-class.html#_multiple__set"><a title="lxml.html.SelectElement._multiple__set" class="py-name" href="#" onclick="return doclink('link-743', '_multiple__set', 'link-743');">_multiple__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-744" class="py-name"><a title="lxml.html.SelectElement._multiple__get" class="py-name" href="#" onclick="return doclink('link-744', '_multiple__get', 'link-742');">_multiple__get</a></tt><tt class="py-op">.</tt><tt id="link-745" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-745', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1219"></a><tt class="py-lineno">1219</tt> <tt class="py-line"> </tt>
-<a name="L1220"></a><tt class="py-lineno">1220</tt> <tt class="py-line"><tt id="link-746" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-746', 'HtmlElementClassLookup', 'link-566');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-747" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-747', '_default_element_classes', 'link-263');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'select'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-748" class="py-name" targets="Class lxml.html.SelectElement=lxml.html.SelectElement-class.html"><a title="lxml.html.SelectElement" class="py-name" href="#" onclick="return doclink('link-748', 'SelectElement', 'link-748');">SelectElement</a></tt> </tt>
-<a name="L1221"></a><tt class="py-lineno">1221</tt> <tt class="py-line"> </tt>
-<a name="MultipleSelectOptions"></a><div id="MultipleSelectOptions-def"><a name="L1222"></a><tt class="py-lineno">1222</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions-toggle" onclick="return toggle('MultipleSelectOptions');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html">MultipleSelectOptions</a><tt class="py-op">(</tt><tt class="py-base-class">SetMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="MultipleSelectOptions-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="MultipleSelectOptions-expanded"><a name="L1223"></a><tt class="py-lineno">1223</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1224"></a><tt class="py-lineno">1224</tt> <tt class="py-line"><tt class="py-docstring"> Represents all the selected options in a ``<select multiple>`` element.</tt> </tt>
-<a name="L1225"></a><tt class="py-lineno">1225</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1226"></a><tt class="py-lineno">1226</tt> <tt class="py-line"><tt class="py-docstring"> You can add to this set-like option to select an option, or remove</tt> </tt>
-<a name="L1227"></a><tt class="py-lineno">1227</tt> <tt class="py-line"><tt class="py-docstring"> to unselect the option.</tt> </tt>
-<a name="L1228"></a><tt class="py-lineno">1228</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1229"></a><tt class="py-lineno">1229</tt> <tt class="py-line"> </tt>
-<a name="MultipleSelectOptions.__init__"></a><div id="MultipleSelectOptions.__init__-def"><a name="L1230"></a><tt class="py-lineno">1230</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.__init__-toggle" onclick="return toggle('MultipleSelectOptions.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">select</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="MultipleSelectOptions.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.__init__-expanded"><a name="L1231"></a><tt class="py-lineno">1231</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">select</tt> <tt class="py-op">=</tt> <tt class="py-name">select</tt> </tt>
-</div><a name="L1232"></a><tt class="py-lineno">1232</tt> <tt class="py-line"> </tt>
-<a name="MultipleSelectOptions.options"></a><div id="MultipleSelectOptions.options-def"><a name="L1233"></a><tt class="py-lineno">1233</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.options-toggle" onclick="return toggle('MultipleSelectOptions.options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#options">options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="MultipleSelectOptions.options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.options-expanded"><a name="L1234"></a><tt class="py-lineno">1234</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1235"></a><tt class="py-lineno">1235</tt> <tt class="py-line"><tt class="py-docstring"> Iterator of all the ``<option>`` elements.</tt> </tt>
-<a name="L1236"></a><tt class="py-lineno">1236</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1237"></a><tt class="py-lineno">1237</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-749" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-749', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt id="link-750" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-750', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">select</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1238"></a><tt class="py-lineno">1238</tt> <tt class="py-line"> <tt id="link-751" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-751', 'options', 'link-717');">options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-752" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-752', 'options', 'link-717');">options</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1239"></a><tt class="py-lineno">1239</tt> <tt class="py-line"> </tt>
-<a name="MultipleSelectOptions.__iter__"></a><div id="MultipleSelectOptions.__iter__-def"><a name="L1240"></a><tt class="py-lineno">1240</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.__iter__-toggle" onclick="return toggle('MultipleSelectOptions.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="MultipleSelectOptions.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.__iter__-expanded"><a name="L1241"></a><tt class="py-lineno">1241</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">option</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-753" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-753', 'options', 'link-717');">options</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1242"></a><tt class="py-lineno">1242</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'selected'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-754" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-743', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'multiple'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1219"></a><tt class="py-lineno">1219</tt> <tt class="py-line"> <tt id="link-744" class="py-name"><a title="lxml.html.SelectElement.multiple" class="py-name" href="#" onclick="return doclink('link-744', 'multiple', 'link-522');">multiple</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-745" class="py-name" targets="Method lxml.html.SelectElement._multiple__get()=lxml.html.SelectElement-class.html#_multiple__get"><a title="lxml.html.SelectElement._multiple__get" class="py-name" href="#" onclick="return doclink('link-745', '_multiple__get', 'link-745');">_multiple__get</a></tt><tt class="py-op">,</tt> <tt id="link-746" class="py-name" targets="Method lxml.html.SelectElement._multiple__set()=lxml.html.SelectElement-class.html#_multiple__set"><a title="lxml.html.SelectElement._multiple__set" class="py-name" href="#" onclick="return doclink('link-746', '_multiple__set', 'link-746');">_multiple__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-747" class="py-name"><a title="lxml.html.SelectElement._multiple__get" class="py-name" href="#" onclick="return doclink('link-747', '_multiple__get', 'link-745');">_multiple__get</a></tt><tt class="py-op">.</tt><tt id="link-748" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-748', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1220"></a><tt class="py-lineno">1220</tt> <tt class="py-line"> </tt>
+<a name="L1221"></a><tt class="py-lineno">1221</tt> <tt class="py-line"><tt id="link-749" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-749', 'HtmlElementClassLookup', 'link-569');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-750" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-750', '_default_element_classes', 'link-266');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'select'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-751" class="py-name" targets="Class lxml.html.SelectElement=lxml.html.SelectElement-class.html"><a title="lxml.html.SelectElement" class="py-name" href="#" onclick="return doclink('link-751', 'SelectElement', 'link-751');">SelectElement</a></tt> </tt>
+<a name="L1222"></a><tt class="py-lineno">1222</tt> <tt class="py-line"> </tt>
+<a name="MultipleSelectOptions"></a><div id="MultipleSelectOptions-def"><a name="L1223"></a><tt class="py-lineno">1223</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions-toggle" onclick="return toggle('MultipleSelectOptions');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html">MultipleSelectOptions</a><tt class="py-op">(</tt><tt class="py-base-class">SetMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="MultipleSelectOptions-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="MultipleSelectOptions-expanded"><a name="L1224"></a><tt class="py-lineno">1224</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1225"></a><tt class="py-lineno">1225</tt> <tt class="py-line"><tt class="py-docstring"> Represents all the selected options in a ``<select multiple>`` element.</tt> </tt>
+<a name="L1226"></a><tt class="py-lineno">1226</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1227"></a><tt class="py-lineno">1227</tt> <tt class="py-line"><tt class="py-docstring"> You can add to this set-like option to select an option, or remove</tt> </tt>
+<a name="L1228"></a><tt class="py-lineno">1228</tt> <tt class="py-line"><tt class="py-docstring"> to unselect the option.</tt> </tt>
+<a name="L1229"></a><tt class="py-lineno">1229</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1230"></a><tt class="py-lineno">1230</tt> <tt class="py-line"> </tt>
+<a name="MultipleSelectOptions.__init__"></a><div id="MultipleSelectOptions.__init__-def"><a name="L1231"></a><tt class="py-lineno">1231</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.__init__-toggle" onclick="return toggle('MultipleSelectOptions.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">select</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="MultipleSelectOptions.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.__init__-expanded"><a name="L1232"></a><tt class="py-lineno">1232</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">select</tt> <tt class="py-op">=</tt> <tt class="py-name">select</tt> </tt>
+</div><a name="L1233"></a><tt class="py-lineno">1233</tt> <tt class="py-line"> </tt>
+<a name="MultipleSelectOptions.options"></a><div id="MultipleSelectOptions.options-def"><a name="L1234"></a><tt class="py-lineno">1234</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.options-toggle" onclick="return toggle('MultipleSelectOptions.options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#options">options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="MultipleSelectOptions.options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.options-expanded"><a name="L1235"></a><tt class="py-lineno">1235</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1236"></a><tt class="py-lineno">1236</tt> <tt class="py-line"><tt class="py-docstring"> Iterator of all the ``<option>`` elements.</tt> </tt>
+<a name="L1237"></a><tt class="py-lineno">1237</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1238"></a><tt class="py-lineno">1238</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-752" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-752', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt id="link-753" class="py-name"><a title="lxml.html._options_xpath" class="py-name" href="#" onclick="return doclink('link-753', '_options_xpath', 'link-21');">_options_xpath</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">select</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1239"></a><tt class="py-lineno">1239</tt> <tt class="py-line"> <tt id="link-754" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-754', 'options', 'link-720');">options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-755" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-755', 'options', 'link-720');">options</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1240"></a><tt class="py-lineno">1240</tt> <tt class="py-line"> </tt>
+<a name="MultipleSelectOptions.__iter__"></a><div id="MultipleSelectOptions.__iter__-def"><a name="L1241"></a><tt class="py-lineno">1241</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.__iter__-toggle" onclick="return toggle('MultipleSelectOptions.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="MultipleSelectOptions.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.__iter__-expanded"><a name="L1242"></a><tt class="py-lineno">1242</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">option</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-756" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-756', 'options', 'link-720');">options</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1243"></a><tt class="py-lineno">1243</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'selected'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-757" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-754', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1243"></a><tt class="py-lineno">1243</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-755" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-757', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1244"></a><tt class="py-lineno">1244</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-758" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-755', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1244"></a><tt class="py-lineno">1244</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1245"></a><tt class="py-lineno">1245</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-756" class="py-name"><a title="lxml.etree.QName.text
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-758', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1245"></a><tt class="py-lineno">1245</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1246"></a><tt class="py-lineno">1246</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-759" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-756', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1246"></a><tt class="py-lineno">1246</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
-<a name="L1247"></a><tt class="py-lineno">1247</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-757" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-757', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1248"></a><tt class="py-lineno">1248</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-name">opt_value</tt> </tt>
-</div><a name="L1249"></a><tt class="py-lineno">1249</tt> <tt class="py-line"> </tt>
-<a name="MultipleSelectOptions.add"></a><div id="MultipleSelectOptions.add-def"><a name="L1250"></a><tt class="py-lineno">1250</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.add-toggle" onclick="return toggle('MultipleSelectOptions.add');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#add">add</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="MultipleSelectOptions.add-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.add-expanded"><a name="L1251"></a><tt class="py-lineno">1251</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">option</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-758" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-758', 'options', 'link-717');">options</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1252"></a><tt class="py-lineno">1252</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-759" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-759', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1247"></a><tt class="py-lineno">1247</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
+<a name="L1248"></a><tt class="py-lineno">1248</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-760" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-760', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1249"></a><tt class="py-lineno">1249</tt> <tt class="py-line"> <tt class="py-keyword">yield</tt> <tt class="py-name">opt_value</tt> </tt>
+</div><a name="L1250"></a><tt class="py-lineno">1250</tt> <tt class="py-line"> </tt>
+<a name="MultipleSelectOptions.add"></a><div id="MultipleSelectOptions.add-def"><a name="L1251"></a><tt class="py-lineno">1251</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.add-toggle" onclick="return toggle('MultipleSelectOptions.add');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#add">add</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="MultipleSelectOptions.add-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.add-expanded"><a name="L1252"></a><tt class="py-lineno">1252</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">option</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-761" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-761', 'options', 'link-720');">options</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1253"></a><tt class="py-lineno">1253</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-762" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-759', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1253"></a><tt class="py-lineno">1253</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1254"></a><tt class="py-lineno">1254</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-760" class="py-name"><a title="lxml.etree.QName.text
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-762', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1254"></a><tt class="py-lineno">1254</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1255"></a><tt class="py-lineno">1255</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-763" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-760', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1255"></a><tt class="py-lineno">1255</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
-<a name="L1256"></a><tt class="py-lineno">1256</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-761" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-761', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1257"></a><tt class="py-lineno">1257</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-op">==</tt> <tt class="py-name">item</tt><tt class="py-op">:</tt> </tt>
-<a name="L1258"></a><tt class="py-lineno">1258</tt> <tt class="py-line"> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-762" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-762', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'selected'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
-<a name="L1259"></a><tt class="py-lineno">1259</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
-<a name="L1260"></a><tt class="py-lineno">1260</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1261"></a><tt class="py-lineno">1261</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1262"></a><tt class="py-lineno">1262</tt> <tt class="py-line"> <tt class="py-string">"There is no option with the value %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">item</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1263"></a><tt class="py-lineno">1263</tt> <tt class="py-line"> </tt>
-<a name="MultipleSelectOptions.remove"></a><div id="MultipleSelectOptions.remove-def"><a name="L1264"></a><tt class="py-lineno">1264</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.remove-toggle" onclick="return toggle('MultipleSelectOptions.remove');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#remove">remove</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="MultipleSelectOptions.remove-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.remove-expanded"><a name="L1265"></a><tt class="py-lineno">1265</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">option</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-763" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
-lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-763', 'options', 'link-717');">options</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1266"></a><tt class="py-lineno">1266</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-764" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-763', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1256"></a><tt class="py-lineno">1256</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
+<a name="L1257"></a><tt class="py-lineno">1257</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-764" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-764', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1258"></a><tt class="py-lineno">1258</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-op">==</tt> <tt class="py-name">item</tt><tt class="py-op">:</tt> </tt>
+<a name="L1259"></a><tt class="py-lineno">1259</tt> <tt class="py-line"> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-765" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-765', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'selected'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
+<a name="L1260"></a><tt class="py-lineno">1260</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
+<a name="L1261"></a><tt class="py-lineno">1261</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1262"></a><tt class="py-lineno">1262</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1263"></a><tt class="py-lineno">1263</tt> <tt class="py-line"> <tt class="py-string">"There is no option with the value %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">item</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1264"></a><tt class="py-lineno">1264</tt> <tt class="py-line"> </tt>
+<a name="MultipleSelectOptions.remove"></a><div id="MultipleSelectOptions.remove-def"><a name="L1265"></a><tt class="py-lineno">1265</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.remove-toggle" onclick="return toggle('MultipleSelectOptions.remove');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#remove">remove</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">item</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="MultipleSelectOptions.remove-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.remove-expanded"><a name="L1266"></a><tt class="py-lineno">1266</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">option</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-766" class="py-name"><a title="lxml.etree.XSLTAccessControl.options
+lxml.html.MultipleSelectOptions.options" class="py-name" href="#" onclick="return doclink('link-766', 'options', 'link-720');">options</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1267"></a><tt class="py-lineno">1267</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-767" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-764', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1267"></a><tt class="py-lineno">1267</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1268"></a><tt class="py-lineno">1268</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-765" class="py-name"><a title="lxml.etree.QName.text
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-767', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1268"></a><tt class="py-lineno">1268</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-keyword">is</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1269"></a><tt class="py-lineno">1269</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-768" class="py-name"><a title="lxml.etree.QName.text
lxml.etree._Element.text
lxml.etree._Entity.text
lxml.objectify.ObjectifiedElement.text
-xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-765', 'text', 'link-102');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
-<a name="L1269"></a><tt class="py-lineno">1269</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
-<a name="L1270"></a><tt class="py-lineno">1270</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-766" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-766', 'strip', 'link-216');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1271"></a><tt class="py-lineno">1271</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-op">==</tt> <tt class="py-name">item</tt><tt class="py-op">:</tt> </tt>
-<a name="L1272"></a><tt class="py-lineno">1272</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'selected'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-767" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.text" class="py-name" href="#" onclick="return doclink('link-768', 'text', 'link-103');">text</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">''</tt> </tt>
+<a name="L1270"></a><tt class="py-lineno">1270</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt><tt class="py-op">:</tt> </tt>
+<a name="L1271"></a><tt class="py-lineno">1271</tt> <tt class="py-line"> <tt class="py-name">opt_value</tt> <tt class="py-op">=</tt> <tt class="py-name">opt_value</tt><tt class="py-op">.</tt><tt id="link-769" class="py-name"><a title="lxml.doctestcompare.strip" class="py-name" href="#" onclick="return doclink('link-769', 'strip', 'link-195');">strip</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1272"></a><tt class="py-lineno">1272</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">opt_value</tt> <tt class="py-op">==</tt> <tt class="py-name">item</tt><tt class="py-op">:</tt> </tt>
+<a name="L1273"></a><tt class="py-lineno">1273</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'selected'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-770" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-767', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1273"></a><tt class="py-lineno">1273</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-768" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-770', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1274"></a><tt class="py-lineno">1274</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">option</tt><tt class="py-op">.</tt><tt id="link-771" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-768', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'selected'</tt><tt class="py-op">]</tt> </tt>
-<a name="L1274"></a><tt class="py-lineno">1274</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1275"></a><tt class="py-lineno">1275</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1276"></a><tt class="py-lineno">1276</tt> <tt class="py-line"> <tt class="py-string">"The option %r is not currently selected"</tt> <tt class="py-op">%</tt> <tt class="py-name">item</tt><tt class="py-op">)</tt> </tt>
-<a name="L1277"></a><tt class="py-lineno">1277</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
-<a name="L1278"></a><tt class="py-lineno">1278</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1279"></a><tt class="py-lineno">1279</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1280"></a><tt class="py-lineno">1280</tt> <tt class="py-line"> <tt class="py-string">"There is not option with the value %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">item</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1281"></a><tt class="py-lineno">1281</tt> <tt class="py-line"> </tt>
-<a name="MultipleSelectOptions.__repr__"></a><div id="MultipleSelectOptions.__repr__-def"><a name="L1282"></a><tt class="py-lineno">1282</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.__repr__-toggle" onclick="return toggle('MultipleSelectOptions.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="MultipleSelectOptions.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.__repr__-expanded"><a name="L1283"></a><tt class="py-lineno">1283</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s {%s} for select name=%r>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
-<a name="L1284"></a><tt class="py-lineno">1284</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
-<a name="L1285"></a><tt class="py-lineno">1285</tt> <tt class="py-line"> <tt class="py-string">', '</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-name">repr</tt><tt class="py-op">(</tt><tt id="link-769" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-769', 'v', 'link-520');">v</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt id="link-770" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-770', 'v', 'link-520');">v</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> </tt>
-<a name="L1286"></a><tt class="py-lineno">1286</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">select</tt><tt class="py-op">.</tt><tt id="link-771" class="py-name"><a title="lxml.etree.DTD.name
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-771', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'selected'</tt><tt class="py-op">]</tt> </tt>
+<a name="L1275"></a><tt class="py-lineno">1275</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1276"></a><tt class="py-lineno">1276</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1277"></a><tt class="py-lineno">1277</tt> <tt class="py-line"> <tt class="py-string">"The option %r is not currently selected"</tt> <tt class="py-op">%</tt> <tt class="py-name">item</tt><tt class="py-op">)</tt> </tt>
+<a name="L1278"></a><tt class="py-lineno">1278</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
+<a name="L1279"></a><tt class="py-lineno">1279</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1280"></a><tt class="py-lineno">1280</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1281"></a><tt class="py-lineno">1281</tt> <tt class="py-line"> <tt class="py-string">"There is not option with the value %r"</tt> <tt class="py-op">%</tt> <tt class="py-name">item</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1282"></a><tt class="py-lineno">1282</tt> <tt class="py-line"> </tt>
+<a name="MultipleSelectOptions.__repr__"></a><div id="MultipleSelectOptions.__repr__-def"><a name="L1283"></a><tt class="py-lineno">1283</tt> <a class="py-toggle" href="#" id="MultipleSelectOptions.__repr__-toggle" onclick="return toggle('MultipleSelectOptions.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.MultipleSelectOptions-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="MultipleSelectOptions.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="MultipleSelectOptions.__repr__-expanded"><a name="L1284"></a><tt class="py-lineno">1284</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s {%s} for select name=%r>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
+<a name="L1285"></a><tt class="py-lineno">1285</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
+<a name="L1286"></a><tt class="py-lineno">1286</tt> <tt class="py-line"> <tt class="py-string">', '</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-name">repr</tt><tt class="py-op">(</tt><tt id="link-772" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-772', 'v', 'link-523');">v</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt id="link-773" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-773', 'v', 'link-523');">v</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> </tt>
+<a name="L1287"></a><tt class="py-lineno">1287</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">select</tt><tt class="py-op">.</tt><tt id="link-774" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-771', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1287"></a><tt class="py-lineno">1287</tt> <tt class="py-line"> </tt>
-<a name="RadioGroup"></a><div id="RadioGroup-def"><a name="L1288"></a><tt class="py-lineno">1288</tt> <a class="py-toggle" href="#" id="RadioGroup-toggle" onclick="return toggle('RadioGroup');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html">RadioGroup</a><tt class="py-op">(</tt><tt class="py-base-class">list</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="RadioGroup-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="RadioGroup-expanded"><a name="L1289"></a><tt class="py-lineno">1289</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1290"></a><tt class="py-lineno">1290</tt> <tt class="py-line"><tt class="py-docstring"> This object represents several ``<input type=radio>`` elements</tt> </tt>
-<a name="L1291"></a><tt class="py-lineno">1291</tt> <tt class="py-line"><tt class="py-docstring"> that have the same name.</tt> </tt>
-<a name="L1292"></a><tt class="py-lineno">1292</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1293"></a><tt class="py-lineno">1293</tt> <tt class="py-line"><tt class="py-docstring"> You can use this like a list, but also use the property</tt> </tt>
-<a name="L1294"></a><tt class="py-lineno">1294</tt> <tt class="py-line"><tt class="py-docstring"> ``.value`` to check/uncheck inputs. Also you can use</tt> </tt>
-<a name="L1295"></a><tt class="py-lineno">1295</tt> <tt class="py-line"><tt class="py-docstring"> ``.value_options`` to get the possible values.</tt> </tt>
-<a name="L1296"></a><tt class="py-lineno">1296</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1297"></a><tt class="py-lineno">1297</tt> <tt class="py-line"> </tt>
-<a name="RadioGroup._value__get"></a><div id="RadioGroup._value__get-def"><a name="L1298"></a><tt class="py-lineno">1298</tt> <a class="py-toggle" href="#" id="RadioGroup._value__get-toggle" onclick="return toggle('RadioGroup._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="RadioGroup._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup._value__get-expanded"><a name="L1299"></a><tt class="py-lineno">1299</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1300"></a><tt class="py-lineno">1300</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value, which checks the radio with that value (and</tt> </tt>
-<a name="L1301"></a><tt class="py-lineno">1301</tt> <tt class="py-line"><tt class="py-docstring"> unchecks any other value).</tt> </tt>
-<a name="L1302"></a><tt class="py-lineno">1302</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1303"></a><tt class="py-lineno">1303</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
-<a name="L1304"></a><tt class="py-lineno">1304</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-772" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-774', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1288"></a><tt class="py-lineno">1288</tt> <tt class="py-line"> </tt>
+<a name="RadioGroup"></a><div id="RadioGroup-def"><a name="L1289"></a><tt class="py-lineno">1289</tt> <a class="py-toggle" href="#" id="RadioGroup-toggle" onclick="return toggle('RadioGroup');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html">RadioGroup</a><tt class="py-op">(</tt><tt class="py-base-class">list</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="RadioGroup-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="RadioGroup-expanded"><a name="L1290"></a><tt class="py-lineno">1290</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1291"></a><tt class="py-lineno">1291</tt> <tt class="py-line"><tt class="py-docstring"> This object represents several ``<input type=radio>`` elements</tt> </tt>
+<a name="L1292"></a><tt class="py-lineno">1292</tt> <tt class="py-line"><tt class="py-docstring"> that have the same name.</tt> </tt>
+<a name="L1293"></a><tt class="py-lineno">1293</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1294"></a><tt class="py-lineno">1294</tt> <tt class="py-line"><tt class="py-docstring"> You can use this like a list, but also use the property</tt> </tt>
+<a name="L1295"></a><tt class="py-lineno">1295</tt> <tt class="py-line"><tt class="py-docstring"> ``.value`` to check/uncheck inputs. Also you can use</tt> </tt>
+<a name="L1296"></a><tt class="py-lineno">1296</tt> <tt class="py-line"><tt class="py-docstring"> ``.value_options`` to get the possible values.</tt> </tt>
+<a name="L1297"></a><tt class="py-lineno">1297</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1298"></a><tt class="py-lineno">1298</tt> <tt class="py-line"> </tt>
+<a name="RadioGroup._value__get"></a><div id="RadioGroup._value__get-def"><a name="L1299"></a><tt class="py-lineno">1299</tt> <a class="py-toggle" href="#" id="RadioGroup._value__get-toggle" onclick="return toggle('RadioGroup._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="RadioGroup._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup._value__get-expanded"><a name="L1300"></a><tt class="py-lineno">1300</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1301"></a><tt class="py-lineno">1301</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value, which checks the radio with that value (and</tt> </tt>
+<a name="L1302"></a><tt class="py-lineno">1302</tt> <tt class="py-line"><tt class="py-docstring"> unchecks any other value).</tt> </tt>
+<a name="L1303"></a><tt class="py-lineno">1303</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1304"></a><tt class="py-lineno">1304</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
+<a name="L1305"></a><tt class="py-lineno">1305</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-775" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-772', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1305"></a><tt class="py-lineno">1305</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-773" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-775', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1306"></a><tt class="py-lineno">1306</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-776" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-773', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1306"></a><tt class="py-lineno">1306</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-</div><a name="L1307"></a><tt class="py-lineno">1307</tt> <tt class="py-line"> </tt>
-<a name="RadioGroup._value__set"></a><div id="RadioGroup._value__set-def"><a name="L1308"></a><tt class="py-lineno">1308</tt> <a class="py-toggle" href="#" id="RadioGroup._value__set-toggle" onclick="return toggle('RadioGroup._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="RadioGroup._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup._value__set-expanded"><a name="L1309"></a><tt class="py-lineno">1309</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-774" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-776', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1307"></a><tt class="py-lineno">1307</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
+</div><a name="L1308"></a><tt class="py-lineno">1308</tt> <tt class="py-line"> </tt>
+<a name="RadioGroup._value__set"></a><div id="RadioGroup._value__set-def"><a name="L1309"></a><tt class="py-lineno">1309</tt> <a class="py-toggle" href="#" id="RadioGroup._value__set-toggle" onclick="return toggle('RadioGroup._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="RadioGroup._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup._value__set-expanded"><a name="L1310"></a><tt class="py-lineno">1310</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-777" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-774', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1310"></a><tt class="py-lineno">1310</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
-<a name="L1311"></a><tt class="py-lineno">1311</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-775" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-777', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1311"></a><tt class="py-lineno">1311</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
+<a name="L1312"></a><tt class="py-lineno">1312</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-778" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-775', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt id="link-776" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-778', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt id="link-779" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-776', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1312"></a><tt class="py-lineno">1312</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt> </tt>
-<a name="L1313"></a><tt class="py-lineno">1313</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
-<a name="L1314"></a><tt class="py-lineno">1314</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1315"></a><tt class="py-lineno">1315</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1316"></a><tt class="py-lineno">1316</tt> <tt class="py-line"> <tt class="py-string">"There is no radio input with the value %r"</tt> <tt class="py-op">%</tt> <tt id="link-777" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-779', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1313"></a><tt class="py-lineno">1313</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt> </tt>
+<a name="L1314"></a><tt class="py-lineno">1314</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
+<a name="L1315"></a><tt class="py-lineno">1315</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1316"></a><tt class="py-lineno">1316</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1317"></a><tt class="py-lineno">1317</tt> <tt class="py-line"> <tt class="py-string">"There is no radio input with the value %r"</tt> <tt class="py-op">%</tt> <tt id="link-780" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-777', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1317"></a><tt class="py-lineno">1317</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
-<a name="L1318"></a><tt class="py-lineno">1318</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-778" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-780', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1318"></a><tt class="py-lineno">1318</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">:</tt> </tt>
+<a name="L1319"></a><tt class="py-lineno">1319</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-781" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-778', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1319"></a><tt class="py-lineno">1319</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-779" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-781', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1320"></a><tt class="py-lineno">1320</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-782" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-779', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'checked'</tt><tt class="py-op">]</tt> </tt>
-<a name="L1320"></a><tt class="py-lineno">1320</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-780" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-782', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'checked'</tt><tt class="py-op">]</tt> </tt>
+<a name="L1321"></a><tt class="py-lineno">1321</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-783" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-780', 'value', 'link-172');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
-<a name="L1321"></a><tt class="py-lineno">1321</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt><tt class="py-op">.</tt><tt id="link-781" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-781', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'checked'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1322"></a><tt class="py-lineno">1322</tt> <tt class="py-line"> </tt>
-<a name="RadioGroup._value__del"></a><div id="RadioGroup._value__del-def"><a name="L1323"></a><tt class="py-lineno">1323</tt> <a class="py-toggle" href="#" id="RadioGroup._value__del-toggle" onclick="return toggle('RadioGroup._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="RadioGroup._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup._value__del-expanded"><a name="L1324"></a><tt class="py-lineno">1324</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-782" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-783', 'value', 'link-173');">value</a></tt> <tt class="py-keyword">is</tt> <tt class="py-keyword">not</tt> <tt class="py-name">None</tt><tt class="py-op">:</tt> </tt>
+<a name="L1322"></a><tt class="py-lineno">1322</tt> <tt class="py-line"> <tt class="py-name">checked_option</tt><tt class="py-op">.</tt><tt id="link-784" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-784', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'checked'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1323"></a><tt class="py-lineno">1323</tt> <tt class="py-line"> </tt>
+<a name="RadioGroup._value__del"></a><div id="RadioGroup._value__del-def"><a name="L1324"></a><tt class="py-lineno">1324</tt> <a class="py-toggle" href="#" id="RadioGroup._value__del-toggle" onclick="return toggle('RadioGroup._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="RadioGroup._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup._value__del-expanded"><a name="L1325"></a><tt class="py-lineno">1325</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-785" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-782', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
-</div><a name="L1325"></a><tt class="py-lineno">1325</tt> <tt class="py-line"> </tt>
-<a name="L1326"></a><tt class="py-lineno">1326</tt> <tt class="py-line"> <tt id="link-783" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-785', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">None</tt> </tt>
+</div><a name="L1326"></a><tt class="py-lineno">1326</tt> <tt class="py-line"> </tt>
+<a name="L1327"></a><tt class="py-lineno">1327</tt> <tt class="py-line"> <tt id="link-786" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-783', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-784" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-786', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-787" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-784', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-785" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-787', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-788" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
lxml.html.InputElement._value__set
lxml.html.RadioGroup._value__set
lxml.html.SelectElement._value__set
-lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-785', '_value__set', 'link-663');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-786" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
+lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-788', '_value__set', 'link-666');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-789" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
lxml.html.InputElement._value__del
lxml.html.RadioGroup._value__del
lxml.html.SelectElement._value__del
-lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-786', '_value__del', 'link-664');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-787" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-789', '_value__del', 'link-667');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-790" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-787', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-788" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-788', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1327"></a><tt class="py-lineno">1327</tt> <tt class="py-line"> </tt>
-<a name="RadioGroup.value_options"></a><div id="RadioGroup.value_options-def"><a name="L1328"></a><tt class="py-lineno">1328</tt> <a class="py-toggle" href="#" id="RadioGroup.value_options-toggle" onclick="return toggle('RadioGroup.value_options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#value_options">value_options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="RadioGroup.value_options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup.value_options-expanded"><a name="L1329"></a><tt class="py-lineno">1329</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1330"></a><tt class="py-lineno">1330</tt> <tt class="py-line"><tt class="py-docstring"> Returns a list of all the possible values.</tt> </tt>
-<a name="L1331"></a><tt class="py-lineno">1331</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1332"></a><tt class="py-lineno">1332</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-op">[</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-789" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-790', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-791" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-791', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1328"></a><tt class="py-lineno">1328</tt> <tt class="py-line"> </tt>
+<a name="RadioGroup.value_options"></a><div id="RadioGroup.value_options-def"><a name="L1329"></a><tt class="py-lineno">1329</tt> <a class="py-toggle" href="#" id="RadioGroup.value_options-toggle" onclick="return toggle('RadioGroup.value_options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#value_options">value_options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="RadioGroup.value_options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup.value_options-expanded"><a name="L1330"></a><tt class="py-lineno">1330</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1331"></a><tt class="py-lineno">1331</tt> <tt class="py-line"><tt class="py-docstring"> Returns a list of all the possible values.</tt> </tt>
+<a name="L1332"></a><tt class="py-lineno">1332</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1333"></a><tt class="py-lineno">1333</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-op">[</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-792" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-789', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1333"></a><tt class="py-lineno">1333</tt> <tt class="py-line"> <tt id="link-790" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-792', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1334"></a><tt class="py-lineno">1334</tt> <tt class="py-line"> <tt id="link-793" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-790', 'value_options', 'link-732');">value_options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-791" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-793', 'value_options', 'link-735');">value_options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-794" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-791', 'value_options', 'link-732');">value_options</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-792" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-794', 'value_options', 'link-735');">value_options</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-795" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-792', 'value_options', 'link-732');">value_options</a></tt><tt class="py-op">.</tt><tt id="link-793" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-793', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1334"></a><tt class="py-lineno">1334</tt> <tt class="py-line"> </tt>
-<a name="RadioGroup.__repr__"></a><div id="RadioGroup.__repr__-def"><a name="L1335"></a><tt class="py-lineno">1335</tt> <a class="py-toggle" href="#" id="RadioGroup.__repr__-toggle" onclick="return toggle('RadioGroup.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="RadioGroup.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup.__repr__-expanded"><a name="L1336"></a><tt class="py-lineno">1336</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'%s(%s)'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
-<a name="L1337"></a><tt class="py-lineno">1337</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
-<a name="L1338"></a><tt class="py-lineno">1338</tt> <tt class="py-line"> <tt class="py-name">list</tt><tt class="py-op">.</tt><tt id="link-794" class="py-name" targets="Method lxml.cssselect.CSSSelector.__repr__()=lxml.cssselect.CSSSelector-class.html#__repr__,Method lxml.etree.XPath.__repr__()=lxml.etree.XPath-class.html#__repr__,Method lxml.etree.XSLTAccessControl.__repr__()=lxml.etree.XSLTAccessControl-class.html#__repr__,Method lxml.etree._Attrib.__repr__()=lxml.etree._Attrib-class.html#__repr__,Method lxml.etree._BaseErrorLog.__repr__()=lxml.etree._BaseErrorLog-class.html#__repr__,Method lxml.etree._Comment.__repr__()=lxml.etree._Comment-class.html#__repr__,Method lxml.etree._Element.__repr__()=lxml.etree._Element-class.html#__repr__,Method lxml.etree._Entity.__repr__()=lxml.etree._Entity-class.html#__repr__,Method lxml.etree._IDDict.__repr__()=lxml.etree._IDDict-class.html#__repr__,Method lxml.etree._ListErrorLog.__repr__()=lxml.etree._ListErrorLog-class.html#__repr__,Method lxml.etree._LogEntry.__repr__()=lxml.etree._LogEntry-class.html#__repr__,Method lxml.etree._ProcessingInstruction.__repr__()=lxml.etree._ProcessingInstruction-class.html#__repr__,Method lxml.html.CheckboxGroup.__repr__()=lxml.html.CheckboxGroup-class.html#__repr__,Method lxml.html.CheckboxValues.__repr__()=lxml.html.CheckboxValues-class.html#__repr__,Method lxml.html.FieldsDict.__repr__()=lxml.html.FieldsDict-class.html#__repr__,Method lxml.html.InputGetter.__repr__()=lxml.html.InputGetter-class.html#__repr__,Method lxml.html.InputMixin.__repr__()=lxml.html.InputMixin-class.html#__repr__,Method lxml.html.MultipleSelectOptions.__repr__()=lxml.html.MultipleSelectOptions-class.html#__repr__,Method lxml.html.RadioGroup.__repr__()=lxml.html.RadioGroup-class.html#__repr__,Method lxml.html.diff.tag_token.__repr__()=lxml.html.diff.tag_token-class.html#__repr__,Method lxml.html.diff.token.__repr__()=lxml.html.diff.token-class.html#__repr__,Method lxml.objectify.BoolElement.__repr__()=lxml.objectify.BoolElement-class.html#__repr__,Method lxml.objectify.NoneElement.__repr__()=lxml.objectify.NoneElement-class.html#__repr__,Method lxml.objectify.NumberElement.__repr__()=lxml.objectify.NumberElement-class.html#__repr__,Method lxml.objectify.ObjectifiedDataElement.__repr__()=lxml.objectify.ObjectifiedDataElement-class.html#__repr__,Method lxml.objectify.PyType.__repr__()=lxml.objectify.PyType-class.html#__repr__,Method lxml.objectify.StringElement.__repr__()=lxml.objectify.StringElement-class.html#__repr__"><a title="lxml.cssselect.CSSSelector.__repr__
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-795', 'value_options', 'link-735');">value_options</a></tt><tt class="py-op">.</tt><tt id="link-796" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-796', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1335"></a><tt class="py-lineno">1335</tt> <tt class="py-line"> </tt>
+<a name="RadioGroup.__repr__"></a><div id="RadioGroup.__repr__-def"><a name="L1336"></a><tt class="py-lineno">1336</tt> <a class="py-toggle" href="#" id="RadioGroup.__repr__-toggle" onclick="return toggle('RadioGroup.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.RadioGroup-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="RadioGroup.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="RadioGroup.__repr__-expanded"><a name="L1337"></a><tt class="py-lineno">1337</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'%s(%s)'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
+<a name="L1338"></a><tt class="py-lineno">1338</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
+<a name="L1339"></a><tt class="py-lineno">1339</tt> <tt class="py-line"> <tt class="py-name">list</tt><tt class="py-op">.</tt><tt id="link-797" class="py-name" targets="Method lxml.cssselect.CSSSelector.__repr__()=lxml.cssselect.CSSSelector-class.html#__repr__,Method lxml.etree.XPath.__repr__()=lxml.etree.XPath-class.html#__repr__,Method lxml.etree.XSLTAccessControl.__repr__()=lxml.etree.XSLTAccessControl-class.html#__repr__,Method lxml.etree._Attrib.__repr__()=lxml.etree._Attrib-class.html#__repr__,Method lxml.etree._BaseErrorLog.__repr__()=lxml.etree._BaseErrorLog-class.html#__repr__,Method lxml.etree._Comment.__repr__()=lxml.etree._Comment-class.html#__repr__,Method lxml.etree._Element.__repr__()=lxml.etree._Element-class.html#__repr__,Method lxml.etree._Entity.__repr__()=lxml.etree._Entity-class.html#__repr__,Method lxml.etree._IDDict.__repr__()=lxml.etree._IDDict-class.html#__repr__,Method lxml.etree._ListErrorLog.__repr__()=lxml.etree._ListErrorLog-class.html#__repr__,Method lxml.etree._LogEntry.__repr__()=lxml.etree._LogEntry-class.html#__repr__,Method lxml.etree._ProcessingInstruction.__repr__()=lxml.etree._ProcessingInstruction-class.html#__repr__,Method lxml.html.CheckboxGroup.__repr__()=lxml.html.CheckboxGroup-class.html#__repr__,Method lxml.html.CheckboxValues.__repr__()=lxml.html.CheckboxValues-class.html#__repr__,Method lxml.html.FieldsDict.__repr__()=lxml.html.FieldsDict-class.html#__repr__,Method lxml.html.InputGetter.__repr__()=lxml.html.InputGetter-class.html#__repr__,Method lxml.html.InputMixin.__repr__()=lxml.html.InputMixin-class.html#__repr__,Method lxml.html.MultipleSelectOptions.__repr__()=lxml.html.MultipleSelectOptions-class.html#__repr__,Method lxml.html.RadioGroup.__repr__()=lxml.html.RadioGroup-class.html#__repr__,Method lxml.html.diff.tag_token.__repr__()=lxml.html.diff.tag_token-class.html#__repr__,Method lxml.html.diff.token.__repr__()=lxml.html.diff.token-class.html#__repr__,Method lxml.objectify.BoolElement.__repr__()=lxml.objectify.BoolElement-class.html#__repr__,Method lxml.objectify.NoneElement.__repr__()=lxml.objectify.NoneElement-class.html#__repr__,Method lxml.objectify.NumberElement.__repr__()=lxml.objectify.NumberElement-class.html#__repr__,Method lxml.objectify.ObjectifiedDataElement.__repr__()=lxml.objectify.ObjectifiedDataElement-class.html#__repr__,Method lxml.objectify.PyType.__repr__()=lxml.objectify.PyType-class.html#__repr__,Method lxml.objectify.StringElement.__repr__()=lxml.objectify.StringElement-class.html#__repr__"><a title="lxml.cssselect.CSSSelector.__repr__
lxml.etree.XPath.__repr__
lxml.etree.XSLTAccessControl.__repr__
lxml.etree._Attrib.__repr__
lxml.objectify.NumberElement.__repr__
lxml.objectify.ObjectifiedDataElement.__repr__
lxml.objectify.PyType.__repr__
-lxml.objectify.StringElement.__repr__" class="py-name" href="#" onclick="return doclink('link-794', '__repr__', 'link-794');">__repr__</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1339"></a><tt class="py-lineno">1339</tt> <tt class="py-line"> </tt>
-<a name="CheckboxGroup"></a><div id="CheckboxGroup-def"><a name="L1340"></a><tt class="py-lineno">1340</tt> <a class="py-toggle" href="#" id="CheckboxGroup-toggle" onclick="return toggle('CheckboxGroup');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html">CheckboxGroup</a><tt class="py-op">(</tt><tt class="py-base-class">list</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxGroup-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="CheckboxGroup-expanded"><a name="L1341"></a><tt class="py-lineno">1341</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1342"></a><tt class="py-lineno">1342</tt> <tt class="py-line"><tt class="py-docstring"> Represents a group of checkboxes (``<input type=checkbox>``) that</tt> </tt>
-<a name="L1343"></a><tt class="py-lineno">1343</tt> <tt class="py-line"><tt class="py-docstring"> have the same name.</tt> </tt>
-<a name="L1344"></a><tt class="py-lineno">1344</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1345"></a><tt class="py-lineno">1345</tt> <tt class="py-line"><tt class="py-docstring"> In addition to using this like a list, the ``.value`` attribute</tt> </tt>
-<a name="L1346"></a><tt class="py-lineno">1346</tt> <tt class="py-line"><tt class="py-docstring"> returns a set-like object that you can add to or remove from to</tt> </tt>
-<a name="L1347"></a><tt class="py-lineno">1347</tt> <tt class="py-line"><tt class="py-docstring"> check and uncheck checkboxes. You can also use ``.value_options``</tt> </tt>
-<a name="L1348"></a><tt class="py-lineno">1348</tt> <tt class="py-line"><tt class="py-docstring"> to get the possible values.</tt> </tt>
-<a name="L1349"></a><tt class="py-lineno">1349</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1350"></a><tt class="py-lineno">1350</tt> <tt class="py-line"> </tt>
-<a name="CheckboxGroup._value__get"></a><div id="CheckboxGroup._value__get-def"><a name="L1351"></a><tt class="py-lineno">1351</tt> <a class="py-toggle" href="#" id="CheckboxGroup._value__get-toggle" onclick="return toggle('CheckboxGroup._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxGroup._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup._value__get-expanded"><a name="L1352"></a><tt class="py-lineno">1352</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1353"></a><tt class="py-lineno">1353</tt> <tt class="py-line"><tt class="py-docstring"> Return a set-like object that can be modified to check or</tt> </tt>
-<a name="L1354"></a><tt class="py-lineno">1354</tt> <tt class="py-line"><tt class="py-docstring"> uncheck individual checkboxes according to their value.</tt> </tt>
-<a name="L1355"></a><tt class="py-lineno">1355</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1356"></a><tt class="py-lineno">1356</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-795" class="py-name" targets="Class lxml.html.CheckboxValues=lxml.html.CheckboxValues-class.html"><a title="lxml.html.CheckboxValues" class="py-name" href="#" onclick="return doclink('link-795', 'CheckboxValues', 'link-795');">CheckboxValues</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
-</div><a name="CheckboxGroup._value__set"></a><div id="CheckboxGroup._value__set-def"><a name="L1357"></a><tt class="py-lineno">1357</tt> <a class="py-toggle" href="#" id="CheckboxGroup._value__set-toggle" onclick="return toggle('CheckboxGroup._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxGroup._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup._value__set-expanded"><a name="L1358"></a><tt class="py-lineno">1358</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-796" class="py-name"><a title="lxml.html.CheckboxGroup.value
-lxml.html.InputElement.value
-lxml.html.RadioGroup.value
-lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-796', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-797" class="py-name"><a title="lxml.etree._Attrib.clear
+lxml.objectify.StringElement.__repr__" class="py-name" href="#" onclick="return doclink('link-797', '__repr__', 'link-797');">__repr__</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1340"></a><tt class="py-lineno">1340</tt> <tt class="py-line"> </tt>
+<a name="CheckboxGroup"></a><div id="CheckboxGroup-def"><a name="L1341"></a><tt class="py-lineno">1341</tt> <a class="py-toggle" href="#" id="CheckboxGroup-toggle" onclick="return toggle('CheckboxGroup');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html">CheckboxGroup</a><tt class="py-op">(</tt><tt class="py-base-class">list</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxGroup-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="CheckboxGroup-expanded"><a name="L1342"></a><tt class="py-lineno">1342</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1343"></a><tt class="py-lineno">1343</tt> <tt class="py-line"><tt class="py-docstring"> Represents a group of checkboxes (``<input type=checkbox>``) that</tt> </tt>
+<a name="L1344"></a><tt class="py-lineno">1344</tt> <tt class="py-line"><tt class="py-docstring"> have the same name.</tt> </tt>
+<a name="L1345"></a><tt class="py-lineno">1345</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1346"></a><tt class="py-lineno">1346</tt> <tt class="py-line"><tt class="py-docstring"> In addition to using this like a list, the ``.value`` attribute</tt> </tt>
+<a name="L1347"></a><tt class="py-lineno">1347</tt> <tt class="py-line"><tt class="py-docstring"> returns a set-like object that you can add to or remove from to</tt> </tt>
+<a name="L1348"></a><tt class="py-lineno">1348</tt> <tt class="py-line"><tt class="py-docstring"> check and uncheck checkboxes. You can also use ``.value_options``</tt> </tt>
+<a name="L1349"></a><tt class="py-lineno">1349</tt> <tt class="py-line"><tt class="py-docstring"> to get the possible values.</tt> </tt>
+<a name="L1350"></a><tt class="py-lineno">1350</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1351"></a><tt class="py-lineno">1351</tt> <tt class="py-line"> </tt>
+<a name="CheckboxGroup._value__get"></a><div id="CheckboxGroup._value__get-def"><a name="L1352"></a><tt class="py-lineno">1352</tt> <a class="py-toggle" href="#" id="CheckboxGroup._value__get-toggle" onclick="return toggle('CheckboxGroup._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxGroup._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup._value__get-expanded"><a name="L1353"></a><tt class="py-lineno">1353</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1354"></a><tt class="py-lineno">1354</tt> <tt class="py-line"><tt class="py-docstring"> Return a set-like object that can be modified to check or</tt> </tt>
+<a name="L1355"></a><tt class="py-lineno">1355</tt> <tt class="py-line"><tt class="py-docstring"> uncheck individual checkboxes according to their value.</tt> </tt>
+<a name="L1356"></a><tt class="py-lineno">1356</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1357"></a><tt class="py-lineno">1357</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-798" class="py-name" targets="Class lxml.html.CheckboxValues=lxml.html.CheckboxValues-class.html"><a title="lxml.html.CheckboxValues" class="py-name" href="#" onclick="return doclink('link-798', 'CheckboxValues', 'link-798');">CheckboxValues</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt> </tt>
+</div><a name="CheckboxGroup._value__set"></a><div id="CheckboxGroup._value__set-def"><a name="L1358"></a><tt class="py-lineno">1358</tt> <a class="py-toggle" href="#" id="CheckboxGroup._value__set-toggle" onclick="return toggle('CheckboxGroup._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxGroup._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup._value__set-expanded"><a name="L1359"></a><tt class="py-lineno">1359</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-799" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputElement.value
+lxml.html.RadioGroup.value
+lxml.html.SelectElement.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-799', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-800" class="py-name"><a title="lxml.etree._Attrib.clear
lxml.etree._Element.clear
-lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-797', 'clear', 'link-688');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1359"></a><tt class="py-lineno">1359</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-798" class="py-name"><a title="lxml.objectify.ObjectPath.hasattr" class="py-name" href="#" onclick="return doclink('link-798', 'hasattr', 'link-571');">hasattr</a></tt><tt class="py-op">(</tt><tt id="link-799" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-800', 'clear', 'link-691');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1360"></a><tt class="py-lineno">1360</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-801" class="py-name"><a title="lxml.objectify.ObjectPath.hasattr" class="py-name" href="#" onclick="return doclink('link-801', 'hasattr', 'link-574');">hasattr</a></tt><tt class="py-op">(</tt><tt id="link-802" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-799', 'value', 'link-172');">value</a></tt><tt class="py-op">,</tt> <tt class="py-string">'__iter__'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1360"></a><tt class="py-lineno">1360</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1361"></a><tt class="py-lineno">1361</tt> <tt class="py-line"> <tt class="py-string">"A CheckboxGroup (name=%r) must be set to a sequence (not %r)"</tt> </tt>
-<a name="L1362"></a><tt class="py-lineno">1362</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-800" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-802', 'value', 'link-173');">value</a></tt><tt class="py-op">,</tt> <tt class="py-string">'__iter__'</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1361"></a><tt class="py-lineno">1361</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">ValueError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1362"></a><tt class="py-lineno">1362</tt> <tt class="py-line"> <tt class="py-string">"A CheckboxGroup (name=%r) must be set to a sequence (not %r)"</tt> </tt>
+<a name="L1363"></a><tt class="py-lineno">1363</tt> <tt class="py-line"> <tt class="py-op">%</tt> <tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt><tt class="py-op">.</tt><tt id="link-803" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-800', 'name', 'link-230');">name</a></tt><tt class="py-op">,</tt> <tt id="link-801" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-803', 'name', 'link-233');">name</a></tt><tt class="py-op">,</tt> <tt id="link-804" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-801', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-<a name="L1363"></a><tt class="py-lineno">1363</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-802" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-804', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+<a name="L1364"></a><tt class="py-lineno">1364</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-805" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-802', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-803" class="py-name"><a title="lxml.etree._Attrib.update" class="py-name" href="#" onclick="return doclink('link-803', 'update', 'link-690');">update</a></tt><tt class="py-op">(</tt><tt id="link-804" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-805', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-806" class="py-name"><a title="lxml.etree._Attrib.update" class="py-name" href="#" onclick="return doclink('link-806', 'update', 'link-693');">update</a></tt><tt class="py-op">(</tt><tt id="link-807" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-804', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="CheckboxGroup._value__del"></a><div id="CheckboxGroup._value__del-def"><a name="L1364"></a><tt class="py-lineno">1364</tt> <a class="py-toggle" href="#" id="CheckboxGroup._value__del-toggle" onclick="return toggle('CheckboxGroup._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxGroup._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup._value__del-expanded"><a name="L1365"></a><tt class="py-lineno">1365</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-805" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-807', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="CheckboxGroup._value__del"></a><div id="CheckboxGroup._value__del-def"><a name="L1365"></a><tt class="py-lineno">1365</tt> <a class="py-toggle" href="#" id="CheckboxGroup._value__del-toggle" onclick="return toggle('CheckboxGroup._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxGroup._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup._value__del-expanded"><a name="L1366"></a><tt class="py-lineno">1366</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-808" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-805', 'value', 'link-172');">value</a></tt><tt class="py-op">.</tt><tt id="link-806" class="py-name"><a title="lxml.etree._Attrib.clear
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-808', 'value', 'link-173');">value</a></tt><tt class="py-op">.</tt><tt id="link-809" class="py-name"><a title="lxml.etree._Attrib.clear
lxml.etree._Element.clear
-lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-806', 'clear', 'link-688');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1366"></a><tt class="py-lineno">1366</tt> <tt class="py-line"> <tt id="link-807" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ErrorLog.clear" class="py-name" href="#" onclick="return doclink('link-809', 'clear', 'link-691');">clear</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1367"></a><tt class="py-lineno">1367</tt> <tt class="py-line"> <tt id="link-810" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-807', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-808" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-810', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-811" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-808', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-809" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-811', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-812" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
lxml.html.InputElement._value__set
lxml.html.RadioGroup._value__set
lxml.html.SelectElement._value__set
-lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-809', '_value__set', 'link-663');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-810" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
+lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-812', '_value__set', 'link-666');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-813" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
lxml.html.InputElement._value__del
lxml.html.RadioGroup._value__del
lxml.html.SelectElement._value__del
-lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-810', '_value__del', 'link-664');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-811" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-813', '_value__del', 'link-667');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-814" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-811', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-812" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-812', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1367"></a><tt class="py-lineno">1367</tt> <tt class="py-line"> </tt>
-<a name="CheckboxGroup.value_options"></a><div id="CheckboxGroup.value_options-def"><a name="L1368"></a><tt class="py-lineno">1368</tt> <a class="py-toggle" href="#" id="CheckboxGroup.value_options-toggle" onclick="return toggle('CheckboxGroup.value_options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#value_options">value_options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxGroup.value_options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup.value_options-expanded"><a name="L1369"></a><tt class="py-lineno">1369</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1370"></a><tt class="py-lineno">1370</tt> <tt class="py-line"><tt class="py-docstring"> Returns a list of all the possible values.</tt> </tt>
-<a name="L1371"></a><tt class="py-lineno">1371</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1372"></a><tt class="py-lineno">1372</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-op">[</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-813" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-814', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-815" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-815', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1368"></a><tt class="py-lineno">1368</tt> <tt class="py-line"> </tt>
+<a name="CheckboxGroup.value_options"></a><div id="CheckboxGroup.value_options-def"><a name="L1369"></a><tt class="py-lineno">1369</tt> <a class="py-toggle" href="#" id="CheckboxGroup.value_options-toggle" onclick="return toggle('CheckboxGroup.value_options');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#value_options">value_options</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxGroup.value_options-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup.value_options-expanded"><a name="L1370"></a><tt class="py-lineno">1370</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1371"></a><tt class="py-lineno">1371</tt> <tt class="py-line"><tt class="py-docstring"> Returns a list of all the possible values.</tt> </tt>
+<a name="L1372"></a><tt class="py-lineno">1372</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1373"></a><tt class="py-lineno">1373</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-op">[</tt><tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-816" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-813', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1373"></a><tt class="py-lineno">1373</tt> <tt class="py-line"> <tt id="link-814" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-816', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1374"></a><tt class="py-lineno">1374</tt> <tt class="py-line"> <tt id="link-817" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-814', 'value_options', 'link-732');">value_options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-815" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-817', 'value_options', 'link-735');">value_options</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-818" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-815', 'value_options', 'link-732');">value_options</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-816" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-818', 'value_options', 'link-735');">value_options</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-819" class="py-name"><a title="lxml.html.CheckboxGroup.value_options
lxml.html.RadioGroup.value_options
-lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-816', 'value_options', 'link-732');">value_options</a></tt><tt class="py-op">.</tt><tt id="link-817" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-817', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1374"></a><tt class="py-lineno">1374</tt> <tt class="py-line"> </tt>
-<a name="CheckboxGroup.__repr__"></a><div id="CheckboxGroup.__repr__-def"><a name="L1375"></a><tt class="py-lineno">1375</tt> <a class="py-toggle" href="#" id="CheckboxGroup.__repr__-toggle" onclick="return toggle('CheckboxGroup.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxGroup.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup.__repr__-expanded"><a name="L1376"></a><tt class="py-lineno">1376</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'%s(%s)'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
-<a name="L1377"></a><tt class="py-lineno">1377</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> <tt class="py-name">list</tt><tt class="py-op">.</tt><tt id="link-818" class="py-name"><a title="lxml.cssselect.CSSSelector.__repr__
+lxml.html.SelectElement.value_options" class="py-name" href="#" onclick="return doclink('link-819', 'value_options', 'link-735');">value_options</a></tt><tt class="py-op">.</tt><tt id="link-820" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-820', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1375"></a><tt class="py-lineno">1375</tt> <tt class="py-line"> </tt>
+<a name="CheckboxGroup.__repr__"></a><div id="CheckboxGroup.__repr__-def"><a name="L1376"></a><tt class="py-lineno">1376</tt> <a class="py-toggle" href="#" id="CheckboxGroup.__repr__-toggle" onclick="return toggle('CheckboxGroup.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxGroup-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxGroup.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxGroup.__repr__-expanded"><a name="L1377"></a><tt class="py-lineno">1377</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'%s(%s)'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
+<a name="L1378"></a><tt class="py-lineno">1378</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> <tt class="py-name">list</tt><tt class="py-op">.</tt><tt id="link-821" class="py-name"><a title="lxml.cssselect.CSSSelector.__repr__
lxml.etree.XPath.__repr__
lxml.etree.XSLTAccessControl.__repr__
lxml.etree._Attrib.__repr__
lxml.objectify.NumberElement.__repr__
lxml.objectify.ObjectifiedDataElement.__repr__
lxml.objectify.PyType.__repr__
-lxml.objectify.StringElement.__repr__" class="py-name" href="#" onclick="return doclink('link-818', '__repr__', 'link-794');">__repr__</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1378"></a><tt class="py-lineno">1378</tt> <tt class="py-line"> </tt>
-<a name="CheckboxValues"></a><div id="CheckboxValues-def"><a name="L1379"></a><tt class="py-lineno">1379</tt> <a class="py-toggle" href="#" id="CheckboxValues-toggle" onclick="return toggle('CheckboxValues');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html">CheckboxValues</a><tt class="py-op">(</tt><tt class="py-base-class">SetMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxValues-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="CheckboxValues-expanded"><a name="L1380"></a><tt class="py-lineno">1380</tt> <tt class="py-line"> </tt>
-<a name="L1381"></a><tt class="py-lineno">1381</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1382"></a><tt class="py-lineno">1382</tt> <tt class="py-line"><tt class="py-docstring"> Represents the values of the checked checkboxes in a group of</tt> </tt>
-<a name="L1383"></a><tt class="py-lineno">1383</tt> <tt class="py-line"><tt class="py-docstring"> checkboxes with the same name.</tt> </tt>
-<a name="L1384"></a><tt class="py-lineno">1384</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1385"></a><tt class="py-lineno">1385</tt> <tt class="py-line"> </tt>
-<a name="CheckboxValues.__init__"></a><div id="CheckboxValues.__init__-def"><a name="L1386"></a><tt class="py-lineno">1386</tt> <a class="py-toggle" href="#" id="CheckboxValues.__init__-toggle" onclick="return toggle('CheckboxValues.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">group</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxValues.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.__init__-expanded"><a name="L1387"></a><tt class="py-lineno">1387</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt> <tt class="py-op">=</tt> <tt class="py-name">group</tt> </tt>
-</div><a name="L1388"></a><tt class="py-lineno">1388</tt> <tt class="py-line"> </tt>
-<a name="CheckboxValues.__iter__"></a><div id="CheckboxValues.__iter__-def"><a name="L1389"></a><tt class="py-lineno">1389</tt> <a class="py-toggle" href="#" id="CheckboxValues.__iter__-toggle" onclick="return toggle('CheckboxValues.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxValues.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.__iter__-expanded"><a name="L1390"></a><tt class="py-lineno">1390</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-819" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-819', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt class="py-op">[</tt> </tt>
-<a name="L1391"></a><tt class="py-lineno">1391</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-820" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.objectify.StringElement.__repr__" class="py-name" href="#" onclick="return doclink('link-821', '__repr__', 'link-797');">__repr__</a></tt><tt class="py-op">(</tt><tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1379"></a><tt class="py-lineno">1379</tt> <tt class="py-line"> </tt>
+<a name="CheckboxValues"></a><div id="CheckboxValues-def"><a name="L1380"></a><tt class="py-lineno">1380</tt> <a class="py-toggle" href="#" id="CheckboxValues-toggle" onclick="return toggle('CheckboxValues');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html">CheckboxValues</a><tt class="py-op">(</tt><tt class="py-base-class">SetMixin</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxValues-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="CheckboxValues-expanded"><a name="L1381"></a><tt class="py-lineno">1381</tt> <tt class="py-line"> </tt>
+<a name="L1382"></a><tt class="py-lineno">1382</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1383"></a><tt class="py-lineno">1383</tt> <tt class="py-line"><tt class="py-docstring"> Represents the values of the checked checkboxes in a group of</tt> </tt>
+<a name="L1384"></a><tt class="py-lineno">1384</tt> <tt class="py-line"><tt class="py-docstring"> checkboxes with the same name.</tt> </tt>
+<a name="L1385"></a><tt class="py-lineno">1385</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1386"></a><tt class="py-lineno">1386</tt> <tt class="py-line"> </tt>
+<a name="CheckboxValues.__init__"></a><div id="CheckboxValues.__init__-def"><a name="L1387"></a><tt class="py-lineno">1387</tt> <a class="py-toggle" href="#" id="CheckboxValues.__init__-toggle" onclick="return toggle('CheckboxValues.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">group</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxValues.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.__init__-expanded"><a name="L1388"></a><tt class="py-lineno">1388</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt> <tt class="py-op">=</tt> <tt class="py-name">group</tt> </tt>
+</div><a name="L1389"></a><tt class="py-lineno">1389</tt> <tt class="py-line"> </tt>
+<a name="CheckboxValues.__iter__"></a><div id="CheckboxValues.__iter__-def"><a name="L1390"></a><tt class="py-lineno">1390</tt> <a class="py-toggle" href="#" id="CheckboxValues.__iter__-toggle" onclick="return toggle('CheckboxValues.__iter__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#__iter__">__iter__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxValues.__iter__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.__iter__-expanded"><a name="L1391"></a><tt class="py-lineno">1391</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-822" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-822', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt class="py-op">[</tt> </tt>
+<a name="L1392"></a><tt class="py-lineno">1392</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-823" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-820', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1392"></a><tt class="py-lineno">1392</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt> </tt>
-<a name="L1393"></a><tt class="py-lineno">1393</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-821" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-823', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1393"></a><tt class="py-lineno">1393</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt> </tt>
+<a name="L1394"></a><tt class="py-lineno">1394</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-824" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-821', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1394"></a><tt class="py-lineno">1394</tt> <tt class="py-line"> </tt>
-<a name="CheckboxValues.add"></a><div id="CheckboxValues.add-def"><a name="L1395"></a><tt class="py-lineno">1395</tt> <a class="py-toggle" href="#" id="CheckboxValues.add-toggle" onclick="return toggle('CheckboxValues.add');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#add">add</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxValues.add-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.add-expanded"><a name="L1396"></a><tt class="py-lineno">1396</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">:</tt> </tt>
-<a name="L1397"></a><tt class="py-lineno">1397</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-822" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-824', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">]</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1395"></a><tt class="py-lineno">1395</tt> <tt class="py-line"> </tt>
+<a name="CheckboxValues.add"></a><div id="CheckboxValues.add-def"><a name="L1396"></a><tt class="py-lineno">1396</tt> <a class="py-toggle" href="#" id="CheckboxValues.add-toggle" onclick="return toggle('CheckboxValues.add');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#add">add</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxValues.add-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.add-expanded"><a name="L1397"></a><tt class="py-lineno">1397</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">:</tt> </tt>
+<a name="L1398"></a><tt class="py-lineno">1398</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-825" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-822', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt id="link-823" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-825', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt id="link-826" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-823', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1398"></a><tt class="py-lineno">1398</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-824" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-824', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'checked'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
-<a name="L1399"></a><tt class="py-lineno">1399</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
-<a name="L1400"></a><tt class="py-lineno">1400</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1401"></a><tt class="py-lineno">1401</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt><tt class="py-string">"No checkbox with value %r"</tt> <tt class="py-op">%</tt> <tt id="link-825" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-826', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1399"></a><tt class="py-lineno">1399</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-827" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-827', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'checked'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
+<a name="L1400"></a><tt class="py-lineno">1400</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
+<a name="L1401"></a><tt class="py-lineno">1401</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1402"></a><tt class="py-lineno">1402</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt><tt class="py-string">"No checkbox with value %r"</tt> <tt class="py-op">%</tt> <tt id="link-828" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-825', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1402"></a><tt class="py-lineno">1402</tt> <tt class="py-line"> </tt>
-<a name="CheckboxValues.remove"></a><div id="CheckboxValues.remove-def"><a name="L1403"></a><tt class="py-lineno">1403</tt> <a class="py-toggle" href="#" id="CheckboxValues.remove-toggle" onclick="return toggle('CheckboxValues.remove');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#remove">remove</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxValues.remove-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.remove-expanded"><a name="L1404"></a><tt class="py-lineno">1404</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">:</tt> </tt>
-<a name="L1405"></a><tt class="py-lineno">1405</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-826" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-828', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1403"></a><tt class="py-lineno">1403</tt> <tt class="py-line"> </tt>
+<a name="CheckboxValues.remove"></a><div id="CheckboxValues.remove-def"><a name="L1404"></a><tt class="py-lineno">1404</tt> <a class="py-toggle" href="#" id="CheckboxValues.remove-toggle" onclick="return toggle('CheckboxValues.remove');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#remove">remove</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxValues.remove-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.remove-expanded"><a name="L1405"></a><tt class="py-lineno">1405</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">:</tt> </tt>
+<a name="L1406"></a><tt class="py-lineno">1406</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-829" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-826', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt id="link-827" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-829', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-op">==</tt> <tt id="link-830" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-827', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1406"></a><tt class="py-lineno">1406</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-828" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-830', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1407"></a><tt class="py-lineno">1407</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-831" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-828', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1407"></a><tt class="py-lineno">1407</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-829" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-831', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1408"></a><tt class="py-lineno">1408</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-832" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-829', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'checked'</tt><tt class="py-op">]</tt> </tt>
-<a name="L1408"></a><tt class="py-lineno">1408</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1409"></a><tt class="py-lineno">1409</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1410"></a><tt class="py-lineno">1410</tt> <tt class="py-line"> <tt class="py-string">"The checkbox with value %r was already unchecked"</tt> <tt class="py-op">%</tt> <tt id="link-830" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-832', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'checked'</tt><tt class="py-op">]</tt> </tt>
+<a name="L1409"></a><tt class="py-lineno">1409</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1410"></a><tt class="py-lineno">1410</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1411"></a><tt class="py-lineno">1411</tt> <tt class="py-line"> <tt class="py-string">"The checkbox with value %r was already unchecked"</tt> <tt class="py-op">%</tt> <tt id="link-833" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-830', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1411"></a><tt class="py-lineno">1411</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
-<a name="L1412"></a><tt class="py-lineno">1412</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1413"></a><tt class="py-lineno">1413</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1414"></a><tt class="py-lineno">1414</tt> <tt class="py-line"> <tt class="py-string">"No checkbox with value %r"</tt> <tt class="py-op">%</tt> <tt id="link-831" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-833', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1412"></a><tt class="py-lineno">1412</tt> <tt class="py-line"> <tt class="py-keyword">break</tt> </tt>
+<a name="L1413"></a><tt class="py-lineno">1413</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1414"></a><tt class="py-lineno">1414</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">KeyError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1415"></a><tt class="py-lineno">1415</tt> <tt class="py-line"> <tt class="py-string">"No checkbox with value %r"</tt> <tt class="py-op">%</tt> <tt id="link-834" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-831', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1415"></a><tt class="py-lineno">1415</tt> <tt class="py-line"> </tt>
-<a name="CheckboxValues.__repr__"></a><div id="CheckboxValues.__repr__-def"><a name="L1416"></a><tt class="py-lineno">1416</tt> <a class="py-toggle" href="#" id="CheckboxValues.__repr__-toggle" onclick="return toggle('CheckboxValues.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="CheckboxValues.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.__repr__-expanded"><a name="L1417"></a><tt class="py-lineno">1417</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s {%s} for checkboxes name=%r>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
-<a name="L1418"></a><tt class="py-lineno">1418</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
-<a name="L1419"></a><tt class="py-lineno">1419</tt> <tt class="py-line"> <tt class="py-string">', '</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-name">repr</tt><tt class="py-op">(</tt><tt id="link-832" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-832', 'v', 'link-520');">v</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt id="link-833" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-833', 'v', 'link-520');">v</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> </tt>
-<a name="L1420"></a><tt class="py-lineno">1420</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">.</tt><tt id="link-834" class="py-name"><a title="lxml.etree.DTD.name
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-834', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1416"></a><tt class="py-lineno">1416</tt> <tt class="py-line"> </tt>
+<a name="CheckboxValues.__repr__"></a><div id="CheckboxValues.__repr__-def"><a name="L1417"></a><tt class="py-lineno">1417</tt> <a class="py-toggle" href="#" id="CheckboxValues.__repr__-toggle" onclick="return toggle('CheckboxValues.__repr__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.CheckboxValues-class.html#__repr__">__repr__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="CheckboxValues.__repr__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="CheckboxValues.__repr__-expanded"><a name="L1418"></a><tt class="py-lineno">1418</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'<%s {%s} for checkboxes name=%r>'</tt> <tt class="py-op">%</tt> <tt class="py-op">(</tt> </tt>
+<a name="L1419"></a><tt class="py-lineno">1419</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">__class__</tt><tt class="py-op">.</tt><tt class="py-name">__name__</tt><tt class="py-op">,</tt> </tt>
+<a name="L1420"></a><tt class="py-lineno">1420</tt> <tt class="py-line"> <tt class="py-string">', '</tt><tt class="py-op">.</tt><tt class="py-name">join</tt><tt class="py-op">(</tt><tt class="py-op">[</tt><tt class="py-name">repr</tt><tt class="py-op">(</tt><tt id="link-835" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-835', 'v', 'link-523');">v</a></tt><tt class="py-op">)</tt> <tt class="py-keyword">for</tt> <tt id="link-836" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-836', 'v', 'link-523');">v</a></tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">]</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> </tt>
+<a name="L1421"></a><tt class="py-lineno">1421</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt class="py-name">group</tt><tt class="py-op">.</tt><tt id="link-837" class="py-name"><a title="lxml.etree.DTD.name
lxml.etree._Entity.name
lxml.html.InputMixin.name
-lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-834', 'name', 'link-230');">name</a></tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1421"></a><tt class="py-lineno">1421</tt> <tt class="py-line"> </tt>
-<a name="InputElement"></a><div id="InputElement-def"><a name="L1422"></a><tt class="py-lineno">1422</tt> <a class="py-toggle" href="#" id="InputElement-toggle" onclick="return toggle('InputElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html">InputElement</a><tt class="py-op">(</tt><tt class="py-base-class">InputMixin</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="InputElement-expanded"><a name="L1423"></a><tt class="py-lineno">1423</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1424"></a><tt class="py-lineno">1424</tt> <tt class="py-line"><tt class="py-docstring"> Represents an ``<input>`` element.</tt> </tt>
-<a name="L1425"></a><tt class="py-lineno">1425</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1426"></a><tt class="py-lineno">1426</tt> <tt class="py-line"><tt class="py-docstring"> You can get the type with ``.type`` (which is lower-cased and</tt> </tt>
-<a name="L1427"></a><tt class="py-lineno">1427</tt> <tt class="py-line"><tt class="py-docstring"> defaults to ``'text'``).</tt> </tt>
-<a name="L1428"></a><tt class="py-lineno">1428</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1429"></a><tt class="py-lineno">1429</tt> <tt class="py-line"><tt class="py-docstring"> Also you can get and set the value with ``.value``</tt> </tt>
-<a name="L1430"></a><tt class="py-lineno">1430</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1431"></a><tt class="py-lineno">1431</tt> <tt class="py-line"><tt class="py-docstring"> Checkboxes and radios have the attribute ``input.checkable ==</tt> </tt>
-<a name="L1432"></a><tt class="py-lineno">1432</tt> <tt class="py-line"><tt class="py-docstring"> True`` (for all others it is false) and a boolean attribute</tt> </tt>
-<a name="L1433"></a><tt class="py-lineno">1433</tt> <tt class="py-line"><tt class="py-docstring"> ``.checked``.</tt> </tt>
-<a name="L1434"></a><tt class="py-lineno">1434</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1435"></a><tt class="py-lineno">1435</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1436"></a><tt class="py-lineno">1436</tt> <tt class="py-line"> </tt>
-<a name="L1437"></a><tt class="py-lineno">1437</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: I'm a little uncomfortable with the use of .checked</tt> </tt>
-<a name="InputElement._value__get"></a><div id="InputElement._value__get-def"><a name="L1438"></a><tt class="py-lineno">1438</tt> <a class="py-toggle" href="#" id="InputElement._value__get-toggle" onclick="return toggle('InputElement._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._value__get-expanded"><a name="L1439"></a><tt class="py-lineno">1439</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1440"></a><tt class="py-lineno">1440</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value of this element, using the ``value`` attribute.</tt> </tt>
-<a name="L1441"></a><tt class="py-lineno">1441</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1442"></a><tt class="py-lineno">1442</tt> <tt class="py-line"><tt class="py-docstring"> Also, if this is a checkbox and it has no value, this defaults</tt> </tt>
-<a name="L1443"></a><tt class="py-lineno">1443</tt> <tt class="py-line"><tt class="py-docstring"> to ``'on'``. If it is a checkbox or radio that is not</tt> </tt>
-<a name="L1444"></a><tt class="py-lineno">1444</tt> <tt class="py-line"><tt class="py-docstring"> checked, this returns None.</tt> </tt>
-<a name="L1445"></a><tt class="py-lineno">1445</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1446"></a><tt class="py-lineno">1446</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-835" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-835', 'checkable', 'link-530');">checkable</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1447"></a><tt class="py-lineno">1447</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-836" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-836', 'checked', 'link-531');">checked</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1448"></a><tt class="py-lineno">1448</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-837" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.objectify.PyType.name" class="py-name" href="#" onclick="return doclink('link-837', 'name', 'link-233');">name</a></tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1422"></a><tt class="py-lineno">1422</tt> <tt class="py-line"> </tt>
+<a name="InputElement"></a><div id="InputElement-def"><a name="L1423"></a><tt class="py-lineno">1423</tt> <a class="py-toggle" href="#" id="InputElement-toggle" onclick="return toggle('InputElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html">InputElement</a><tt class="py-op">(</tt><tt class="py-base-class">InputMixin</tt><tt class="py-op">,</tt> <tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="InputElement-expanded"><a name="L1424"></a><tt class="py-lineno">1424</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1425"></a><tt class="py-lineno">1425</tt> <tt class="py-line"><tt class="py-docstring"> Represents an ``<input>`` element.</tt> </tt>
+<a name="L1426"></a><tt class="py-lineno">1426</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1427"></a><tt class="py-lineno">1427</tt> <tt class="py-line"><tt class="py-docstring"> You can get the type with ``.type`` (which is lower-cased and</tt> </tt>
+<a name="L1428"></a><tt class="py-lineno">1428</tt> <tt class="py-line"><tt class="py-docstring"> defaults to ``'text'``).</tt> </tt>
+<a name="L1429"></a><tt class="py-lineno">1429</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1430"></a><tt class="py-lineno">1430</tt> <tt class="py-line"><tt class="py-docstring"> Also you can get and set the value with ``.value``</tt> </tt>
+<a name="L1431"></a><tt class="py-lineno">1431</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1432"></a><tt class="py-lineno">1432</tt> <tt class="py-line"><tt class="py-docstring"> Checkboxes and radios have the attribute ``input.checkable ==</tt> </tt>
+<a name="L1433"></a><tt class="py-lineno">1433</tt> <tt class="py-line"><tt class="py-docstring"> True`` (for all others it is false) and a boolean attribute</tt> </tt>
+<a name="L1434"></a><tt class="py-lineno">1434</tt> <tt class="py-line"><tt class="py-docstring"> ``.checked``.</tt> </tt>
+<a name="L1435"></a><tt class="py-lineno">1435</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1436"></a><tt class="py-lineno">1436</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1437"></a><tt class="py-lineno">1437</tt> <tt class="py-line"> </tt>
+<a name="L1438"></a><tt class="py-lineno">1438</tt> <tt class="py-line"> <tt class="py-comment">## FIXME: I'm a little uncomfortable with the use of .checked</tt> </tt>
+<a name="InputElement._value__get"></a><div id="InputElement._value__get-def"><a name="L1439"></a><tt class="py-lineno">1439</tt> <a class="py-toggle" href="#" id="InputElement._value__get-toggle" onclick="return toggle('InputElement._value__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_value__get">_value__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement._value__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._value__get-expanded"><a name="L1440"></a><tt class="py-lineno">1440</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1441"></a><tt class="py-lineno">1441</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the value of this element, using the ``value`` attribute.</tt> </tt>
+<a name="L1442"></a><tt class="py-lineno">1442</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1443"></a><tt class="py-lineno">1443</tt> <tt class="py-line"><tt class="py-docstring"> Also, if this is a checkbox and it has no value, this defaults</tt> </tt>
+<a name="L1444"></a><tt class="py-lineno">1444</tt> <tt class="py-line"><tt class="py-docstring"> to ``'on'``. If it is a checkbox or radio that is not</tt> </tt>
+<a name="L1445"></a><tt class="py-lineno">1445</tt> <tt class="py-line"><tt class="py-docstring"> checked, this returns None.</tt> </tt>
+<a name="L1446"></a><tt class="py-lineno">1446</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1447"></a><tt class="py-lineno">1447</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-838" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-838', 'checkable', 'link-533');">checkable</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1448"></a><tt class="py-lineno">1448</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-839" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-839', 'checked', 'link-534');">checked</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1449"></a><tt class="py-lineno">1449</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-840" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-837', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-keyword">or</tt> <tt class="py-string">'on'</tt> </tt>
-<a name="L1449"></a><tt class="py-lineno">1449</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1450"></a><tt class="py-lineno">1450</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-<a name="L1451"></a><tt class="py-lineno">1451</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-838" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-840', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> <tt class="py-keyword">or</tt> <tt class="py-string">'on'</tt> </tt>
+<a name="L1450"></a><tt class="py-lineno">1450</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1451"></a><tt class="py-lineno">1451</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
+<a name="L1452"></a><tt class="py-lineno">1452</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-841" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-838', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
-</div><a name="InputElement._value__set"></a><div id="InputElement._value__set-def"><a name="L1452"></a><tt class="py-lineno">1452</tt> <a class="py-toggle" href="#" id="InputElement._value__set-toggle" onclick="return toggle('InputElement._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._value__set-expanded"><a name="L1453"></a><tt class="py-lineno">1453</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-839" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-839', 'checkable', 'link-530');">checkable</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1454"></a><tt class="py-lineno">1454</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-840" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-841', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">)</tt> </tt>
+</div><a name="InputElement._value__set"></a><div id="InputElement._value__set-def"><a name="L1453"></a><tt class="py-lineno">1453</tt> <a class="py-toggle" href="#" id="InputElement._value__set-toggle" onclick="return toggle('InputElement._value__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_value__set">_value__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement._value__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._value__set-expanded"><a name="L1454"></a><tt class="py-lineno">1454</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-842" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-842', 'checkable', 'link-533');">checkable</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1455"></a><tt class="py-lineno">1455</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt id="link-843" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-840', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1455"></a><tt class="py-lineno">1455</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-841" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-841', 'checked', 'link-531');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
-<a name="L1456"></a><tt class="py-lineno">1456</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1457"></a><tt class="py-lineno">1457</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-842" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-842', 'checked', 'link-531');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">True</tt> </tt>
-<a name="L1458"></a><tt class="py-lineno">1458</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-843" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-843', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1456"></a><tt class="py-lineno">1456</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-844" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-844', 'checked', 'link-534');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
+<a name="L1457"></a><tt class="py-lineno">1457</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1458"></a><tt class="py-lineno">1458</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-845" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-845', 'checked', 'link-534');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">True</tt> </tt>
+<a name="L1459"></a><tt class="py-lineno">1459</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-846" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-843', 'value', 'link-172');">value</a></tt><tt class="py-op">,</tt> <tt id="link-844" class="py-name"><a title="lxml.html.basestring
-lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-844', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1459"></a><tt class="py-lineno">1459</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-845" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-845', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">,</tt> <tt id="link-846" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-846', 'value', 'link-173');">value</a></tt><tt class="py-op">,</tt> <tt id="link-847" class="py-name"><a title="lxml.html.basestring
+lxml.html.clean.basestring" class="py-name" href="#" onclick="return doclink('link-847', 'basestring', 'link-13');">basestring</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1460"></a><tt class="py-lineno">1460</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-848" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-848', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">,</tt> <tt id="link-849" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-846', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1460"></a><tt class="py-lineno">1460</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1461"></a><tt class="py-lineno">1461</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-847" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-847', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">,</tt> <tt id="link-848" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-849', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1461"></a><tt class="py-lineno">1461</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1462"></a><tt class="py-lineno">1462</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-850" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-850', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'value'</tt><tt class="py-op">,</tt> <tt id="link-851" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-848', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="InputElement._value__del"></a><div id="InputElement._value__del-def"><a name="L1462"></a><tt class="py-lineno">1462</tt> <a class="py-toggle" href="#" id="InputElement._value__del-toggle" onclick="return toggle('InputElement._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._value__del-expanded"><a name="L1463"></a><tt class="py-lineno">1463</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-849" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-849', 'checkable', 'link-530');">checkable</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1464"></a><tt class="py-lineno">1464</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-850" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-850', 'checked', 'link-531');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
-<a name="L1465"></a><tt class="py-lineno">1465</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1466"></a><tt class="py-lineno">1466</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'value'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-851" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-851', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="InputElement._value__del"></a><div id="InputElement._value__del-def"><a name="L1463"></a><tt class="py-lineno">1463</tt> <a class="py-toggle" href="#" id="InputElement._value__del-toggle" onclick="return toggle('InputElement._value__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_value__del">_value__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement._value__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._value__del-expanded"><a name="L1464"></a><tt class="py-lineno">1464</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-852" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-852', 'checkable', 'link-533');">checkable</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1465"></a><tt class="py-lineno">1465</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-853" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-853', 'checked', 'link-534');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">False</tt> </tt>
+<a name="L1466"></a><tt class="py-lineno">1466</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1467"></a><tt class="py-lineno">1467</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'value'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-854" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-851', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1467"></a><tt class="py-lineno">1467</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-852" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-854', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1468"></a><tt class="py-lineno">1468</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-855" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-852', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'value'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1468"></a><tt class="py-lineno">1468</tt> <tt class="py-line"> <tt id="link-853" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-855', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'value'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1469"></a><tt class="py-lineno">1469</tt> <tt class="py-line"> <tt id="link-856" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-853', 'value', 'link-172');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-854" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-856', 'value', 'link-173');">value</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-857" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-854', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-855" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-857', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">,</tt> <tt id="link-858" class="py-name"><a title="lxml.html.CheckboxGroup._value__set
lxml.html.InputElement._value__set
lxml.html.RadioGroup._value__set
lxml.html.SelectElement._value__set
-lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-855', '_value__set', 'link-663');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-856" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
+lxml.html.TextareaElement._value__set" class="py-name" href="#" onclick="return doclink('link-858', '_value__set', 'link-666');">_value__set</a></tt><tt class="py-op">,</tt> <tt id="link-859" class="py-name"><a title="lxml.html.CheckboxGroup._value__del
lxml.html.InputElement._value__del
lxml.html.RadioGroup._value__del
lxml.html.SelectElement._value__del
-lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-856', '_value__del', 'link-664');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-857" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
+lxml.html.TextareaElement._value__del" class="py-name" href="#" onclick="return doclink('link-859', '_value__del', 'link-667');">_value__del</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-860" class="py-name"><a title="lxml.html.CheckboxGroup._value__get
lxml.html.InputElement._value__get
lxml.html.RadioGroup._value__get
lxml.html.SelectElement._value__get
-lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-857', '_value__get', 'link-662');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-858" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-858', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1469"></a><tt class="py-lineno">1469</tt> <tt class="py-line"> </tt>
-<a name="InputElement._type__get"></a><div id="InputElement._type__get-def"><a name="L1470"></a><tt class="py-lineno">1470</tt> <a class="py-toggle" href="#" id="InputElement._type__get-toggle" onclick="return toggle('InputElement._type__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_type__get">_type__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement._type__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._type__get-expanded"><a name="L1471"></a><tt class="py-lineno">1471</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1472"></a><tt class="py-lineno">1472</tt> <tt class="py-line"><tt class="py-docstring"> Return the type of this element (using the type attribute).</tt> </tt>
-<a name="L1473"></a><tt class="py-lineno">1473</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1474"></a><tt class="py-lineno">1474</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-859" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.html.TextareaElement._value__get" class="py-name" href="#" onclick="return doclink('link-860', '_value__get', 'link-665');">_value__get</a></tt><tt class="py-op">.</tt><tt id="link-861" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-861', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1470"></a><tt class="py-lineno">1470</tt> <tt class="py-line"> </tt>
+<a name="InputElement._type__get"></a><div id="InputElement._type__get-def"><a name="L1471"></a><tt class="py-lineno">1471</tt> <a class="py-toggle" href="#" id="InputElement._type__get-toggle" onclick="return toggle('InputElement._type__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_type__get">_type__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement._type__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._type__get-expanded"><a name="L1472"></a><tt class="py-lineno">1472</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1473"></a><tt class="py-lineno">1473</tt> <tt class="py-line"><tt class="py-docstring"> Return the type of this element (using the type attribute).</tt> </tt>
+<a name="L1474"></a><tt class="py-lineno">1474</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1475"></a><tt class="py-lineno">1475</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-862" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-859', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'type'</tt><tt class="py-op">,</tt> <tt class="py-string">'text'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-</div><a name="InputElement._type__set"></a><div id="InputElement._type__set-def"><a name="L1475"></a><tt class="py-lineno">1475</tt> <a class="py-toggle" href="#" id="InputElement._type__set-toggle" onclick="return toggle('InputElement._type__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_type__set">_type__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement._type__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._type__set-expanded"><a name="L1476"></a><tt class="py-lineno">1476</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-860" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-860', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'type'</tt><tt class="py-op">,</tt> <tt id="link-861" class="py-name"><a title="lxml.html.CheckboxGroup.value
-lxml.html.InputElement.value
-lxml.html.RadioGroup.value
-lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-861', 'value', 'link-172');">value</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1477"></a><tt class="py-lineno">1477</tt> <tt class="py-line"> <tt id="link-862" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-862', 'type', 'link-237');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-863" class="py-name" targets="Method lxml.html.InputElement._type__get()=lxml.html.InputElement-class.html#_type__get"><a title="lxml.html.InputElement._type__get" class="py-name" href="#" onclick="return doclink('link-863', '_type__get', 'link-863');">_type__get</a></tt><tt class="py-op">,</tt> <tt id="link-864" class="py-name" targets="Method lxml.html.InputElement._type__set()=lxml.html.InputElement-class.html#_type__set"><a title="lxml.html.InputElement._type__set" class="py-name" href="#" onclick="return doclink('link-864', '_type__set', 'link-864');">_type__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-865" class="py-name"><a title="lxml.html.InputElement._type__get" class="py-name" href="#" onclick="return doclink('link-865', '_type__get', 'link-863');">_type__get</a></tt><tt class="py-op">.</tt><tt id="link-866" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-866', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1478"></a><tt class="py-lineno">1478</tt> <tt class="py-line"> </tt>
-<a name="InputElement.checkable"></a><div id="InputElement.checkable-def"><a name="L1479"></a><tt class="py-lineno">1479</tt> <a class="py-toggle" href="#" id="InputElement.checkable-toggle" onclick="return toggle('InputElement.checkable');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#checkable">checkable</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement.checkable-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement.checkable-expanded"><a name="L1480"></a><tt class="py-lineno">1480</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1481"></a><tt class="py-lineno">1481</tt> <tt class="py-line"><tt class="py-docstring"> Boolean: can this element be checked?</tt> </tt>
-<a name="L1482"></a><tt class="py-lineno">1482</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1483"></a><tt class="py-lineno">1483</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-867" class="py-name"><a title="lxml.etree._LogEntry.type
-lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-867', 'type', 'link-237');">type</a></tt> <tt class="py-keyword">in</tt> <tt class="py-op">[</tt><tt class="py-string">'checkbox'</tt><tt class="py-op">,</tt> <tt class="py-string">'radio'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1484"></a><tt class="py-lineno">1484</tt> <tt class="py-line"> <tt id="link-868" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-868', 'checkable', 'link-530');">checkable</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-869" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-869', 'checkable', 'link-530');">checkable</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-870" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-870', 'checkable', 'link-530');">checkable</a></tt><tt class="py-op">.</tt><tt id="link-871" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-871', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1485"></a><tt class="py-lineno">1485</tt> <tt class="py-line"> </tt>
-<a name="InputElement._checked__get"></a><div id="InputElement._checked__get-def"><a name="L1486"></a><tt class="py-lineno">1486</tt> <a class="py-toggle" href="#" id="InputElement._checked__get-toggle" onclick="return toggle('InputElement._checked__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_checked__get">_checked__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement._checked__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._checked__get-expanded"><a name="L1487"></a><tt class="py-lineno">1487</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1488"></a><tt class="py-lineno">1488</tt> <tt class="py-line"><tt class="py-docstring"> Boolean attribute to get/set the presence of the ``checked``</tt> </tt>
-<a name="L1489"></a><tt class="py-lineno">1489</tt> <tt class="py-line"><tt class="py-docstring"> attribute.</tt> </tt>
-<a name="L1490"></a><tt class="py-lineno">1490</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1491"></a><tt class="py-lineno">1491</tt> <tt class="py-line"><tt class="py-docstring"> You can only use this on checkable input types.</tt> </tt>
-<a name="L1492"></a><tt class="py-lineno">1492</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1493"></a><tt class="py-lineno">1493</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-872" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-872', 'checkable', 'link-530');">checkable</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1494"></a><tt class="py-lineno">1494</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">(</tt><tt class="py-string">'Not a checkable input type'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1495"></a><tt class="py-lineno">1495</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-873" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-862', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'type'</tt><tt class="py-op">,</tt> <tt class="py-string">'text'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">lower</tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+</div><a name="InputElement._type__set"></a><div id="InputElement._type__set-def"><a name="L1476"></a><tt class="py-lineno">1476</tt> <a class="py-toggle" href="#" id="InputElement._type__set-toggle" onclick="return toggle('InputElement._type__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_type__set">_type__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement._type__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._type__set-expanded"><a name="L1477"></a><tt class="py-lineno">1477</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-863" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-863', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'type'</tt><tt class="py-op">,</tt> <tt id="link-864" class="py-name"><a title="lxml.html.CheckboxGroup.value
+lxml.html.InputElement.value
+lxml.html.RadioGroup.value
+lxml.html.SelectElement.value
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-864', 'value', 'link-173');">value</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1478"></a><tt class="py-lineno">1478</tt> <tt class="py-line"> <tt id="link-865" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-865', 'type', 'link-240');">type</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-866" class="py-name" targets="Method lxml.html.InputElement._type__get()=lxml.html.InputElement-class.html#_type__get"><a title="lxml.html.InputElement._type__get" class="py-name" href="#" onclick="return doclink('link-866', '_type__get', 'link-866');">_type__get</a></tt><tt class="py-op">,</tt> <tt id="link-867" class="py-name" targets="Method lxml.html.InputElement._type__set()=lxml.html.InputElement-class.html#_type__set"><a title="lxml.html.InputElement._type__set" class="py-name" href="#" onclick="return doclink('link-867', '_type__set', 'link-867');">_type__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-868" class="py-name"><a title="lxml.html.InputElement._type__get" class="py-name" href="#" onclick="return doclink('link-868', '_type__get', 'link-866');">_type__get</a></tt><tt class="py-op">.</tt><tt id="link-869" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-869', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1479"></a><tt class="py-lineno">1479</tt> <tt class="py-line"> </tt>
+<a name="InputElement.checkable"></a><div id="InputElement.checkable-def"><a name="L1480"></a><tt class="py-lineno">1480</tt> <a class="py-toggle" href="#" id="InputElement.checkable-toggle" onclick="return toggle('InputElement.checkable');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#checkable">checkable</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement.checkable-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement.checkable-expanded"><a name="L1481"></a><tt class="py-lineno">1481</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1482"></a><tt class="py-lineno">1482</tt> <tt class="py-line"><tt class="py-docstring"> Boolean: can this element be checked?</tt> </tt>
+<a name="L1483"></a><tt class="py-lineno">1483</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1484"></a><tt class="py-lineno">1484</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-870" class="py-name"><a title="lxml.etree._LogEntry.type
+lxml.html.InputElement.type" class="py-name" href="#" onclick="return doclink('link-870', 'type', 'link-240');">type</a></tt> <tt class="py-keyword">in</tt> <tt class="py-op">[</tt><tt class="py-string">'checkbox'</tt><tt class="py-op">,</tt> <tt class="py-string">'radio'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1485"></a><tt class="py-lineno">1485</tt> <tt class="py-line"> <tt id="link-871" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-871', 'checkable', 'link-533');">checkable</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-872" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-872', 'checkable', 'link-533');">checkable</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-873" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-873', 'checkable', 'link-533');">checkable</a></tt><tt class="py-op">.</tt><tt id="link-874" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-874', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1486"></a><tt class="py-lineno">1486</tt> <tt class="py-line"> </tt>
+<a name="InputElement._checked__get"></a><div id="InputElement._checked__get-def"><a name="L1487"></a><tt class="py-lineno">1487</tt> <a class="py-toggle" href="#" id="InputElement._checked__get-toggle" onclick="return toggle('InputElement._checked__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_checked__get">_checked__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement._checked__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._checked__get-expanded"><a name="L1488"></a><tt class="py-lineno">1488</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1489"></a><tt class="py-lineno">1489</tt> <tt class="py-line"><tt class="py-docstring"> Boolean attribute to get/set the presence of the ``checked``</tt> </tt>
+<a name="L1490"></a><tt class="py-lineno">1490</tt> <tt class="py-line"><tt class="py-docstring"> attribute.</tt> </tt>
+<a name="L1491"></a><tt class="py-lineno">1491</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1492"></a><tt class="py-lineno">1492</tt> <tt class="py-line"><tt class="py-docstring"> You can only use this on checkable input types.</tt> </tt>
+<a name="L1493"></a><tt class="py-lineno">1493</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1494"></a><tt class="py-lineno">1494</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-875" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-875', 'checkable', 'link-533');">checkable</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1495"></a><tt class="py-lineno">1495</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">(</tt><tt class="py-string">'Not a checkable input type'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1496"></a><tt class="py-lineno">1496</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-876" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-873', 'attrib', 'link-92');">attrib</a></tt> </tt>
-</div><a name="InputElement._checked__set"></a><div id="InputElement._checked__set-def"><a name="L1496"></a><tt class="py-lineno">1496</tt> <a class="py-toggle" href="#" id="InputElement._checked__set-toggle" onclick="return toggle('InputElement._checked__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_checked__set">_checked__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="InputElement._checked__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._checked__set-expanded"><a name="L1497"></a><tt class="py-lineno">1497</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-874" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-874', 'checkable', 'link-530');">checkable</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1498"></a><tt class="py-lineno">1498</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">(</tt><tt class="py-string">'Not a checkable input type'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1499"></a><tt class="py-lineno">1499</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-875" class="py-name"><a title="lxml.html.CheckboxGroup.value
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-876', 'attrib', 'link-93');">attrib</a></tt> </tt>
+</div><a name="InputElement._checked__set"></a><div id="InputElement._checked__set-def"><a name="L1497"></a><tt class="py-lineno">1497</tt> <a class="py-toggle" href="#" id="InputElement._checked__set-toggle" onclick="return toggle('InputElement._checked__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.InputElement-class.html#_checked__set">_checked__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">value</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="InputElement._checked__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="InputElement._checked__set-expanded"><a name="L1498"></a><tt class="py-lineno">1498</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-877" class="py-name"><a title="lxml.html.InputElement.checkable" class="py-name" href="#" onclick="return doclink('link-877', 'checkable', 'link-533');">checkable</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1499"></a><tt class="py-lineno">1499</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">(</tt><tt class="py-string">'Not a checkable input type'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1500"></a><tt class="py-lineno">1500</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-878" class="py-name"><a title="lxml.html.CheckboxGroup.value
lxml.html.InputElement.value
lxml.html.RadioGroup.value
lxml.html.SelectElement.value
-lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-875', 'value', 'link-172');">value</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1500"></a><tt class="py-lineno">1500</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-876" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-876', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'checked'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
-<a name="L1501"></a><tt class="py-lineno">1501</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1502"></a><tt class="py-lineno">1502</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-877" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.html.TextareaElement.value" class="py-name" href="#" onclick="return doclink('link-878', 'value', 'link-173');">value</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1501"></a><tt class="py-lineno">1501</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-879" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-879', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'checked'</tt><tt class="py-op">,</tt> <tt class="py-string">''</tt><tt class="py-op">)</tt> </tt>
+<a name="L1502"></a><tt class="py-lineno">1502</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1503"></a><tt class="py-lineno">1503</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'checked'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-880" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-877', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1503"></a><tt class="py-lineno">1503</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-878" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-880', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1504"></a><tt class="py-lineno">1504</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-881" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-878', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'checked'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1504"></a><tt class="py-lineno">1504</tt> <tt class="py-line"> <tt id="link-879" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-879', 'checked', 'link-531');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-880" class="py-name" targets="Method lxml.html.InputElement._checked__get()=lxml.html.InputElement-class.html#_checked__get"><a title="lxml.html.InputElement._checked__get" class="py-name" href="#" onclick="return doclink('link-880', '_checked__get', 'link-880');">_checked__get</a></tt><tt class="py-op">,</tt> <tt id="link-881" class="py-name" targets="Method lxml.html.InputElement._checked__set()=lxml.html.InputElement-class.html#_checked__set"><a title="lxml.html.InputElement._checked__set" class="py-name" href="#" onclick="return doclink('link-881', '_checked__set', 'link-881');">_checked__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-882" class="py-name"><a title="lxml.html.InputElement._checked__get" class="py-name" href="#" onclick="return doclink('link-882', '_checked__get', 'link-880');">_checked__get</a></tt><tt class="py-op">.</tt><tt id="link-883" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-883', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1505"></a><tt class="py-lineno">1505</tt> <tt class="py-line"> </tt>
-<a name="L1506"></a><tt class="py-lineno">1506</tt> <tt class="py-line"><tt id="link-884" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-884', 'HtmlElementClassLookup', 'link-566');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-885" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-885', '_default_element_classes', 'link-263');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'input'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-886" class="py-name" targets="Class lxml.html.InputElement=lxml.html.InputElement-class.html"><a title="lxml.html.InputElement" class="py-name" href="#" onclick="return doclink('link-886', 'InputElement', 'link-886');">InputElement</a></tt> </tt>
-<a name="L1507"></a><tt class="py-lineno">1507</tt> <tt class="py-line"> </tt>
-<a name="LabelElement"></a><div id="LabelElement-def"><a name="L1508"></a><tt class="py-lineno">1508</tt> <a class="py-toggle" href="#" id="LabelElement-toggle" onclick="return toggle('LabelElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html">LabelElement</a><tt class="py-op">(</tt><tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="LabelElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="LabelElement-expanded"><a name="L1509"></a><tt class="py-lineno">1509</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1510"></a><tt class="py-lineno">1510</tt> <tt class="py-line"><tt class="py-docstring"> Represents a ``<label>`` element.</tt> </tt>
-<a name="L1511"></a><tt class="py-lineno">1511</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1512"></a><tt class="py-lineno">1512</tt> <tt class="py-line"><tt class="py-docstring"> Label elements are linked to other elements with their ``for``</tt> </tt>
-<a name="L1513"></a><tt class="py-lineno">1513</tt> <tt class="py-line"><tt class="py-docstring"> attribute. You can access this element with ``label.for_element``.</tt> </tt>
-<a name="L1514"></a><tt class="py-lineno">1514</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1515"></a><tt class="py-lineno">1515</tt> <tt class="py-line"> </tt>
-<a name="LabelElement._for_element__get"></a><div id="LabelElement._for_element__get-def"><a name="L1516"></a><tt class="py-lineno">1516</tt> <a class="py-toggle" href="#" id="LabelElement._for_element__get-toggle" onclick="return toggle('LabelElement._for_element__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html#_for_element__get">_for_element__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="LabelElement._for_element__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="LabelElement._for_element__get-expanded"><a name="L1517"></a><tt class="py-lineno">1517</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1518"></a><tt class="py-lineno">1518</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the element this label points to. Return None if it</tt> </tt>
-<a name="L1519"></a><tt class="py-lineno">1519</tt> <tt class="py-line"><tt class="py-docstring"> can't be found.</tt> </tt>
-<a name="L1520"></a><tt class="py-lineno">1520</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1521"></a><tt class="py-lineno">1521</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-887" class="py-name"><a title="lxml.etree._Attrib.get
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-881', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'checked'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1505"></a><tt class="py-lineno">1505</tt> <tt class="py-line"> <tt id="link-882" class="py-name"><a title="lxml.html.InputElement.checked" class="py-name" href="#" onclick="return doclink('link-882', 'checked', 'link-534');">checked</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-883" class="py-name" targets="Method lxml.html.InputElement._checked__get()=lxml.html.InputElement-class.html#_checked__get"><a title="lxml.html.InputElement._checked__get" class="py-name" href="#" onclick="return doclink('link-883', '_checked__get', 'link-883');">_checked__get</a></tt><tt class="py-op">,</tt> <tt id="link-884" class="py-name" targets="Method lxml.html.InputElement._checked__set()=lxml.html.InputElement-class.html#_checked__set"><a title="lxml.html.InputElement._checked__set" class="py-name" href="#" onclick="return doclink('link-884', '_checked__set', 'link-884');">_checked__set</a></tt><tt class="py-op">,</tt> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-885" class="py-name"><a title="lxml.html.InputElement._checked__get" class="py-name" href="#" onclick="return doclink('link-885', '_checked__get', 'link-883');">_checked__get</a></tt><tt class="py-op">.</tt><tt id="link-886" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-886', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1506"></a><tt class="py-lineno">1506</tt> <tt class="py-line"> </tt>
+<a name="L1507"></a><tt class="py-lineno">1507</tt> <tt class="py-line"><tt id="link-887" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-887', 'HtmlElementClassLookup', 'link-569');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-888" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-888', '_default_element_classes', 'link-266');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'input'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-889" class="py-name" targets="Class lxml.html.InputElement=lxml.html.InputElement-class.html"><a title="lxml.html.InputElement" class="py-name" href="#" onclick="return doclink('link-889', 'InputElement', 'link-889');">InputElement</a></tt> </tt>
+<a name="L1508"></a><tt class="py-lineno">1508</tt> <tt class="py-line"> </tt>
+<a name="LabelElement"></a><div id="LabelElement-def"><a name="L1509"></a><tt class="py-lineno">1509</tt> <a class="py-toggle" href="#" id="LabelElement-toggle" onclick="return toggle('LabelElement');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html">LabelElement</a><tt class="py-op">(</tt><tt class="py-base-class">HtmlElement</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="LabelElement-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="LabelElement-expanded"><a name="L1510"></a><tt class="py-lineno">1510</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1511"></a><tt class="py-lineno">1511</tt> <tt class="py-line"><tt class="py-docstring"> Represents a ``<label>`` element.</tt> </tt>
+<a name="L1512"></a><tt class="py-lineno">1512</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1513"></a><tt class="py-lineno">1513</tt> <tt class="py-line"><tt class="py-docstring"> Label elements are linked to other elements with their ``for``</tt> </tt>
+<a name="L1514"></a><tt class="py-lineno">1514</tt> <tt class="py-line"><tt class="py-docstring"> attribute. You can access this element with ``label.for_element``.</tt> </tt>
+<a name="L1515"></a><tt class="py-lineno">1515</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1516"></a><tt class="py-lineno">1516</tt> <tt class="py-line"> </tt>
+<a name="LabelElement._for_element__get"></a><div id="LabelElement._for_element__get-def"><a name="L1517"></a><tt class="py-lineno">1517</tt> <a class="py-toggle" href="#" id="LabelElement._for_element__get-toggle" onclick="return toggle('LabelElement._for_element__get');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html#_for_element__get">_for_element__get</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="LabelElement._for_element__get-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="LabelElement._for_element__get-expanded"><a name="L1518"></a><tt class="py-lineno">1518</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1519"></a><tt class="py-lineno">1519</tt> <tt class="py-line"><tt class="py-docstring"> Get/set the element this label points to. Return None if it</tt> </tt>
+<a name="L1520"></a><tt class="py-lineno">1520</tt> <tt class="py-line"><tt class="py-docstring"> can't be found.</tt> </tt>
+<a name="L1521"></a><tt class="py-lineno">1521</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1522"></a><tt class="py-lineno">1522</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-890" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-887', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'for'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1522"></a><tt class="py-lineno">1522</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
-<a name="L1523"></a><tt class="py-lineno">1523</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
-<a name="L1524"></a><tt class="py-lineno">1524</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-888" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-888', 'body', 'link-70');">body</a></tt><tt class="py-op">.</tt><tt id="link-889" class="py-name" targets="Method lxml.html.HtmlMixin.get_element_by_id()=lxml.html.HtmlMixin-class.html#get_element_by_id"><a title="lxml.html.HtmlMixin.get_element_by_id" class="py-name" href="#" onclick="return doclink('link-889', 'get_element_by_id', 'link-889');">get_element_by_id</a></tt><tt class="py-op">(</tt><tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
-</div><a name="LabelElement._for_element__set"></a><div id="LabelElement._for_element__set-def"><a name="L1525"></a><tt class="py-lineno">1525</tt> <a class="py-toggle" href="#" id="LabelElement._for_element__set-toggle" onclick="return toggle('LabelElement._for_element__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html#_for_element__set">_for_element__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">other</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="LabelElement._for_element__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="LabelElement._for_element__set-expanded"><a name="L1526"></a><tt class="py-lineno">1526</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">other</tt><tt class="py-op">.</tt><tt id="link-890" class="py-name"><a title="lxml.etree._Attrib.get
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-890', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'for'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1523"></a><tt class="py-lineno">1523</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
+<a name="L1524"></a><tt class="py-lineno">1524</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">None</tt> </tt>
+<a name="L1525"></a><tt class="py-lineno">1525</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-891" class="py-name"><a title="lxml.html.HtmlMixin.body" class="py-name" href="#" onclick="return doclink('link-891', 'body', 'link-71');">body</a></tt><tt class="py-op">.</tt><tt id="link-892" class="py-name" targets="Method lxml.html.HtmlMixin.get_element_by_id()=lxml.html.HtmlMixin-class.html#get_element_by_id"><a title="lxml.html.HtmlMixin.get_element_by_id" class="py-name" href="#" onclick="return doclink('link-892', 'get_element_by_id', 'link-892');">get_element_by_id</a></tt><tt class="py-op">(</tt><tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
+</div><a name="LabelElement._for_element__set"></a><div id="LabelElement._for_element__set-def"><a name="L1526"></a><tt class="py-lineno">1526</tt> <a class="py-toggle" href="#" id="LabelElement._for_element__set-toggle" onclick="return toggle('LabelElement._for_element__set');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html#_for_element__set">_for_element__set</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-param">other</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="LabelElement._for_element__set-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="LabelElement._for_element__set-expanded"><a name="L1527"></a><tt class="py-lineno">1527</tt> <tt class="py-line"> <tt class="py-name">id</tt> <tt class="py-op">=</tt> <tt class="py-name">other</tt><tt class="py-op">.</tt><tt id="link-893" class="py-name"><a title="lxml.etree._Attrib.get
lxml.etree._Element.get
lxml.etree._IDDict.get
-lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-890', 'get', 'link-80');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1527"></a><tt class="py-lineno">1527</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
-<a name="L1528"></a><tt class="py-lineno">1528</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
-<a name="L1529"></a><tt class="py-lineno">1529</tt> <tt class="py-line"> <tt class="py-string">"Element %r has no id attribute"</tt> <tt class="py-op">%</tt> <tt class="py-name">other</tt><tt class="py-op">)</tt> </tt>
-<a name="L1530"></a><tt class="py-lineno">1530</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-891" class="py-name"><a title="lxml.etree._Element.set
-lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-891', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'for'</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
-</div><a name="LabelElement._for_element__del"></a><div id="LabelElement._for_element__del-def"><a name="L1531"></a><tt class="py-lineno">1531</tt> <a class="py-toggle" href="#" id="LabelElement._for_element__del-toggle" onclick="return toggle('LabelElement._for_element__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html#_for_element__del">_for_element__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="LabelElement._for_element__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="LabelElement._for_element__del-expanded"><a name="L1532"></a><tt class="py-lineno">1532</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'id'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-892" class="py-name"><a title="lxml.etree._Element.attrib
+lxml.etree._ProcessingInstruction.get" class="py-name" href="#" onclick="return doclink('link-893', 'get', 'link-81');">get</a></tt><tt class="py-op">(</tt><tt class="py-string">'id'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1528"></a><tt class="py-lineno">1528</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">id</tt><tt class="py-op">:</tt> </tt>
+<a name="L1529"></a><tt class="py-lineno">1529</tt> <tt class="py-line"> <tt class="py-keyword">raise</tt> <tt class="py-name">TypeError</tt><tt class="py-op">(</tt> </tt>
+<a name="L1530"></a><tt class="py-lineno">1530</tt> <tt class="py-line"> <tt class="py-string">"Element %r has no id attribute"</tt> <tt class="py-op">%</tt> <tt class="py-name">other</tt><tt class="py-op">)</tt> </tt>
+<a name="L1531"></a><tt class="py-lineno">1531</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-894" class="py-name"><a title="lxml.etree._Element.set
+lxml.etree._XSLTProcessingInstruction.set" class="py-name" href="#" onclick="return doclink('link-894', 'set', 'link-9');">set</a></tt><tt class="py-op">(</tt><tt class="py-string">'for'</tt><tt class="py-op">,</tt> <tt class="py-name">id</tt><tt class="py-op">)</tt> </tt>
+</div><a name="LabelElement._for_element__del"></a><div id="LabelElement._for_element__del-def"><a name="L1532"></a><tt class="py-lineno">1532</tt> <a class="py-toggle" href="#" id="LabelElement._for_element__del-toggle" onclick="return toggle('LabelElement._for_element__del');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.LabelElement-class.html#_for_element__del">_for_element__del</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="LabelElement._for_element__del-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="LabelElement._for_element__del-expanded"><a name="L1533"></a><tt class="py-lineno">1533</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-string">'id'</tt> <tt class="py-keyword">in</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-895" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-892', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">:</tt> </tt>
-<a name="L1533"></a><tt class="py-lineno">1533</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-893" class="py-name"><a title="lxml.etree._Element.attrib
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-895', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">:</tt> </tt>
+<a name="L1534"></a><tt class="py-lineno">1534</tt> <tt class="py-line"> <tt class="py-keyword">del</tt> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-896" class="py-name"><a title="lxml.etree._Element.attrib
lxml.etree._ProcessingInstruction.attrib
-xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-893', 'attrib', 'link-92');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'id'</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1534"></a><tt class="py-lineno">1534</tt> <tt class="py-line"> <tt id="link-894" class="py-name" targets="Variable lxml.html.LabelElement.for_element=lxml.html.LabelElement-class.html#for_element"><a title="lxml.html.LabelElement.for_element" class="py-name" href="#" onclick="return doclink('link-894', 'for_element', 'link-894');">for_element</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-895" class="py-name" targets="Method lxml.html.LabelElement._for_element__get()=lxml.html.LabelElement-class.html#_for_element__get"><a title="lxml.html.LabelElement._for_element__get" class="py-name" href="#" onclick="return doclink('link-895', '_for_element__get', 'link-895');">_for_element__get</a></tt><tt class="py-op">,</tt> <tt id="link-896" class="py-name" targets="Method lxml.html.LabelElement._for_element__set()=lxml.html.LabelElement-class.html#_for_element__set"><a title="lxml.html.LabelElement._for_element__set" class="py-name" href="#" onclick="return doclink('link-896', '_for_element__set', 'link-896');">_for_element__set</a></tt><tt class="py-op">,</tt> <tt id="link-897" class="py-name" targets="Method lxml.html.LabelElement._for_element__del()=lxml.html.LabelElement-class.html#_for_element__del"><a title="lxml.html.LabelElement._for_element__del" class="py-name" href="#" onclick="return doclink('link-897', '_for_element__del', 'link-897');">_for_element__del</a></tt><tt class="py-op">,</tt> </tt>
-<a name="L1535"></a><tt class="py-lineno">1535</tt> <tt class="py-line"> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-898" class="py-name"><a title="lxml.html.LabelElement._for_element__get" class="py-name" href="#" onclick="return doclink('link-898', '_for_element__get', 'link-895');">_for_element__get</a></tt><tt class="py-op">.</tt><tt id="link-899" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-899', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1536"></a><tt class="py-lineno">1536</tt> <tt class="py-line"> </tt>
-<a name="L1537"></a><tt class="py-lineno">1537</tt> <tt class="py-line"><tt id="link-900" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-900', 'HtmlElementClassLookup', 'link-566');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-901" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-901', '_default_element_classes', 'link-263');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'label'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-902" class="py-name" targets="Class lxml.html.LabelElement=lxml.html.LabelElement-class.html"><a title="lxml.html.LabelElement" class="py-name" href="#" onclick="return doclink('link-902', 'LabelElement', 'link-902');">LabelElement</a></tt> </tt>
-<a name="L1538"></a><tt class="py-lineno">1538</tt> <tt class="py-line"> </tt>
-<a name="L1539"></a><tt class="py-lineno">1539</tt> <tt class="py-line"><tt class="py-comment">############################################################</tt> </tt>
-<a name="L1540"></a><tt class="py-lineno">1540</tt> <tt class="py-line"><tt class="py-comment">## Serialization</tt> </tt>
-<a name="L1541"></a><tt class="py-lineno">1541</tt> <tt class="py-line"><tt class="py-comment">############################################################</tt> </tt>
-<a name="L1542"></a><tt class="py-lineno">1542</tt> <tt class="py-line"> </tt>
-<a name="html_to_xhtml"></a><div id="html_to_xhtml-def"><a name="L1543"></a><tt class="py-lineno">1543</tt> <a class="py-toggle" href="#" id="html_to_xhtml-toggle" onclick="return toggle('html_to_xhtml');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#html_to_xhtml">html_to_xhtml</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="html_to_xhtml-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="html_to_xhtml-expanded"><a name="L1544"></a><tt class="py-lineno">1544</tt> <tt class="py-line"> <tt class="py-docstring">"""Convert all tags in an HTML tree to XHTML by moving them to the</tt> </tt>
-<a name="L1545"></a><tt class="py-lineno">1545</tt> <tt class="py-line"><tt class="py-docstring"> XHTML namespace.</tt> </tt>
-<a name="L1546"></a><tt class="py-lineno">1546</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1547"></a><tt class="py-lineno">1547</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
-<a name="L1548"></a><tt class="py-lineno">1548</tt> <tt class="py-line"> <tt id="link-903" class="py-name"><a title="lxml.html
+xml.etree.ElementTree.Element.attrib" class="py-name" href="#" onclick="return doclink('link-896', 'attrib', 'link-93');">attrib</a></tt><tt class="py-op">[</tt><tt class="py-string">'id'</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1535"></a><tt class="py-lineno">1535</tt> <tt class="py-line"> <tt id="link-897" class="py-name" targets="Variable lxml.html.LabelElement.for_element=lxml.html.LabelElement-class.html#for_element"><a title="lxml.html.LabelElement.for_element" class="py-name" href="#" onclick="return doclink('link-897', 'for_element', 'link-897');">for_element</a></tt> <tt class="py-op">=</tt> <tt class="py-name">property</tt><tt class="py-op">(</tt><tt id="link-898" class="py-name" targets="Method lxml.html.LabelElement._for_element__get()=lxml.html.LabelElement-class.html#_for_element__get"><a title="lxml.html.LabelElement._for_element__get" class="py-name" href="#" onclick="return doclink('link-898', '_for_element__get', 'link-898');">_for_element__get</a></tt><tt class="py-op">,</tt> <tt id="link-899" class="py-name" targets="Method lxml.html.LabelElement._for_element__set()=lxml.html.LabelElement-class.html#_for_element__set"><a title="lxml.html.LabelElement._for_element__set" class="py-name" href="#" onclick="return doclink('link-899', '_for_element__set', 'link-899');">_for_element__set</a></tt><tt class="py-op">,</tt> <tt id="link-900" class="py-name" targets="Method lxml.html.LabelElement._for_element__del()=lxml.html.LabelElement-class.html#_for_element__del"><a title="lxml.html.LabelElement._for_element__del" class="py-name" href="#" onclick="return doclink('link-900', '_for_element__del', 'link-900');">_for_element__del</a></tt><tt class="py-op">,</tt> </tt>
+<a name="L1536"></a><tt class="py-lineno">1536</tt> <tt class="py-line"> <tt class="py-name">doc</tt><tt class="py-op">=</tt><tt id="link-901" class="py-name"><a title="lxml.html.LabelElement._for_element__get" class="py-name" href="#" onclick="return doclink('link-901', '_for_element__get', 'link-898');">_for_element__get</a></tt><tt class="py-op">.</tt><tt id="link-902" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-902', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1537"></a><tt class="py-lineno">1537</tt> <tt class="py-line"> </tt>
+<a name="L1538"></a><tt class="py-lineno">1538</tt> <tt class="py-line"><tt id="link-903" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-903', 'HtmlElementClassLookup', 'link-569');">HtmlElementClassLookup</a></tt><tt class="py-op">.</tt><tt id="link-904" class="py-name"><a title="lxml.html.HtmlElementClassLookup._default_element_classes" class="py-name" href="#" onclick="return doclink('link-904', '_default_element_classes', 'link-266');">_default_element_classes</a></tt><tt class="py-op">[</tt><tt class="py-string">'label'</tt><tt class="py-op">]</tt> <tt class="py-op">=</tt> <tt id="link-905" class="py-name" targets="Class lxml.html.LabelElement=lxml.html.LabelElement-class.html"><a title="lxml.html.LabelElement" class="py-name" href="#" onclick="return doclink('link-905', 'LabelElement', 'link-905');">LabelElement</a></tt> </tt>
+<a name="L1539"></a><tt class="py-lineno">1539</tt> <tt class="py-line"> </tt>
+<a name="L1540"></a><tt class="py-lineno">1540</tt> <tt class="py-line"><tt class="py-comment">############################################################</tt> </tt>
+<a name="L1541"></a><tt class="py-lineno">1541</tt> <tt class="py-line"><tt class="py-comment">## Serialization</tt> </tt>
+<a name="L1542"></a><tt class="py-lineno">1542</tt> <tt class="py-line"><tt class="py-comment">############################################################</tt> </tt>
+<a name="L1543"></a><tt class="py-lineno">1543</tt> <tt class="py-line"> </tt>
+<a name="html_to_xhtml"></a><div id="html_to_xhtml-def"><a name="L1544"></a><tt class="py-lineno">1544</tt> <a class="py-toggle" href="#" id="html_to_xhtml-toggle" onclick="return toggle('html_to_xhtml');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#html_to_xhtml">html_to_xhtml</a><tt class="py-op">(</tt><tt class="py-param">html</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="html_to_xhtml-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="html_to_xhtml-expanded"><a name="L1545"></a><tt class="py-lineno">1545</tt> <tt class="py-line"> <tt class="py-docstring">"""Convert all tags in an HTML tree to XHTML by moving them to the</tt> </tt>
+<a name="L1546"></a><tt class="py-lineno">1546</tt> <tt class="py-line"><tt class="py-docstring"> XHTML namespace.</tt> </tt>
+<a name="L1547"></a><tt class="py-lineno">1547</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1548"></a><tt class="py-lineno">1548</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
+<a name="L1549"></a><tt class="py-lineno">1549</tt> <tt class="py-line"> <tt id="link-906" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-903', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt id="link-904" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-906', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt id="link-907" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-904', 'html', 'link-5');">html</a></tt><tt class="py-op">.</tt><tt id="link-905" class="py-name" targets="Method lxml.etree._ElementTree.getroot()=lxml.etree._ElementTree-class.html#getroot"><a title="lxml.etree._ElementTree.getroot" class="py-name" href="#" onclick="return doclink('link-905', 'getroot', 'link-905');">getroot</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1549"></a><tt class="py-lineno">1549</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">:</tt> </tt>
-<a name="L1550"></a><tt class="py-lineno">1550</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
-<a name="L1551"></a><tt class="py-lineno">1551</tt> <tt class="py-line"> <tt id="link-906" class="py-name" targets="Variable lxml.etree._Element.prefix=lxml.etree._Element-class.html#prefix"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-906', 'prefix', 'link-906');">prefix</a></tt> <tt class="py-op">=</tt> <tt class="py-string">"{%s}"</tt> <tt class="py-op">%</tt> <tt id="link-907" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-907', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt> </tt>
-<a name="L1552"></a><tt class="py-lineno">1552</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-908" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-907', 'html', 'link-5');">html</a></tt><tt class="py-op">.</tt><tt id="link-908" class="py-name" targets="Method lxml.etree._ElementTree.getroot()=lxml.etree._ElementTree-class.html#getroot"><a title="lxml.etree._ElementTree.getroot" class="py-name" href="#" onclick="return doclink('link-908', 'getroot', 'link-908');">getroot</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1550"></a><tt class="py-lineno">1550</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">:</tt> </tt>
+<a name="L1551"></a><tt class="py-lineno">1551</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
+<a name="L1552"></a><tt class="py-lineno">1552</tt> <tt class="py-line"> <tt id="link-909" class="py-name" targets="Variable lxml.etree._Element.prefix=lxml.etree._Element-class.html#prefix"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-909', 'prefix', 'link-909');">prefix</a></tt> <tt class="py-op">=</tt> <tt class="py-string">"{%s}"</tt> <tt class="py-op">%</tt> <tt id="link-910" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-910', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt> </tt>
+<a name="L1553"></a><tt class="py-lineno">1553</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt id="link-911" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-908', 'html', 'link-5');">html</a></tt><tt class="py-op">.</tt><tt id="link-909" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-909', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt id="link-910" class="py-name"><a title="lxml.etree
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-911', 'html', 'link-5');">html</a></tt><tt class="py-op">.</tt><tt id="link-912" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-912', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt id="link-913" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-910', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-911" class="py-name"><a title="lxml.etree.Element
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-913', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-914" class="py-name"><a title="lxml.etree.Element
lxml.objectify.Element
lxml.tests.test_pyclasslookup.PyClassLookupTestCase.Element
-xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-911', 'Element', 'link-164');">Element</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1553"></a><tt class="py-lineno">1553</tt> <tt class="py-line"> <tt id="link-912" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element" class="py-name" href="#" onclick="return doclink('link-914', 'Element', 'link-165');">Element</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1554"></a><tt class="py-lineno">1554</tt> <tt class="py-line"> <tt id="link-915" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-912', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-913" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-915', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-916" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-913', 'tag', 'link-48');">tag</a></tt> </tt>
-<a name="L1554"></a><tt class="py-lineno">1554</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-914" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-916', 'tag', 'link-49');">tag</a></tt> </tt>
+<a name="L1555"></a><tt class="py-lineno">1555</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-917" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-914', 'tag', 'link-48');">tag</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> <tt class="py-op">!=</tt> <tt class="py-string">'{'</tt><tt class="py-op">:</tt> </tt>
-<a name="L1555"></a><tt class="py-lineno">1555</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-915" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-917', 'tag', 'link-49');">tag</a></tt><tt class="py-op">[</tt><tt class="py-number">0</tt><tt class="py-op">]</tt> <tt class="py-op">!=</tt> <tt class="py-string">'{'</tt><tt class="py-op">:</tt> </tt>
+<a name="L1556"></a><tt class="py-lineno">1556</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-918" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-915', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">=</tt> <tt id="link-916" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-916', 'prefix', 'link-906');">prefix</a></tt> <tt class="py-op">+</tt> <tt id="link-917" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-918', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">=</tt> <tt id="link-919" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-919', 'prefix', 'link-909');">prefix</a></tt> <tt class="py-op">+</tt> <tt id="link-920" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-917', 'tag', 'link-48');">tag</a></tt> </tt>
-</div><a name="L1556"></a><tt class="py-lineno">1556</tt> <tt class="py-line"> </tt>
-<a name="xhtml_to_html"></a><div id="xhtml_to_html-def"><a name="L1557"></a><tt class="py-lineno">1557</tt> <a class="py-toggle" href="#" id="xhtml_to_html-toggle" onclick="return toggle('xhtml_to_html');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#xhtml_to_html">xhtml_to_html</a><tt class="py-op">(</tt><tt class="py-param">xhtml</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="xhtml_to_html-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="xhtml_to_html-expanded"><a name="L1558"></a><tt class="py-lineno">1558</tt> <tt class="py-line"> <tt class="py-docstring">"""Convert all tags in an XHTML tree to HTML by removing their</tt> </tt>
-<a name="L1559"></a><tt class="py-lineno">1559</tt> <tt class="py-line"><tt class="py-docstring"> XHTML namespace.</tt> </tt>
-<a name="L1560"></a><tt class="py-lineno">1560</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1561"></a><tt class="py-lineno">1561</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
-<a name="L1562"></a><tt class="py-lineno">1562</tt> <tt class="py-line"> <tt class="py-name">xhtml</tt> <tt class="py-op">=</tt> <tt class="py-name">xhtml</tt><tt class="py-op">.</tt><tt id="link-918" class="py-name"><a title="lxml.etree._ElementTree.getroot" class="py-name" href="#" onclick="return doclink('link-918', 'getroot', 'link-905');">getroot</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1563"></a><tt class="py-lineno">1563</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">:</tt> </tt>
-<a name="L1564"></a><tt class="py-lineno">1564</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
-<a name="L1565"></a><tt class="py-lineno">1565</tt> <tt class="py-line"> <tt id="link-919" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-919', 'prefix', 'link-906');">prefix</a></tt> <tt class="py-op">=</tt> <tt class="py-string">"{%s}"</tt> <tt class="py-op">%</tt> <tt id="link-920" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-920', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt> </tt>
-<a name="L1566"></a><tt class="py-lineno">1566</tt> <tt class="py-line"> <tt class="py-name">prefix_len</tt> <tt class="py-op">=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-921" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-921', 'prefix', 'link-906');">prefix</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1567"></a><tt class="py-lineno">1567</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">xhtml</tt><tt class="py-op">.</tt><tt id="link-922" class="py-name"><a title="lxml.etree._Element.iter
-lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-922', 'iter', 'link-162');">iter</a></tt><tt class="py-op">(</tt><tt id="link-923" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-923', 'prefix', 'link-906');">prefix</a></tt> <tt class="py-op">+</tt> <tt class="py-string">"*"</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1568"></a><tt class="py-lineno">1568</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-924" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-920', 'tag', 'link-49');">tag</a></tt> </tt>
+</div><a name="L1557"></a><tt class="py-lineno">1557</tt> <tt class="py-line"> </tt>
+<a name="xhtml_to_html"></a><div id="xhtml_to_html-def"><a name="L1558"></a><tt class="py-lineno">1558</tt> <a class="py-toggle" href="#" id="xhtml_to_html-toggle" onclick="return toggle('xhtml_to_html');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#xhtml_to_html">xhtml_to_html</a><tt class="py-op">(</tt><tt class="py-param">xhtml</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="xhtml_to_html-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="xhtml_to_html-expanded"><a name="L1559"></a><tt class="py-lineno">1559</tt> <tt class="py-line"> <tt class="py-docstring">"""Convert all tags in an XHTML tree to HTML by removing their</tt> </tt>
+<a name="L1560"></a><tt class="py-lineno">1560</tt> <tt class="py-line"><tt class="py-docstring"> XHTML namespace.</tt> </tt>
+<a name="L1561"></a><tt class="py-lineno">1561</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1562"></a><tt class="py-lineno">1562</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
+<a name="L1563"></a><tt class="py-lineno">1563</tt> <tt class="py-line"> <tt class="py-name">xhtml</tt> <tt class="py-op">=</tt> <tt class="py-name">xhtml</tt><tt class="py-op">.</tt><tt id="link-921" class="py-name"><a title="lxml.etree._ElementTree.getroot" class="py-name" href="#" onclick="return doclink('link-921', 'getroot', 'link-908');">getroot</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1564"></a><tt class="py-lineno">1564</tt> <tt class="py-line"> <tt class="py-keyword">except</tt> <tt class="py-name">AttributeError</tt><tt class="py-op">:</tt> </tt>
+<a name="L1565"></a><tt class="py-lineno">1565</tt> <tt class="py-line"> <tt class="py-keyword">pass</tt> </tt>
+<a name="L1566"></a><tt class="py-lineno">1566</tt> <tt class="py-line"> <tt id="link-922" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-922', 'prefix', 'link-909');">prefix</a></tt> <tt class="py-op">=</tt> <tt class="py-string">"{%s}"</tt> <tt class="py-op">%</tt> <tt id="link-923" class="py-name"><a title="lxml.html.XHTML_NAMESPACE" class="py-name" href="#" onclick="return doclink('link-923', 'XHTML_NAMESPACE', 'link-16');">XHTML_NAMESPACE</a></tt> </tt>
+<a name="L1567"></a><tt class="py-lineno">1567</tt> <tt class="py-line"> <tt class="py-name">prefix_len</tt> <tt class="py-op">=</tt> <tt class="py-name">len</tt><tt class="py-op">(</tt><tt id="link-924" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-924', 'prefix', 'link-909');">prefix</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1568"></a><tt class="py-lineno">1568</tt> <tt class="py-line"> <tt class="py-keyword">for</tt> <tt class="py-name">el</tt> <tt class="py-keyword">in</tt> <tt class="py-name">xhtml</tt><tt class="py-op">.</tt><tt id="link-925" class="py-name"><a title="lxml.etree._Element.iter
+lxml.etree._ElementTree.iter" class="py-name" href="#" onclick="return doclink('link-925', 'iter', 'link-163');">iter</a></tt><tt class="py-op">(</tt><tt id="link-926" class="py-name"><a title="lxml.etree._Element.prefix" class="py-name" href="#" onclick="return doclink('link-926', 'prefix', 'link-909');">prefix</a></tt> <tt class="py-op">+</tt> <tt class="py-string">"*"</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1569"></a><tt class="py-lineno">1569</tt> <tt class="py-line"> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-927" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-924', 'tag', 'link-48');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-925" class="py-name"><a title="lxml.etree._Comment.tag
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-927', 'tag', 'link-49');">tag</a></tt> <tt class="py-op">=</tt> <tt class="py-name">el</tt><tt class="py-op">.</tt><tt id="link-928" class="py-name"><a title="lxml.etree._Comment.tag
lxml.etree._Element.tag
lxml.etree._Entity.tag
lxml.etree._ProcessingInstruction.tag
lxml.tests.test_xpathevaluator.tag
-xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-925', 'tag', 'link-48');">tag</a></tt><tt class="py-op">[</tt><tt class="py-name">prefix_len</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
-</div><a name="L1569"></a><tt class="py-lineno">1569</tt> <tt class="py-line"> </tt>
-<a name="L1570"></a><tt class="py-lineno">1570</tt> <tt class="py-line"><tt class="py-comment"># This isn't a general match, but it's a match for what libxml2</tt> </tt>
-<a name="L1571"></a><tt class="py-lineno">1571</tt> <tt class="py-line"><tt class="py-comment"># specifically serialises:</tt> </tt>
-<a name="L1572"></a><tt class="py-lineno">1572</tt> <tt class="py-line"><tt class="py-name">__str_replace_meta_content_type</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
-<a name="L1573"></a><tt class="py-lineno">1573</tt> <tt class="py-line"> <tt class="py-string">r'<meta http-equiv="Content-Type"[^>]*>'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">sub</tt> </tt>
-<a name="L1574"></a><tt class="py-lineno">1574</tt> <tt class="py-line"><tt class="py-name">__bytes_replace_meta_content_type</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
-<a name="L1575"></a><tt class="py-lineno">1575</tt> <tt class="py-line"> <tt class="py-string">r'<meta http-equiv="Content-Type"[^>]*>'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ASCII'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">sub</tt> </tt>
-<a name="L1576"></a><tt class="py-lineno">1576</tt> <tt class="py-line"> </tt>
-<a name="tostring"></a><div id="tostring-def"><a name="L1577"></a><tt class="py-lineno">1577</tt> <a class="py-toggle" href="#" id="tostring-toggle" onclick="return toggle('tostring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#tostring">tostring</a><tt class="py-op">(</tt><tt class="py-param">doc</tt><tt class="py-op">,</tt> <tt class="py-param">pretty_print</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">include_meta_content_type</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> </tt>
-<a name="L1578"></a><tt class="py-lineno">1578</tt> <tt class="py-line"> <tt class="py-param">encoding</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">method</tt><tt class="py-op">=</tt><tt class="py-string">"html"</tt><tt class="py-op">,</tt> <tt class="py-param">with_tail</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> <tt class="py-param">doctype</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="tostring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="tostring-expanded"><a name="L1579"></a><tt class="py-lineno">1579</tt> <tt class="py-line"> <tt class="py-docstring">"""Return an HTML string representation of the document.</tt> </tt>
-<a name="L1580"></a><tt class="py-lineno">1580</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1581"></a><tt class="py-lineno">1581</tt> <tt class="py-line"><tt class="py-docstring"> Note: if include_meta_content_type is true this will create a</tt> </tt>
-<a name="L1582"></a><tt class="py-lineno">1582</tt> <tt class="py-line"><tt class="py-docstring"> ``<meta http-equiv="Content-Type" ...>`` tag in the head;</tt> </tt>
-<a name="L1583"></a><tt class="py-lineno">1583</tt> <tt class="py-line"><tt class="py-docstring"> regardless of the value of include_meta_content_type any existing</tt> </tt>
-<a name="L1584"></a><tt class="py-lineno">1584</tt> <tt class="py-line"><tt class="py-docstring"> ``<meta http-equiv="Content-Type" ...>`` tag will be removed</tt> </tt>
-<a name="L1585"></a><tt class="py-lineno">1585</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1586"></a><tt class="py-lineno">1586</tt> <tt class="py-line"><tt class="py-docstring"> The ``encoding`` argument controls the output encoding (defauts to</tt> </tt>
-<a name="L1587"></a><tt class="py-lineno">1587</tt> <tt class="py-line"><tt class="py-docstring"> ASCII, with &#...; character references for any characters outside</tt> </tt>
-<a name="L1588"></a><tt class="py-lineno">1588</tt> <tt class="py-line"><tt class="py-docstring"> of ASCII). Note that you can pass the name ``'unicode'`` as</tt> </tt>
-<a name="L1589"></a><tt class="py-lineno">1589</tt> <tt class="py-line"><tt class="py-docstring"> ``encoding`` argument to serialise to a Unicode string.</tt> </tt>
-<a name="L1590"></a><tt class="py-lineno">1590</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1591"></a><tt class="py-lineno">1591</tt> <tt class="py-line"><tt class="py-docstring"> The ``method`` argument defines the output method. It defaults to</tt> </tt>
-<a name="L1592"></a><tt class="py-lineno">1592</tt> <tt class="py-line"><tt class="py-docstring"> 'html', but can also be 'xml' for xhtml output, or 'text' to</tt> </tt>
-<a name="L1593"></a><tt class="py-lineno">1593</tt> <tt class="py-line"><tt class="py-docstring"> serialise to plain text without markup.</tt> </tt>
-<a name="L1594"></a><tt class="py-lineno">1594</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1595"></a><tt class="py-lineno">1595</tt> <tt class="py-line"><tt class="py-docstring"> To leave out the tail text of the top-level element that is being</tt> </tt>
-<a name="L1596"></a><tt class="py-lineno">1596</tt> <tt class="py-line"><tt class="py-docstring"> serialised, pass ``with_tail=False``.</tt> </tt>
-<a name="L1597"></a><tt class="py-lineno">1597</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1598"></a><tt class="py-lineno">1598</tt> <tt class="py-line"><tt class="py-docstring"> The ``doctype`` option allows passing in a plain string that will</tt> </tt>
-<a name="L1599"></a><tt class="py-lineno">1599</tt> <tt class="py-line"><tt class="py-docstring"> be serialised before the XML tree. Note that passing in non</tt> </tt>
-<a name="L1600"></a><tt class="py-lineno">1600</tt> <tt class="py-line"><tt class="py-docstring"> well-formed content here will make the XML output non well-formed.</tt> </tt>
-<a name="L1601"></a><tt class="py-lineno">1601</tt> <tt class="py-line"><tt class="py-docstring"> Also, an existing doctype in the document tree will not be removed</tt> </tt>
-<a name="L1602"></a><tt class="py-lineno">1602</tt> <tt class="py-line"><tt class="py-docstring"> when serialising an ElementTree instance.</tt> </tt>
-<a name="L1603"></a><tt class="py-lineno">1603</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1604"></a><tt class="py-lineno">1604</tt> <tt class="py-line"><tt class="py-docstring"> Example::</tt> </tt>
-<a name="L1605"></a><tt class="py-lineno">1605</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1606"></a><tt class="py-lineno">1606</tt> <tt class="py-line"><tt class="py-docstring"> >>> from lxml import html</tt> </tt>
-<a name="L1607"></a><tt class="py-lineno">1607</tt> <tt class="py-line"><tt class="py-docstring"> >>> root = html.fragment_fromstring('<p>Hello<br>world!</p>')</tt> </tt>
-<a name="L1608"></a><tt class="py-lineno">1608</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1609"></a><tt class="py-lineno">1609</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root)</tt> </tt>
-<a name="L1610"></a><tt class="py-lineno">1610</tt> <tt class="py-line"><tt class="py-docstring"> b'<p>Hello<br>world!</p>'</tt> </tt>
-<a name="L1611"></a><tt class="py-lineno">1611</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='html')</tt> </tt>
-<a name="L1612"></a><tt class="py-lineno">1612</tt> <tt class="py-line"><tt class="py-docstring"> b'<p>Hello<br>world!</p>'</tt> </tt>
-<a name="L1613"></a><tt class="py-lineno">1613</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1614"></a><tt class="py-lineno">1614</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='xml')</tt> </tt>
-<a name="L1615"></a><tt class="py-lineno">1615</tt> <tt class="py-line"><tt class="py-docstring"> b'<p>Hello<br/>world!</p>'</tt> </tt>
-<a name="L1616"></a><tt class="py-lineno">1616</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1617"></a><tt class="py-lineno">1617</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='text')</tt> </tt>
-<a name="L1618"></a><tt class="py-lineno">1618</tt> <tt class="py-line"><tt class="py-docstring"> b'Helloworld!'</tt> </tt>
-<a name="L1619"></a><tt class="py-lineno">1619</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1620"></a><tt class="py-lineno">1620</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='text', encoding='unicode')</tt> </tt>
-<a name="L1621"></a><tt class="py-lineno">1621</tt> <tt class="py-line"><tt class="py-docstring"> u'Helloworld!'</tt> </tt>
-<a name="L1622"></a><tt class="py-lineno">1622</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1623"></a><tt class="py-lineno">1623</tt> <tt class="py-line"><tt class="py-docstring"> >>> root = html.fragment_fromstring('<div><p>Hello<br>world!</p>TAIL</div>')</tt> </tt>
-<a name="L1624"></a><tt class="py-lineno">1624</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root[0], method='text', encoding='unicode')</tt> </tt>
-<a name="L1625"></a><tt class="py-lineno">1625</tt> <tt class="py-line"><tt class="py-docstring"> u'Helloworld!TAIL'</tt> </tt>
-<a name="L1626"></a><tt class="py-lineno">1626</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1627"></a><tt class="py-lineno">1627</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root[0], method='text', encoding='unicode', with_tail=False)</tt> </tt>
-<a name="L1628"></a><tt class="py-lineno">1628</tt> <tt class="py-line"><tt class="py-docstring"> u'Helloworld!'</tt> </tt>
-<a name="L1629"></a><tt class="py-lineno">1629</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1630"></a><tt class="py-lineno">1630</tt> <tt class="py-line"><tt class="py-docstring"> >>> doc = html.document_fromstring('<p>Hello<br>world!</p>')</tt> </tt>
-<a name="L1631"></a><tt class="py-lineno">1631</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(doc, method='html', encoding='unicode')</tt> </tt>
-<a name="L1632"></a><tt class="py-lineno">1632</tt> <tt class="py-line"><tt class="py-docstring"> u'<html><body><p>Hello<br>world!</p></body></html>'</tt> </tt>
-<a name="L1633"></a><tt class="py-lineno">1633</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1634"></a><tt class="py-lineno">1634</tt> <tt class="py-line"><tt class="py-docstring"> >>> print(html.tostring(doc, method='html', encoding='unicode',</tt> </tt>
-<a name="L1635"></a><tt class="py-lineno">1635</tt> <tt class="py-line"><tt class="py-docstring"> ... doctype='<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"'</tt> </tt>
-<a name="L1636"></a><tt class="py-lineno">1636</tt> <tt class="py-line"><tt class="py-docstring"> ... ' "http://www.w3.org/TR/html4/strict.dtd">'))</tt> </tt>
-<a name="L1637"></a><tt class="py-lineno">1637</tt> <tt class="py-line"><tt class="py-docstring"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"></tt> </tt>
-<a name="L1638"></a><tt class="py-lineno">1638</tt> <tt class="py-line"><tt class="py-docstring"> <html><body><p>Hello<br>world!</p></body></html></tt> </tt>
-<a name="L1639"></a><tt class="py-lineno">1639</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1640"></a><tt class="py-lineno">1640</tt> <tt class="py-line"> <tt id="link-926" class="py-name"><a title="lxml.html
+xml.etree.ElementTree.Element.tag" class="py-name" href="#" onclick="return doclink('link-928', 'tag', 'link-49');">tag</a></tt><tt class="py-op">[</tt><tt class="py-name">prefix_len</tt><tt class="py-op">:</tt><tt class="py-op">]</tt> </tt>
+</div><a name="L1570"></a><tt class="py-lineno">1570</tt> <tt class="py-line"> </tt>
+<a name="L1571"></a><tt class="py-lineno">1571</tt> <tt class="py-line"><tt class="py-comment"># This isn't a general match, but it's a match for what libxml2</tt> </tt>
+<a name="L1572"></a><tt class="py-lineno">1572</tt> <tt class="py-line"><tt class="py-comment"># specifically serialises:</tt> </tt>
+<a name="L1573"></a><tt class="py-lineno">1573</tt> <tt class="py-line"><tt class="py-name">__str_replace_meta_content_type</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
+<a name="L1574"></a><tt class="py-lineno">1574</tt> <tt class="py-line"> <tt class="py-string">r'<meta http-equiv="Content-Type"[^>]*>'</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">sub</tt> </tt>
+<a name="L1575"></a><tt class="py-lineno">1575</tt> <tt class="py-line"><tt class="py-name">__bytes_replace_meta_content_type</tt> <tt class="py-op">=</tt> <tt class="py-name">re</tt><tt class="py-op">.</tt><tt class="py-name">compile</tt><tt class="py-op">(</tt> </tt>
+<a name="L1576"></a><tt class="py-lineno">1576</tt> <tt class="py-line"> <tt class="py-string">r'<meta http-equiv="Content-Type"[^>]*>'</tt><tt class="py-op">.</tt><tt class="py-name">encode</tt><tt class="py-op">(</tt><tt class="py-string">'ASCII'</tt><tt class="py-op">)</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt class="py-name">sub</tt> </tt>
+<a name="L1577"></a><tt class="py-lineno">1577</tt> <tt class="py-line"> </tt>
+<a name="tostring"></a><div id="tostring-def"><a name="L1578"></a><tt class="py-lineno">1578</tt> <a class="py-toggle" href="#" id="tostring-toggle" onclick="return toggle('tostring');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#tostring">tostring</a><tt class="py-op">(</tt><tt class="py-param">doc</tt><tt class="py-op">,</tt> <tt class="py-param">pretty_print</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> <tt class="py-param">include_meta_content_type</tt><tt class="py-op">=</tt><tt class="py-name">False</tt><tt class="py-op">,</tt> </tt>
+<a name="L1579"></a><tt class="py-lineno">1579</tt> <tt class="py-line"> <tt class="py-param">encoding</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">,</tt> <tt class="py-param">method</tt><tt class="py-op">=</tt><tt class="py-string">"html"</tt><tt class="py-op">,</tt> <tt class="py-param">with_tail</tt><tt class="py-op">=</tt><tt class="py-name">True</tt><tt class="py-op">,</tt> <tt class="py-param">doctype</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="tostring-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="tostring-expanded"><a name="L1580"></a><tt class="py-lineno">1580</tt> <tt class="py-line"> <tt class="py-docstring">"""Return an HTML string representation of the document.</tt> </tt>
+<a name="L1581"></a><tt class="py-lineno">1581</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1582"></a><tt class="py-lineno">1582</tt> <tt class="py-line"><tt class="py-docstring"> Note: if include_meta_content_type is true this will create a</tt> </tt>
+<a name="L1583"></a><tt class="py-lineno">1583</tt> <tt class="py-line"><tt class="py-docstring"> ``<meta http-equiv="Content-Type" ...>`` tag in the head;</tt> </tt>
+<a name="L1584"></a><tt class="py-lineno">1584</tt> <tt class="py-line"><tt class="py-docstring"> regardless of the value of include_meta_content_type any existing</tt> </tt>
+<a name="L1585"></a><tt class="py-lineno">1585</tt> <tt class="py-line"><tt class="py-docstring"> ``<meta http-equiv="Content-Type" ...>`` tag will be removed</tt> </tt>
+<a name="L1586"></a><tt class="py-lineno">1586</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1587"></a><tt class="py-lineno">1587</tt> <tt class="py-line"><tt class="py-docstring"> The ``encoding`` argument controls the output encoding (defauts to</tt> </tt>
+<a name="L1588"></a><tt class="py-lineno">1588</tt> <tt class="py-line"><tt class="py-docstring"> ASCII, with &#...; character references for any characters outside</tt> </tt>
+<a name="L1589"></a><tt class="py-lineno">1589</tt> <tt class="py-line"><tt class="py-docstring"> of ASCII). Note that you can pass the name ``'unicode'`` as</tt> </tt>
+<a name="L1590"></a><tt class="py-lineno">1590</tt> <tt class="py-line"><tt class="py-docstring"> ``encoding`` argument to serialise to a Unicode string.</tt> </tt>
+<a name="L1591"></a><tt class="py-lineno">1591</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1592"></a><tt class="py-lineno">1592</tt> <tt class="py-line"><tt class="py-docstring"> The ``method`` argument defines the output method. It defaults to</tt> </tt>
+<a name="L1593"></a><tt class="py-lineno">1593</tt> <tt class="py-line"><tt class="py-docstring"> 'html', but can also be 'xml' for xhtml output, or 'text' to</tt> </tt>
+<a name="L1594"></a><tt class="py-lineno">1594</tt> <tt class="py-line"><tt class="py-docstring"> serialise to plain text without markup.</tt> </tt>
+<a name="L1595"></a><tt class="py-lineno">1595</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1596"></a><tt class="py-lineno">1596</tt> <tt class="py-line"><tt class="py-docstring"> To leave out the tail text of the top-level element that is being</tt> </tt>
+<a name="L1597"></a><tt class="py-lineno">1597</tt> <tt class="py-line"><tt class="py-docstring"> serialised, pass ``with_tail=False``.</tt> </tt>
+<a name="L1598"></a><tt class="py-lineno">1598</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1599"></a><tt class="py-lineno">1599</tt> <tt class="py-line"><tt class="py-docstring"> The ``doctype`` option allows passing in a plain string that will</tt> </tt>
+<a name="L1600"></a><tt class="py-lineno">1600</tt> <tt class="py-line"><tt class="py-docstring"> be serialised before the XML tree. Note that passing in non</tt> </tt>
+<a name="L1601"></a><tt class="py-lineno">1601</tt> <tt class="py-line"><tt class="py-docstring"> well-formed content here will make the XML output non well-formed.</tt> </tt>
+<a name="L1602"></a><tt class="py-lineno">1602</tt> <tt class="py-line"><tt class="py-docstring"> Also, an existing doctype in the document tree will not be removed</tt> </tt>
+<a name="L1603"></a><tt class="py-lineno">1603</tt> <tt class="py-line"><tt class="py-docstring"> when serialising an ElementTree instance.</tt> </tt>
+<a name="L1604"></a><tt class="py-lineno">1604</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1605"></a><tt class="py-lineno">1605</tt> <tt class="py-line"><tt class="py-docstring"> Example::</tt> </tt>
+<a name="L1606"></a><tt class="py-lineno">1606</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1607"></a><tt class="py-lineno">1607</tt> <tt class="py-line"><tt class="py-docstring"> >>> from lxml import html</tt> </tt>
+<a name="L1608"></a><tt class="py-lineno">1608</tt> <tt class="py-line"><tt class="py-docstring"> >>> root = html.fragment_fromstring('<p>Hello<br>world!</p>')</tt> </tt>
+<a name="L1609"></a><tt class="py-lineno">1609</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1610"></a><tt class="py-lineno">1610</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root)</tt> </tt>
+<a name="L1611"></a><tt class="py-lineno">1611</tt> <tt class="py-line"><tt class="py-docstring"> b'<p>Hello<br>world!</p>'</tt> </tt>
+<a name="L1612"></a><tt class="py-lineno">1612</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='html')</tt> </tt>
+<a name="L1613"></a><tt class="py-lineno">1613</tt> <tt class="py-line"><tt class="py-docstring"> b'<p>Hello<br>world!</p>'</tt> </tt>
+<a name="L1614"></a><tt class="py-lineno">1614</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1615"></a><tt class="py-lineno">1615</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='xml')</tt> </tt>
+<a name="L1616"></a><tt class="py-lineno">1616</tt> <tt class="py-line"><tt class="py-docstring"> b'<p>Hello<br/>world!</p>'</tt> </tt>
+<a name="L1617"></a><tt class="py-lineno">1617</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1618"></a><tt class="py-lineno">1618</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='text')</tt> </tt>
+<a name="L1619"></a><tt class="py-lineno">1619</tt> <tt class="py-line"><tt class="py-docstring"> b'Helloworld!'</tt> </tt>
+<a name="L1620"></a><tt class="py-lineno">1620</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1621"></a><tt class="py-lineno">1621</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root, method='text', encoding='unicode')</tt> </tt>
+<a name="L1622"></a><tt class="py-lineno">1622</tt> <tt class="py-line"><tt class="py-docstring"> u'Helloworld!'</tt> </tt>
+<a name="L1623"></a><tt class="py-lineno">1623</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1624"></a><tt class="py-lineno">1624</tt> <tt class="py-line"><tt class="py-docstring"> >>> root = html.fragment_fromstring('<div><p>Hello<br>world!</p>TAIL</div>')</tt> </tt>
+<a name="L1625"></a><tt class="py-lineno">1625</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root[0], method='text', encoding='unicode')</tt> </tt>
+<a name="L1626"></a><tt class="py-lineno">1626</tt> <tt class="py-line"><tt class="py-docstring"> u'Helloworld!TAIL'</tt> </tt>
+<a name="L1627"></a><tt class="py-lineno">1627</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1628"></a><tt class="py-lineno">1628</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(root[0], method='text', encoding='unicode', with_tail=False)</tt> </tt>
+<a name="L1629"></a><tt class="py-lineno">1629</tt> <tt class="py-line"><tt class="py-docstring"> u'Helloworld!'</tt> </tt>
+<a name="L1630"></a><tt class="py-lineno">1630</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1631"></a><tt class="py-lineno">1631</tt> <tt class="py-line"><tt class="py-docstring"> >>> doc = html.document_fromstring('<p>Hello<br>world!</p>')</tt> </tt>
+<a name="L1632"></a><tt class="py-lineno">1632</tt> <tt class="py-line"><tt class="py-docstring"> >>> html.tostring(doc, method='html', encoding='unicode')</tt> </tt>
+<a name="L1633"></a><tt class="py-lineno">1633</tt> <tt class="py-line"><tt class="py-docstring"> u'<html><body><p>Hello<br>world!</p></body></html>'</tt> </tt>
+<a name="L1634"></a><tt class="py-lineno">1634</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1635"></a><tt class="py-lineno">1635</tt> <tt class="py-line"><tt class="py-docstring"> >>> print(html.tostring(doc, method='html', encoding='unicode',</tt> </tt>
+<a name="L1636"></a><tt class="py-lineno">1636</tt> <tt class="py-line"><tt class="py-docstring"> ... doctype='<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"'</tt> </tt>
+<a name="L1637"></a><tt class="py-lineno">1637</tt> <tt class="py-line"><tt class="py-docstring"> ... ' "http://www.w3.org/TR/html4/strict.dtd">'))</tt> </tt>
+<a name="L1638"></a><tt class="py-lineno">1638</tt> <tt class="py-line"><tt class="py-docstring"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"></tt> </tt>
+<a name="L1639"></a><tt class="py-lineno">1639</tt> <tt class="py-line"><tt class="py-docstring"> <html><body><p>Hello<br>world!</p></body></html></tt> </tt>
+<a name="L1640"></a><tt class="py-lineno">1640</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1641"></a><tt class="py-lineno">1641</tt> <tt class="py-line"> <tt id="link-929" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-926', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt id="link-927" class="py-name"><a title="lxml.etree
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-929', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt id="link-930" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-927', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-928" class="py-name"><a title="lxml.etree.XSLT.tostring
-lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-928', 'tostring', 'link-44');">tostring</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt id="link-929" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-929', 'method', 'link-561');">method</a></tt><tt class="py-op">=</tt><tt id="link-930" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-930', 'method', 'link-561');">method</a></tt><tt class="py-op">,</tt> <tt class="py-name">pretty_print</tt><tt class="py-op">=</tt><tt class="py-name">pretty_print</tt><tt class="py-op">,</tt> </tt>
-<a name="L1641"></a><tt class="py-lineno">1641</tt> <tt class="py-line"> <tt id="link-931" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-931', 'encoding', 'link-45');">encoding</a></tt><tt class="py-op">=</tt><tt id="link-932" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-932', 'encoding', 'link-45');">encoding</a></tt><tt class="py-op">,</tt> <tt class="py-name">with_tail</tt><tt class="py-op">=</tt><tt class="py-name">with_tail</tt><tt class="py-op">,</tt> </tt>
-<a name="L1642"></a><tt class="py-lineno">1642</tt> <tt class="py-line"> <tt id="link-933" class="py-name" targets="Variable lxml.etree.DocInfo.doctype=lxml.etree.DocInfo-class.html#doctype"><a title="lxml.etree.DocInfo.doctype" class="py-name" href="#" onclick="return doclink('link-933', 'doctype', 'link-933');">doctype</a></tt><tt class="py-op">=</tt><tt id="link-934" class="py-name"><a title="lxml.etree.DocInfo.doctype" class="py-name" href="#" onclick="return doclink('link-934', 'doctype', 'link-933');">doctype</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1643"></a><tt class="py-lineno">1643</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-935" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-935', 'method', 'link-561');">method</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'html'</tt> <tt class="py-keyword">and</tt> <tt class="py-keyword">not</tt> <tt class="py-name">include_meta_content_type</tt><tt class="py-op">:</tt> </tt>
-<a name="L1644"></a><tt class="py-lineno">1644</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-936" class="py-name"><a title="lxml.html
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-930', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-931" class="py-name"><a title="lxml.etree.XSLT.tostring
+lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-931', 'tostring', 'link-45');">tostring</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt id="link-932" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-932', 'method', 'link-564');">method</a></tt><tt class="py-op">=</tt><tt id="link-933" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-933', 'method', 'link-564');">method</a></tt><tt class="py-op">,</tt> <tt class="py-name">pretty_print</tt><tt class="py-op">=</tt><tt class="py-name">pretty_print</tt><tt class="py-op">,</tt> </tt>
+<a name="L1642"></a><tt class="py-lineno">1642</tt> <tt class="py-line"> <tt id="link-934" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-934', 'encoding', 'link-46');">encoding</a></tt><tt class="py-op">=</tt><tt id="link-935" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-935', 'encoding', 'link-46');">encoding</a></tt><tt class="py-op">,</tt> <tt class="py-name">with_tail</tt><tt class="py-op">=</tt><tt class="py-name">with_tail</tt><tt class="py-op">,</tt> </tt>
+<a name="L1643"></a><tt class="py-lineno">1643</tt> <tt class="py-line"> <tt id="link-936" class="py-name" targets="Variable lxml.etree.DocInfo.doctype=lxml.etree.DocInfo-class.html#doctype"><a title="lxml.etree.DocInfo.doctype" class="py-name" href="#" onclick="return doclink('link-936', 'doctype', 'link-936');">doctype</a></tt><tt class="py-op">=</tt><tt id="link-937" class="py-name"><a title="lxml.etree.DocInfo.doctype" class="py-name" href="#" onclick="return doclink('link-937', 'doctype', 'link-936');">doctype</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1644"></a><tt class="py-lineno">1644</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt id="link-938" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-938', 'method', 'link-564');">method</a></tt> <tt class="py-op">==</tt> <tt class="py-string">'html'</tt> <tt class="py-keyword">and</tt> <tt class="py-keyword">not</tt> <tt class="py-name">include_meta_content_type</tt><tt class="py-op">:</tt> </tt>
+<a name="L1645"></a><tt class="py-lineno">1645</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt id="link-939" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-936', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-937" class="py-name"><a title="str" class="py-name" href="#" onclick="return doclink('link-937', 'str', 'link-11');">str</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1645"></a><tt class="py-lineno">1645</tt> <tt class="py-line"> <tt id="link-938" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-939', 'html', 'link-5');">html</a></tt><tt class="py-op">,</tt> <tt id="link-940" class="py-name"><a title="str" class="py-name" href="#" onclick="return doclink('link-940', 'str', 'link-11');">str</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1646"></a><tt class="py-lineno">1646</tt> <tt class="py-line"> <tt id="link-941" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-938', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-name">__str_replace_meta_content_type</tt><tt class="py-op">(</tt><tt class="py-string">''</tt><tt class="py-op">,</tt> <tt id="link-939" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-941', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-name">__str_replace_meta_content_type</tt><tt class="py-op">(</tt><tt class="py-string">''</tt><tt class="py-op">,</tt> <tt id="link-942" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-939', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1646"></a><tt class="py-lineno">1646</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
-<a name="L1647"></a><tt class="py-lineno">1647</tt> <tt class="py-line"> <tt id="link-940" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-942', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1647"></a><tt class="py-lineno">1647</tt> <tt class="py-line"> <tt class="py-keyword">else</tt><tt class="py-op">:</tt> </tt>
+<a name="L1648"></a><tt class="py-lineno">1648</tt> <tt class="py-line"> <tt id="link-943" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-940', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-name">__bytes_replace_meta_content_type</tt><tt class="py-op">(</tt><tt class="py-name">bytes</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt id="link-941" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-943', 'html', 'link-5');">html</a></tt> <tt class="py-op">=</tt> <tt class="py-name">__bytes_replace_meta_content_type</tt><tt class="py-op">(</tt><tt class="py-name">bytes</tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">,</tt> <tt id="link-944" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-941', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1648"></a><tt class="py-lineno">1648</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-942" class="py-name"><a title="lxml.html
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-944', 'html', 'link-5');">html</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1649"></a><tt class="py-lineno">1649</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-945" class="py-name"><a title="lxml.html
lxml.html.diff.href_token.html
lxml.html.diff.tag_token.html
-lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-942', 'html', 'link-5');">html</a></tt> </tt>
-</div><a name="L1649"></a><tt class="py-lineno">1649</tt> <tt class="py-line"> </tt>
-<a name="L1650"></a><tt class="py-lineno">1650</tt> <tt class="py-line"><tt id="link-943" class="py-name"><a title="lxml.etree.XSLT.tostring
-lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-943', 'tostring', 'link-44');">tostring</a></tt><tt class="py-op">.</tt><tt id="link-944" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-944', '__doc__', 'link-62');">__doc__</a></tt> <tt class="py-op">=</tt> <tt class="py-name">__fix_docstring</tt><tt class="py-op">(</tt><tt id="link-945" class="py-name"><a title="lxml.etree.XSLT.tostring
-lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-945', 'tostring', 'link-44');">tostring</a></tt><tt class="py-op">.</tt><tt id="link-946" class="py-name"><a title="lxml.html.ElementSoup.__doc__
-lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-946', '__doc__', 'link-62');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
-<a name="L1651"></a><tt class="py-lineno">1651</tt> <tt class="py-line"> </tt>
-<a name="open_in_browser"></a><div id="open_in_browser-def"><a name="L1652"></a><tt class="py-lineno">1652</tt> <a class="py-toggle" href="#" id="open_in_browser-toggle" onclick="return toggle('open_in_browser');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#open_in_browser">open_in_browser</a><tt class="py-op">(</tt><tt class="py-param">doc</tt><tt class="py-op">,</tt> <tt class="py-param">encoding</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="open_in_browser-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="open_in_browser-expanded"><a name="L1653"></a><tt class="py-lineno">1653</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
-<a name="L1654"></a><tt class="py-lineno">1654</tt> <tt class="py-line"><tt class="py-docstring"> Open the HTML document in a web browser, saving it to a temporary</tt> </tt>
-<a name="L1655"></a><tt class="py-lineno">1655</tt> <tt class="py-line"><tt class="py-docstring"> file to open it. Note that this does not delete the file after</tt> </tt>
-<a name="L1656"></a><tt class="py-lineno">1656</tt> <tt class="py-line"><tt class="py-docstring"> use. This is mainly meant for debugging.</tt> </tt>
-<a name="L1657"></a><tt class="py-lineno">1657</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1658"></a><tt class="py-lineno">1658</tt> <tt class="py-line"> <tt class="py-keyword">import</tt> <tt class="py-name">os</tt> </tt>
-<a name="L1659"></a><tt class="py-lineno">1659</tt> <tt class="py-line"> <tt class="py-keyword">import</tt> <tt class="py-name">webbrowser</tt> </tt>
-<a name="L1660"></a><tt class="py-lineno">1660</tt> <tt class="py-line"> <tt class="py-keyword">import</tt> <tt class="py-name">tempfile</tt> </tt>
-<a name="L1661"></a><tt class="py-lineno">1661</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt id="link-947" class="py-name"><a title="lxml.etree
+lxml.html.diff.token.html" class="py-name" href="#" onclick="return doclink('link-945', 'html', 'link-5');">html</a></tt> </tt>
+</div><a name="L1650"></a><tt class="py-lineno">1650</tt> <tt class="py-line"> </tt>
+<a name="L1651"></a><tt class="py-lineno">1651</tt> <tt class="py-line"><tt id="link-946" class="py-name"><a title="lxml.etree.XSLT.tostring
+lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-946', 'tostring', 'link-45');">tostring</a></tt><tt class="py-op">.</tt><tt id="link-947" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-947', '__doc__', 'link-63');">__doc__</a></tt> <tt class="py-op">=</tt> <tt class="py-name">__fix_docstring</tt><tt class="py-op">(</tt><tt id="link-948" class="py-name"><a title="lxml.etree.XSLT.tostring
+lxml.etree.tostring" class="py-name" href="#" onclick="return doclink('link-948', 'tostring', 'link-45');">tostring</a></tt><tt class="py-op">.</tt><tt id="link-949" class="py-name"><a title="lxml.html.ElementSoup.__doc__
+lxml.html.soupparser.__doc__" class="py-name" href="#" onclick="return doclink('link-949', '__doc__', 'link-63');">__doc__</a></tt><tt class="py-op">)</tt> </tt>
+<a name="L1652"></a><tt class="py-lineno">1652</tt> <tt class="py-line"> </tt>
+<a name="open_in_browser"></a><div id="open_in_browser-def"><a name="L1653"></a><tt class="py-lineno">1653</tt> <a class="py-toggle" href="#" id="open_in_browser-toggle" onclick="return toggle('open_in_browser');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#open_in_browser">open_in_browser</a><tt class="py-op">(</tt><tt class="py-param">doc</tt><tt class="py-op">,</tt> <tt class="py-param">encoding</tt><tt class="py-op">=</tt><tt class="py-name">None</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="open_in_browser-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="open_in_browser-expanded"><a name="L1654"></a><tt class="py-lineno">1654</tt> <tt class="py-line"> <tt class="py-docstring">"""</tt> </tt>
+<a name="L1655"></a><tt class="py-lineno">1655</tt> <tt class="py-line"><tt class="py-docstring"> Open the HTML document in a web browser, saving it to a temporary</tt> </tt>
+<a name="L1656"></a><tt class="py-lineno">1656</tt> <tt class="py-line"><tt class="py-docstring"> file to open it. Note that this does not delete the file after</tt> </tt>
+<a name="L1657"></a><tt class="py-lineno">1657</tt> <tt class="py-line"><tt class="py-docstring"> use. This is mainly meant for debugging.</tt> </tt>
+<a name="L1658"></a><tt class="py-lineno">1658</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1659"></a><tt class="py-lineno">1659</tt> <tt class="py-line"> <tt class="py-keyword">import</tt> <tt class="py-name">os</tt> </tt>
+<a name="L1660"></a><tt class="py-lineno">1660</tt> <tt class="py-line"> <tt class="py-keyword">import</tt> <tt class="py-name">webbrowser</tt> </tt>
+<a name="L1661"></a><tt class="py-lineno">1661</tt> <tt class="py-line"> <tt class="py-keyword">import</tt> <tt class="py-name">tempfile</tt> </tt>
+<a name="L1662"></a><tt class="py-lineno">1662</tt> <tt class="py-line"> <tt class="py-keyword">if</tt> <tt class="py-keyword">not</tt> <tt class="py-name">isinstance</tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">,</tt> <tt id="link-950" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-947', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-948" class="py-name" targets="Class lxml.etree._ElementTree=lxml.etree._ElementTree-class.html"><a title="lxml.etree._ElementTree" class="py-name" href="#" onclick="return doclink('link-948', '_ElementTree', 'link-948');">_ElementTree</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-<a name="L1662"></a><tt class="py-lineno">1662</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-949" class="py-name"><a title="lxml.etree
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-950', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-951" class="py-name" targets="Class lxml.etree._ElementTree=lxml.etree._ElementTree-class.html"><a title="lxml.etree._ElementTree" class="py-name" href="#" onclick="return doclink('link-951', '_ElementTree', 'link-951');">_ElementTree</a></tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+<a name="L1663"></a><tt class="py-lineno">1663</tt> <tt class="py-line"> <tt class="py-name">doc</tt> <tt class="py-op">=</tt> <tt id="link-952" class="py-name"><a title="lxml.etree
lxml.sax.ElementTreeContentHandler.etree
lxml.tests.test_elementtree.CElementTreeTestCase.etree
lxml.tests.test_elementtree._ETreeTestCaseBase.etree
lxml.tests.test_elementtree._XMLPullParserTest.etree
-lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-949', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-950" class="py-name" targets="Function lxml.etree.ElementTree()=lxml.etree-module.html#ElementTree,Module xml.etree.ElementTree=xml.etree.ElementTree-module.html,Class xml.etree.ElementTree.ElementTree=xml.etree.ElementTree.ElementTree-class.html"><a title="lxml.etree.ElementTree
+lxml.tests.test_io._IOTestCaseBase.etree" class="py-name" href="#" onclick="return doclink('link-952', 'etree', 'link-3');">etree</a></tt><tt class="py-op">.</tt><tt id="link-953" class="py-name" targets="Function lxml.etree.ElementTree()=lxml.etree-module.html#ElementTree,Module xml.etree.ElementTree=xml.etree.ElementTree-module.html,Class xml.etree.ElementTree.ElementTree=xml.etree.ElementTree.ElementTree-class.html"><a title="lxml.etree.ElementTree
xml.etree.ElementTree
-xml.etree.ElementTree.ElementTree" class="py-name" href="#" onclick="return doclink('link-950', 'ElementTree', 'link-950');">ElementTree</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
-<a name="L1663"></a><tt class="py-lineno">1663</tt> <tt class="py-line"> <tt id="link-951" class="py-name" targets="Method lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.ParseWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.ParseWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.ReverseWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.ReverseWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.RotateWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.RotateWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker-class.html#handle"><a title="lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker.handle
+xml.etree.ElementTree.ElementTree" class="py-name" href="#" onclick="return doclink('link-953', 'ElementTree', 'link-953');">ElementTree</a></tt><tt class="py-op">(</tt><tt class="py-name">doc</tt><tt class="py-op">)</tt> </tt>
+<a name="L1664"></a><tt class="py-lineno">1664</tt> <tt class="py-line"> <tt id="link-954" class="py-name" targets="Method lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.ParseWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.ParseWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.ReverseWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.ReverseWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.RotateWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.RotateWorker-class.html#handle,Method lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker.handle()=lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker-class.html#handle"><a title="lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker.handle
lxml.tests.test_threading.ThreadPipelineTestCase.ParseWorker.handle
lxml.tests.test_threading.ThreadPipelineTestCase.ReverseWorker.handle
lxml.tests.test_threading.ThreadPipelineTestCase.RotateWorker.handle
-lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker.handle" class="py-name" href="#" onclick="return doclink('link-951', 'handle', 'link-951');">handle</a></tt><tt class="py-op">,</tt> <tt class="py-name">fn</tt> <tt class="py-op">=</tt> <tt class="py-name">tempfile</tt><tt class="py-op">.</tt><tt class="py-name">mkstemp</tt><tt class="py-op">(</tt><tt class="py-name">suffix</tt><tt class="py-op">=</tt><tt class="py-string">'.html'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1664"></a><tt class="py-lineno">1664</tt> <tt class="py-line"> <tt class="py-name">f</tt> <tt class="py-op">=</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">fdopen</tt><tt class="py-op">(</tt><tt id="link-952" class="py-name"><a title="lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker.handle
+lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker.handle" class="py-name" href="#" onclick="return doclink('link-954', 'handle', 'link-954');">handle</a></tt><tt class="py-op">,</tt> <tt class="py-name">fn</tt> <tt class="py-op">=</tt> <tt class="py-name">tempfile</tt><tt class="py-op">.</tt><tt class="py-name">mkstemp</tt><tt class="py-op">(</tt><tt class="py-name">suffix</tt><tt class="py-op">=</tt><tt class="py-string">'.html'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1665"></a><tt class="py-lineno">1665</tt> <tt class="py-line"> <tt class="py-name">f</tt> <tt class="py-op">=</tt> <tt class="py-name">os</tt><tt class="py-op">.</tt><tt class="py-name">fdopen</tt><tt class="py-op">(</tt><tt id="link-955" class="py-name"><a title="lxml.tests.test_threading.ThreadPipelineTestCase.ParseAndExtendWorker.handle
lxml.tests.test_threading.ThreadPipelineTestCase.ParseWorker.handle
lxml.tests.test_threading.ThreadPipelineTestCase.ReverseWorker.handle
lxml.tests.test_threading.ThreadPipelineTestCase.RotateWorker.handle
-lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker.handle" class="py-name" href="#" onclick="return doclink('link-952', 'handle', 'link-951');">handle</a></tt><tt class="py-op">,</tt> <tt class="py-string">'wb'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1665"></a><tt class="py-lineno">1665</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
-<a name="L1666"></a><tt class="py-lineno">1666</tt> <tt class="py-line"> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-953" class="py-name" targets="Method lxml.etree._ElementTree.write()=lxml.etree._ElementTree-class.html#write"><a title="lxml.etree._ElementTree.write" class="py-name" href="#" onclick="return doclink('link-953', 'write', 'link-953');">write</a></tt><tt class="py-op">(</tt><tt class="py-name">f</tt><tt class="py-op">,</tt> <tt id="link-954" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-954', 'method', 'link-561');">method</a></tt><tt class="py-op">=</tt><tt class="py-string">"html"</tt><tt class="py-op">,</tt> <tt id="link-955" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-955', 'encoding', 'link-45');">encoding</a></tt><tt class="py-op">=</tt><tt id="link-956" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-956', 'encoding', 'link-45');">encoding</a></tt> <tt class="py-keyword">or</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-957" class="py-name"><a title="lxml.etree._ElementTree.docinfo" class="py-name" href="#" onclick="return doclink('link-957', 'docinfo', 'link-57');">docinfo</a></tt><tt class="py-op">.</tt><tt id="link-958" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-958', 'encoding', 'link-45');">encoding</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">"UTF-8"</tt><tt class="py-op">)</tt> </tt>
-<a name="L1667"></a><tt class="py-lineno">1667</tt> <tt class="py-line"> <tt class="py-keyword">finally</tt><tt class="py-op">:</tt> </tt>
-<a name="L1668"></a><tt class="py-lineno">1668</tt> <tt class="py-line"> <tt class="py-comment"># we leak the file itself here, but we should at least close it</tt> </tt>
-<a name="L1669"></a><tt class="py-lineno">1669</tt> <tt class="py-line"> <tt class="py-name">f</tt><tt class="py-op">.</tt><tt id="link-959" class="py-name" targets="Method lxml.etree.TreeBuilder.close()=lxml.etree.TreeBuilder-class.html#close,Method lxml.etree._FeedParser.close()=lxml.etree._FeedParser-class.html#close,Method lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.close()=lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike-class.html#close"><a title="lxml.etree.TreeBuilder.close
+lxml.tests.test_threading.ThreadPipelineTestCase.SerialiseWorker.handle" class="py-name" href="#" onclick="return doclink('link-955', 'handle', 'link-954');">handle</a></tt><tt class="py-op">,</tt> <tt class="py-string">'wb'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1666"></a><tt class="py-lineno">1666</tt> <tt class="py-line"> <tt class="py-keyword">try</tt><tt class="py-op">:</tt> </tt>
+<a name="L1667"></a><tt class="py-lineno">1667</tt> <tt class="py-line"> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-956" class="py-name" targets="Method lxml.etree._ElementTree.write()=lxml.etree._ElementTree-class.html#write"><a title="lxml.etree._ElementTree.write" class="py-name" href="#" onclick="return doclink('link-956', 'write', 'link-956');">write</a></tt><tt class="py-op">(</tt><tt class="py-name">f</tt><tt class="py-op">,</tt> <tt id="link-957" class="py-name"><a title="lxml.html.FormElement.method" class="py-name" href="#" onclick="return doclink('link-957', 'method', 'link-564');">method</a></tt><tt class="py-op">=</tt><tt class="py-string">"html"</tt><tt class="py-op">,</tt> <tt id="link-958" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-958', 'encoding', 'link-46');">encoding</a></tt><tt class="py-op">=</tt><tt id="link-959" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-959', 'encoding', 'link-46');">encoding</a></tt> <tt class="py-keyword">or</tt> <tt class="py-name">doc</tt><tt class="py-op">.</tt><tt id="link-960" class="py-name"><a title="lxml.etree._ElementTree.docinfo" class="py-name" href="#" onclick="return doclink('link-960', 'docinfo', 'link-58');">docinfo</a></tt><tt class="py-op">.</tt><tt id="link-961" class="py-name"><a title="lxml.etree.DocInfo.encoding" class="py-name" href="#" onclick="return doclink('link-961', 'encoding', 'link-46');">encoding</a></tt> <tt class="py-keyword">or</tt> <tt class="py-string">"UTF-8"</tt><tt class="py-op">)</tt> </tt>
+<a name="L1668"></a><tt class="py-lineno">1668</tt> <tt class="py-line"> <tt class="py-keyword">finally</tt><tt class="py-op">:</tt> </tt>
+<a name="L1669"></a><tt class="py-lineno">1669</tt> <tt class="py-line"> <tt class="py-comment"># we leak the file itself here, but we should at least close it</tt> </tt>
+<a name="L1670"></a><tt class="py-lineno">1670</tt> <tt class="py-line"> <tt class="py-name">f</tt><tt class="py-op">.</tt><tt id="link-962" class="py-name" targets="Method lxml.etree.TreeBuilder.close()=lxml.etree.TreeBuilder-class.html#close,Method lxml.etree._FeedParser.close()=lxml.etree._FeedParser-class.html#close,Method lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.close()=lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike-class.html#close"><a title="lxml.etree.TreeBuilder.close
lxml.etree._FeedParser.close
-lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.close" class="py-name" href="#" onclick="return doclink('link-959', 'close', 'link-959');">close</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1670"></a><tt class="py-lineno">1670</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-string">'file://'</tt> <tt class="py-op">+</tt> <tt class="py-name">fn</tt><tt class="py-op">.</tt><tt id="link-960" class="py-name" targets="Method lxml.etree._Element.replace()=lxml.etree._Element-class.html#replace"><a title="lxml.etree._Element.replace" class="py-name" href="#" onclick="return doclink('link-960', 'replace', 'link-960');">replace</a></tt><tt class="py-op">(</tt><tt class="py-name">os</tt><tt class="py-op">.</tt><tt id="link-961" class="py-name" targets="Variable lxml.etree.XPath.path=lxml.etree.XPath-class.html#path"><a title="lxml.etree.XPath.path" class="py-name" href="#" onclick="return doclink('link-961', 'path', 'link-961');">path</a></tt><tt class="py-op">.</tt><tt class="py-name">sep</tt><tt class="py-op">,</tt> <tt class="py-string">'/'</tt><tt class="py-op">)</tt> </tt>
-<a name="L1671"></a><tt class="py-lineno">1671</tt> <tt class="py-line"> <tt class="py-keyword">print</tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">)</tt> </tt>
-<a name="L1672"></a><tt class="py-lineno">1672</tt> <tt class="py-line"> <tt class="py-name">webbrowser</tt><tt class="py-op">.</tt><tt class="py-name">open</tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">)</tt> </tt>
-</div><a name="L1673"></a><tt class="py-lineno">1673</tt> <tt class="py-line"> </tt>
-<a name="L1674"></a><tt class="py-lineno">1674</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
-<a name="L1675"></a><tt class="py-lineno">1675</tt> <tt class="py-line"><tt class="py-comment"># configure Element class lookup</tt> </tt>
-<a name="L1676"></a><tt class="py-lineno">1676</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
-<a name="L1677"></a><tt class="py-lineno">1677</tt> <tt class="py-line"> </tt>
-<a name="HTMLParser"></a><div id="HTMLParser-def"><a name="L1678"></a><tt class="py-lineno">1678</tt> <a class="py-toggle" href="#" id="HTMLParser-toggle" onclick="return toggle('HTMLParser');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HTMLParser-class.html">HTMLParser</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">HTMLParser</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HTMLParser-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HTMLParser-expanded"><a name="L1679"></a><tt class="py-lineno">1679</tt> <tt class="py-line"> <tt class="py-docstring">"""An HTML parser that is configured to return lxml.html Element</tt> </tt>
-<a name="L1680"></a><tt class="py-lineno">1680</tt> <tt class="py-line"><tt class="py-docstring"> objects.</tt> </tt>
-<a name="L1681"></a><tt class="py-lineno">1681</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="HTMLParser.__init__"></a><div id="HTMLParser.__init__-def"><a name="L1682"></a><tt class="py-lineno">1682</tt> <a class="py-toggle" href="#" id="HTMLParser.__init__-toggle" onclick="return toggle('HTMLParser.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HTMLParser-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kwargs</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="HTMLParser.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HTMLParser.__init__-expanded"><a name="L1683"></a><tt class="py-lineno">1683</tt> <tt class="py-line"> <tt class="py-name">super</tt><tt class="py-op">(</tt><tt id="link-962" class="py-name" targets="Class lxml.etree.HTMLParser=lxml.etree.HTMLParser-class.html,Class lxml.html.HTMLParser=lxml.html.HTMLParser-class.html,Class lxml.html.html5parser.HTMLParser=lxml.html.html5parser.HTMLParser-class.html"><a title="lxml.etree.HTMLParser
+lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.close" class="py-name" href="#" onclick="return doclink('link-962', 'close', 'link-962');">close</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1671"></a><tt class="py-lineno">1671</tt> <tt class="py-line"> <tt class="py-name">url</tt> <tt class="py-op">=</tt> <tt class="py-string">'file://'</tt> <tt class="py-op">+</tt> <tt class="py-name">fn</tt><tt class="py-op">.</tt><tt id="link-963" class="py-name" targets="Method lxml.etree._Element.replace()=lxml.etree._Element-class.html#replace"><a title="lxml.etree._Element.replace" class="py-name" href="#" onclick="return doclink('link-963', 'replace', 'link-963');">replace</a></tt><tt class="py-op">(</tt><tt class="py-name">os</tt><tt class="py-op">.</tt><tt id="link-964" class="py-name" targets="Variable lxml.etree.XPath.path=lxml.etree.XPath-class.html#path"><a title="lxml.etree.XPath.path" class="py-name" href="#" onclick="return doclink('link-964', 'path', 'link-964');">path</a></tt><tt class="py-op">.</tt><tt class="py-name">sep</tt><tt class="py-op">,</tt> <tt class="py-string">'/'</tt><tt class="py-op">)</tt> </tt>
+<a name="L1672"></a><tt class="py-lineno">1672</tt> <tt class="py-line"> <tt class="py-keyword">print</tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">)</tt> </tt>
+<a name="L1673"></a><tt class="py-lineno">1673</tt> <tt class="py-line"> <tt class="py-name">webbrowser</tt><tt class="py-op">.</tt><tt class="py-name">open</tt><tt class="py-op">(</tt><tt class="py-name">url</tt><tt class="py-op">)</tt> </tt>
+</div><a name="L1674"></a><tt class="py-lineno">1674</tt> <tt class="py-line"> </tt>
+<a name="L1675"></a><tt class="py-lineno">1675</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
+<a name="L1676"></a><tt class="py-lineno">1676</tt> <tt class="py-line"><tt class="py-comment"># configure Element class lookup</tt> </tt>
+<a name="L1677"></a><tt class="py-lineno">1677</tt> <tt class="py-line"><tt class="py-comment">################################################################################</tt> </tt>
+<a name="L1678"></a><tt class="py-lineno">1678</tt> <tt class="py-line"> </tt>
+<a name="HTMLParser"></a><div id="HTMLParser-def"><a name="L1679"></a><tt class="py-lineno">1679</tt> <a class="py-toggle" href="#" id="HTMLParser-toggle" onclick="return toggle('HTMLParser');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.HTMLParser-class.html">HTMLParser</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">HTMLParser</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HTMLParser-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="HTMLParser-expanded"><a name="L1680"></a><tt class="py-lineno">1680</tt> <tt class="py-line"> <tt class="py-docstring">"""An HTML parser that is configured to return lxml.html Element</tt> </tt>
+<a name="L1681"></a><tt class="py-lineno">1681</tt> <tt class="py-line"><tt class="py-docstring"> objects.</tt> </tt>
+<a name="L1682"></a><tt class="py-lineno">1682</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="HTMLParser.__init__"></a><div id="HTMLParser.__init__-def"><a name="L1683"></a><tt class="py-lineno">1683</tt> <a class="py-toggle" href="#" id="HTMLParser.__init__-toggle" onclick="return toggle('HTMLParser.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.HTMLParser-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kwargs</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="HTMLParser.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="HTMLParser.__init__-expanded"><a name="L1684"></a><tt class="py-lineno">1684</tt> <tt class="py-line"> <tt class="py-name">super</tt><tt class="py-op">(</tt><tt id="link-965" class="py-name" targets="Class lxml.etree.HTMLParser=lxml.etree.HTMLParser-class.html,Class lxml.html.HTMLParser=lxml.html.HTMLParser-class.html,Class lxml.html.html5parser.HTMLParser=lxml.html.html5parser.HTMLParser-class.html"><a title="lxml.etree.HTMLParser
lxml.html.HTMLParser
-lxml.html.html5parser.HTMLParser" class="py-name" href="#" onclick="return doclink('link-962', 'HTMLParser', 'link-962');">HTMLParser</a></tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-963" class="py-name"><a title="lxml.builder.ElementMaker.__init__
+lxml.html.html5parser.HTMLParser" class="py-name" href="#" onclick="return doclink('link-965', 'HTMLParser', 'link-965');">HTMLParser</a></tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-966" class="py-name"><a title="lxml.builder.ElementMaker.__init__
lxml.cssselect.CSSSelector.__init__
lxml.doctestcompare._RestoreChecker.__init__
lxml.etree.AttributeBasedElementClassLookup.__init__
lxml.tests.test_doctestcompare.DummyInput.__init__
lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.__init__
lxml.tests.test_threading.ThreadPipelineTestCase.Worker.__init__
-lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__" class="py-name" href="#" onclick="return doclink('link-963', '__init__', 'link-266');">__init__</a></tt><tt class="py-op">(</tt><tt class="py-op">**</tt><tt class="py-name">kwargs</tt><tt class="py-op">)</tt> </tt>
-<a name="L1684"></a><tt class="py-lineno">1684</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-964" class="py-name" targets="Method lxml.etree.iterparse.set_element_class_lookup()=lxml.etree.iterparse-class.html#set_element_class_lookup,Function lxml.etree.set_element_class_lookup()=lxml.etree-module.html#set_element_class_lookup"><a title="lxml.etree.iterparse.set_element_class_lookup
-lxml.etree.set_element_class_lookup" class="py-name" href="#" onclick="return doclink('link-964', 'set_element_class_lookup', 'link-964');">set_element_class_lookup</a></tt><tt class="py-op">(</tt><tt id="link-965" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-965', 'HtmlElementClassLookup', 'link-566');">HtmlElementClassLookup</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1685"></a><tt class="py-lineno">1685</tt> <tt class="py-line"> </tt>
-<a name="XHTMLParser"></a><div id="XHTMLParser-def"><a name="L1686"></a><tt class="py-lineno">1686</tt> <a class="py-toggle" href="#" id="XHTMLParser-toggle" onclick="return toggle('XHTMLParser');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.XHTMLParser-class.html">XHTMLParser</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">XMLParser</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="XHTMLParser-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="XHTMLParser-expanded"><a name="L1687"></a><tt class="py-lineno">1687</tt> <tt class="py-line"> <tt class="py-docstring">"""An XML parser that is configured to return lxml.html Element</tt> </tt>
-<a name="L1688"></a><tt class="py-lineno">1688</tt> <tt class="py-line"><tt class="py-docstring"> objects.</tt> </tt>
-<a name="L1689"></a><tt class="py-lineno">1689</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1690"></a><tt class="py-lineno">1690</tt> <tt class="py-line"><tt class="py-docstring"> Note that this parser is not really XHTML aware unless you let it</tt> </tt>
-<a name="L1691"></a><tt class="py-lineno">1691</tt> <tt class="py-line"><tt class="py-docstring"> load a DTD that declares the HTML entities. To do this, make sure</tt> </tt>
-<a name="L1692"></a><tt class="py-lineno">1692</tt> <tt class="py-line"><tt class="py-docstring"> you have the XHTML DTDs installed in your catalogs, and create the</tt> </tt>
-<a name="L1693"></a><tt class="py-lineno">1693</tt> <tt class="py-line"><tt class="py-docstring"> parser like this::</tt> </tt>
-<a name="L1694"></a><tt class="py-lineno">1694</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1695"></a><tt class="py-lineno">1695</tt> <tt class="py-line"><tt class="py-docstring"> >>> parser = XHTMLParser(load_dtd=True)</tt> </tt>
-<a name="L1696"></a><tt class="py-lineno">1696</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1697"></a><tt class="py-lineno">1697</tt> <tt class="py-line"><tt class="py-docstring"> If you additionally want to validate the document, use this::</tt> </tt>
-<a name="L1698"></a><tt class="py-lineno">1698</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1699"></a><tt class="py-lineno">1699</tt> <tt class="py-line"><tt class="py-docstring"> >>> parser = XHTMLParser(dtd_validation=True)</tt> </tt>
-<a name="L1700"></a><tt class="py-lineno">1700</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1701"></a><tt class="py-lineno">1701</tt> <tt class="py-line"><tt class="py-docstring"> For catalog support, see http://www.xmlsoft.org/catalog.html.</tt> </tt>
-<a name="L1702"></a><tt class="py-lineno">1702</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="XHTMLParser.__init__"></a><div id="XHTMLParser.__init__-def"><a name="L1703"></a><tt class="py-lineno">1703</tt> <a class="py-toggle" href="#" id="XHTMLParser.__init__-toggle" onclick="return toggle('XHTMLParser.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.XHTMLParser-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kwargs</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="XHTMLParser.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="XHTMLParser.__init__-expanded"><a name="L1704"></a><tt class="py-lineno">1704</tt> <tt class="py-line"> <tt class="py-name">super</tt><tt class="py-op">(</tt><tt id="link-966" class="py-name" targets="Class lxml.html.XHTMLParser=lxml.html.XHTMLParser-class.html,Class lxml.html.html5parser.XHTMLParser=lxml.html.html5parser.XHTMLParser-class.html"><a title="lxml.html.XHTMLParser
-lxml.html.html5parser.XHTMLParser" class="py-name" href="#" onclick="return doclink('link-966', 'XHTMLParser', 'link-966');">XHTMLParser</a></tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-967" class="py-name"><a title="lxml.builder.ElementMaker.__init__
+lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__" class="py-name" href="#" onclick="return doclink('link-966', '__init__', 'link-269');">__init__</a></tt><tt class="py-op">(</tt><tt class="py-op">**</tt><tt class="py-name">kwargs</tt><tt class="py-op">)</tt> </tt>
+<a name="L1685"></a><tt class="py-lineno">1685</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-967" class="py-name" targets="Method lxml.etree.iterparse.set_element_class_lookup()=lxml.etree.iterparse-class.html#set_element_class_lookup,Function lxml.etree.set_element_class_lookup()=lxml.etree-module.html#set_element_class_lookup"><a title="lxml.etree.iterparse.set_element_class_lookup
+lxml.etree.set_element_class_lookup" class="py-name" href="#" onclick="return doclink('link-967', 'set_element_class_lookup', 'link-967');">set_element_class_lookup</a></tt><tt class="py-op">(</tt><tt id="link-968" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-968', 'HtmlElementClassLookup', 'link-569');">HtmlElementClassLookup</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1686"></a><tt class="py-lineno">1686</tt> <tt class="py-line"> </tt>
+<a name="XHTMLParser"></a><div id="XHTMLParser-def"><a name="L1687"></a><tt class="py-lineno">1687</tt> <a class="py-toggle" href="#" id="XHTMLParser-toggle" onclick="return toggle('XHTMLParser');">-</a><tt class="py-line"><tt class="py-keyword">class</tt> <a class="py-def-name" href="lxml.html.XHTMLParser-class.html">XHTMLParser</a><tt class="py-op">(</tt><tt class="py-base-class">etree</tt><tt class="py-op">.</tt><tt class="py-base-class">XMLParser</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="XHTMLParser-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="XHTMLParser-expanded"><a name="L1688"></a><tt class="py-lineno">1688</tt> <tt class="py-line"> <tt class="py-docstring">"""An XML parser that is configured to return lxml.html Element</tt> </tt>
+<a name="L1689"></a><tt class="py-lineno">1689</tt> <tt class="py-line"><tt class="py-docstring"> objects.</tt> </tt>
+<a name="L1690"></a><tt class="py-lineno">1690</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1691"></a><tt class="py-lineno">1691</tt> <tt class="py-line"><tt class="py-docstring"> Note that this parser is not really XHTML aware unless you let it</tt> </tt>
+<a name="L1692"></a><tt class="py-lineno">1692</tt> <tt class="py-line"><tt class="py-docstring"> load a DTD that declares the HTML entities. To do this, make sure</tt> </tt>
+<a name="L1693"></a><tt class="py-lineno">1693</tt> <tt class="py-line"><tt class="py-docstring"> you have the XHTML DTDs installed in your catalogs, and create the</tt> </tt>
+<a name="L1694"></a><tt class="py-lineno">1694</tt> <tt class="py-line"><tt class="py-docstring"> parser like this::</tt> </tt>
+<a name="L1695"></a><tt class="py-lineno">1695</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1696"></a><tt class="py-lineno">1696</tt> <tt class="py-line"><tt class="py-docstring"> >>> parser = XHTMLParser(load_dtd=True)</tt> </tt>
+<a name="L1697"></a><tt class="py-lineno">1697</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1698"></a><tt class="py-lineno">1698</tt> <tt class="py-line"><tt class="py-docstring"> If you additionally want to validate the document, use this::</tt> </tt>
+<a name="L1699"></a><tt class="py-lineno">1699</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1700"></a><tt class="py-lineno">1700</tt> <tt class="py-line"><tt class="py-docstring"> >>> parser = XHTMLParser(dtd_validation=True)</tt> </tt>
+<a name="L1701"></a><tt class="py-lineno">1701</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1702"></a><tt class="py-lineno">1702</tt> <tt class="py-line"><tt class="py-docstring"> For catalog support, see http://www.xmlsoft.org/catalog.html.</tt> </tt>
+<a name="L1703"></a><tt class="py-lineno">1703</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="XHTMLParser.__init__"></a><div id="XHTMLParser.__init__-def"><a name="L1704"></a><tt class="py-lineno">1704</tt> <a class="py-toggle" href="#" id="XHTMLParser.__init__-toggle" onclick="return toggle('XHTMLParser.__init__');">-</a><tt class="py-line"> <tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html.XHTMLParser-class.html#__init__">__init__</a><tt class="py-op">(</tt><tt class="py-param">self</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kwargs</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="XHTMLParser.__init__-collapsed" style="display:none;" pad="++++" indent="++++++++"></div><div id="XHTMLParser.__init__-expanded"><a name="L1705"></a><tt class="py-lineno">1705</tt> <tt class="py-line"> <tt class="py-name">super</tt><tt class="py-op">(</tt><tt id="link-969" class="py-name" targets="Class lxml.html.XHTMLParser=lxml.html.XHTMLParser-class.html,Class lxml.html.html5parser.XHTMLParser=lxml.html.html5parser.XHTMLParser-class.html"><a title="lxml.html.XHTMLParser
+lxml.html.html5parser.XHTMLParser" class="py-name" href="#" onclick="return doclink('link-969', 'XHTMLParser', 'link-969');">XHTMLParser</a></tt><tt class="py-op">,</tt> <tt class="py-name">self</tt><tt class="py-op">)</tt><tt class="py-op">.</tt><tt id="link-970" class="py-name"><a title="lxml.builder.ElementMaker.__init__
lxml.cssselect.CSSSelector.__init__
lxml.doctestcompare._RestoreChecker.__init__
lxml.etree.AttributeBasedElementClassLookup.__init__
lxml.tests.test_doctestcompare.DummyInput.__init__
lxml.tests.test_incremental_xmlfile.SimpleFileLikeXmlFileTestCase.SimpleFileLike.__init__
lxml.tests.test_threading.ThreadPipelineTestCase.Worker.__init__
-lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__" class="py-name" href="#" onclick="return doclink('link-967', '__init__', 'link-266');">__init__</a></tt><tt class="py-op">(</tt><tt class="py-op">**</tt><tt class="py-name">kwargs</tt><tt class="py-op">)</tt> </tt>
-<a name="L1705"></a><tt class="py-lineno">1705</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-968" class="py-name"><a title="lxml.etree.iterparse.set_element_class_lookup
-lxml.etree.set_element_class_lookup" class="py-name" href="#" onclick="return doclink('link-968', 'set_element_class_lookup', 'link-964');">set_element_class_lookup</a></tt><tt class="py-op">(</tt><tt id="link-969" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-969', 'HtmlElementClassLookup', 'link-566');">HtmlElementClassLookup</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
-</div></div><a name="L1706"></a><tt class="py-lineno">1706</tt> <tt class="py-line"> </tt>
-<a name="Element"></a><div id="Element-def"><a name="L1707"></a><tt class="py-lineno">1707</tt> <a class="py-toggle" href="#" id="Element-toggle" onclick="return toggle('Element');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#Element">Element</a><tt class="py-op">(</tt><tt class="py-op">*</tt><tt class="py-param">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
-</div><div id="Element-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="Element-expanded"><a name="L1708"></a><tt class="py-lineno">1708</tt> <tt class="py-line"> <tt class="py-docstring">"""Create a new HTML Element.</tt> </tt>
-<a name="L1709"></a><tt class="py-lineno">1709</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
-<a name="L1710"></a><tt class="py-lineno">1710</tt> <tt class="py-line"><tt class="py-docstring"> This can also be used for XHTML documents.</tt> </tt>
-<a name="L1711"></a><tt class="py-lineno">1711</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
-<a name="L1712"></a><tt class="py-lineno">1712</tt> <tt class="py-line"> <tt id="link-970" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-970', 'v', 'link-520');">v</a></tt> <tt class="py-op">=</tt> <tt id="link-971" class="py-name"><a title="lxml.html.html5parser.html_parser
-lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-971', 'html_parser', 'link-295');">html_parser</a></tt><tt class="py-op">.</tt><tt id="link-972" class="py-name" targets="Method lxml.etree._Element.makeelement()=lxml.etree._Element-class.html#makeelement,Method lxml.etree.iterparse.makeelement()=lxml.etree.iterparse-class.html#makeelement"><a title="lxml.etree._Element.makeelement
-lxml.etree.iterparse.makeelement" class="py-name" href="#" onclick="return doclink('link-972', 'makeelement', 'link-972');">makeelement</a></tt><tt class="py-op">(</tt><tt class="py-op">*</tt><tt class="py-name">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
-<a name="L1713"></a><tt class="py-lineno">1713</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-973" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-973', 'v', 'link-520');">v</a></tt> </tt>
-</div><a name="L1714"></a><tt class="py-lineno">1714</tt> <tt class="py-line"> </tt>
-<a name="L1715"></a><tt class="py-lineno">1715</tt> <tt class="py-line"><tt id="link-974" class="py-name"><a title="lxml.html.html5parser.html_parser
-lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-974', 'html_parser', 'link-295');">html_parser</a></tt> <tt class="py-op">=</tt> <tt id="link-975" class="py-name"><a title="lxml.etree.HTMLParser
+lxml.tests.test_xmlschema.ETreeXMLSchemaResolversTestCase.simple_resolver.__init__" class="py-name" href="#" onclick="return doclink('link-970', '__init__', 'link-269');">__init__</a></tt><tt class="py-op">(</tt><tt class="py-op">**</tt><tt class="py-name">kwargs</tt><tt class="py-op">)</tt> </tt>
+<a name="L1706"></a><tt class="py-lineno">1706</tt> <tt class="py-line"> <tt class="py-name">self</tt><tt class="py-op">.</tt><tt id="link-971" class="py-name"><a title="lxml.etree.iterparse.set_element_class_lookup
+lxml.etree.set_element_class_lookup" class="py-name" href="#" onclick="return doclink('link-971', 'set_element_class_lookup', 'link-967');">set_element_class_lookup</a></tt><tt class="py-op">(</tt><tt id="link-972" class="py-name"><a title="lxml.html.HtmlElementClassLookup" class="py-name" href="#" onclick="return doclink('link-972', 'HtmlElementClassLookup', 'link-569');">HtmlElementClassLookup</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt><tt class="py-op">)</tt> </tt>
+</div></div><a name="L1707"></a><tt class="py-lineno">1707</tt> <tt class="py-line"> </tt>
+<a name="Element"></a><div id="Element-def"><a name="L1708"></a><tt class="py-lineno">1708</tt> <a class="py-toggle" href="#" id="Element-toggle" onclick="return toggle('Element');">-</a><tt class="py-line"><tt class="py-keyword">def</tt> <a class="py-def-name" href="lxml.html-module.html#Element">Element</a><tt class="py-op">(</tt><tt class="py-op">*</tt><tt class="py-param">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-param">kw</tt><tt class="py-op">)</tt><tt class="py-op">:</tt> </tt>
+</div><div id="Element-collapsed" style="display:none;" pad="++++" indent="++++"></div><div id="Element-expanded"><a name="L1709"></a><tt class="py-lineno">1709</tt> <tt class="py-line"> <tt class="py-docstring">"""Create a new HTML Element.</tt> </tt>
+<a name="L1710"></a><tt class="py-lineno">1710</tt> <tt class="py-line"><tt class="py-docstring"></tt> </tt>
+<a name="L1711"></a><tt class="py-lineno">1711</tt> <tt class="py-line"><tt class="py-docstring"> This can also be used for XHTML documents.</tt> </tt>
+<a name="L1712"></a><tt class="py-lineno">1712</tt> <tt class="py-line"><tt class="py-docstring"> """</tt> </tt>
+<a name="L1713"></a><tt class="py-lineno">1713</tt> <tt class="py-line"> <tt id="link-973" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-973', 'v', 'link-523');">v</a></tt> <tt class="py-op">=</tt> <tt id="link-974" class="py-name"><a title="lxml.html.html5parser.html_parser
+lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-974', 'html_parser', 'link-298');">html_parser</a></tt><tt class="py-op">.</tt><tt id="link-975" class="py-name" targets="Method lxml.etree._Element.makeelement()=lxml.etree._Element-class.html#makeelement,Method lxml.etree.iterparse.makeelement()=lxml.etree.iterparse-class.html#makeelement"><a title="lxml.etree._Element.makeelement
+lxml.etree.iterparse.makeelement" class="py-name" href="#" onclick="return doclink('link-975', 'makeelement', 'link-975');">makeelement</a></tt><tt class="py-op">(</tt><tt class="py-op">*</tt><tt class="py-name">args</tt><tt class="py-op">,</tt> <tt class="py-op">**</tt><tt class="py-name">kw</tt><tt class="py-op">)</tt> </tt>
+<a name="L1714"></a><tt class="py-lineno">1714</tt> <tt class="py-line"> <tt class="py-keyword">return</tt> <tt id="link-976" class="py-name"><a title="lxml.tests.test_objectify.v" class="py-name" href="#" onclick="return doclink('link-976', 'v', 'link-523');">v</a></tt> </tt>
+</div><a name="L1715"></a><tt class="py-lineno">1715</tt> <tt class="py-line"> </tt>
+<a name="L1716"></a><tt class="py-lineno">1716</tt> <tt class="py-line"><tt id="link-977" class="py-name"><a title="lxml.html.html5parser.html_parser
+lxml.html.html_parser" class="py-name" href="#" onclick="return doclink('link-977', 'html_parser', 'link-298');">html_parser</a></tt> <tt class="py-op">=</tt> <tt id="link-978" class="py-name"><a title="lxml.etree.HTMLParser
lxml.html.HTMLParser
-lxml.html.html5parser.HTMLParser" class="py-name" href="#" onclick="return doclink('link-975', 'HTMLParser', 'link-962');">HTMLParser</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1716"></a><tt class="py-lineno">1716</tt> <tt class="py-line"><tt id="link-976" class="py-name" targets="Variable lxml.html.html5parser.xhtml_parser=lxml.html.html5parser-module.html#xhtml_parser,Variable lxml.html.xhtml_parser=lxml.html-module.html#xhtml_parser"><a title="lxml.html.html5parser.xhtml_parser
-lxml.html.xhtml_parser" class="py-name" href="#" onclick="return doclink('link-976', 'xhtml_parser', 'link-976');">xhtml_parser</a></tt> <tt class="py-op">=</tt> <tt id="link-977" class="py-name"><a title="lxml.html.XHTMLParser
-lxml.html.html5parser.XHTMLParser" class="py-name" href="#" onclick="return doclink('link-977', 'XHTMLParser', 'link-966');">XHTMLParser</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
-<a name="L1717"></a><tt class="py-lineno">1717</tt> <tt class="py-line"> </tt><script type="text/javascript">
+lxml.html.html5parser.HTMLParser" class="py-name" href="#" onclick="return doclink('link-978', 'HTMLParser', 'link-965');">HTMLParser</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1717"></a><tt class="py-lineno">1717</tt> <tt class="py-line"><tt id="link-979" class="py-name" targets="Variable lxml.html.html5parser.xhtml_parser=lxml.html.html5parser-module.html#xhtml_parser,Variable lxml.html.xhtml_parser=lxml.html-module.html#xhtml_parser"><a title="lxml.html.html5parser.xhtml_parser
+lxml.html.xhtml_parser" class="py-name" href="#" onclick="return doclink('link-979', 'xhtml_parser', 'link-979');">xhtml_parser</a></tt> <tt class="py-op">=</tt> <tt id="link-980" class="py-name"><a title="lxml.html.XHTMLParser
+lxml.html.html5parser.XHTMLParser" class="py-name" href="#" onclick="return doclink('link-980', 'XHTMLParser', 'link-969');">XHTMLParser</a></tt><tt class="py-op">(</tt><tt class="py-op">)</tt> </tt>
+<a name="L1718"></a><tt class="py-lineno">1718</tt> <tt class="py-line"> </tt><script type="text/javascript">
<!--
expandto(location.href);
// -->
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
<tr>
<td align="left" class="footer">
- Generated by Epydoc 3.0.1 on Sat Feb 7 20:53:48 2015
+ Generated by Epydoc 3.0.1 on Wed Apr 15 19:28:03 2015
</td>
<td align="right" class="footer">
<a target="mainFrame" href="http://epydoc.sourceforge.net"
__pyx_e_4lxml_5etree_OUTPUT_METHOD_TEXT
};
-/* "src/lxml/serializer.pxi":685
+/* "src/lxml/serializer.pxi":694
*
*
* cdef enum _IncrementalFileWriterStatus: # <<<<<<<<<<<<<<
xmlNode *node;
};
-/* "src/lxml/lxml.etree.pyx":2632
+/* "src/lxml/lxml.etree.pyx":2641
* self._storeTags(item, seen)
*
* cdef inline int cacheTags(self, _Document doc, bint force_into_dict=False) except -1: # <<<<<<<<<<<<<<
__PYX_EXTERN_C DL_EXPORT(PyTypeObject) LxmlElementType;
-/* "src/lxml/lxml.etree.pyx":1531
+/* "src/lxml/lxml.etree.pyx":1540
*
* @cython.internal
* cdef class __ContentOnlyElement(_Element): # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":1598
+/* "src/lxml/lxml.etree.pyx":1607
* return []
*
* cdef class _Comment(__ContentOnlyElement): # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":1606
+/* "src/lxml/lxml.etree.pyx":1615
* return u"<!--%s-->" % self.text
*
* cdef class _ProcessingInstruction(__ContentOnlyElement): # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":1656
+/* "src/lxml/lxml.etree.pyx":1665
* cdef object _FIND_PI_ATTRIBUTES = re.compile(ur'\s+(\w+)\s*=\s*(?:\'([^\']*)\'|"([^"]*)")', re.U).findall
*
* cdef class _Entity(__ContentOnlyElement): # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":1753
+/* "src/lxml/lxml.etree.pyx":1762
*
*
* cdef public class _ElementTree [ type LxmlElementTreeType, # <<<<<<<<<<<<<<
__PYX_EXTERN_C DL_EXPORT(PyTypeObject) LxmlElementTreeType;
-/* "src/lxml/lxml.etree.pyx":2296
+/* "src/lxml/lxml.etree.pyx":2305
* @cython.final
* @cython.freelist(16)
* cdef class _Attrib: # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2436
+/* "src/lxml/lxml.etree.pyx":2445
* @cython.final
* @cython.internal
* cdef class _AttribIterator: # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2477
+/* "src/lxml/lxml.etree.pyx":2486
*
*
* cdef public class _ElementTagMatcher [ object LxmlElementTagMatcher, # <<<<<<<<<<<<<<
__PYX_EXTERN_C DL_EXPORT(PyTypeObject) LxmlElementTagMatcherType;
-/* "src/lxml/lxml.etree.pyx":2508
+/* "src/lxml/lxml.etree.pyx":2517
* self._name = NULL
*
* cdef public class _ElementIterator(_ElementTagMatcher) [ # <<<<<<<<<<<<<<
__PYX_EXTERN_C DL_EXPORT(PyTypeObject) LxmlElementIteratorType;
-/* "src/lxml/lxml.etree.pyx":2545
+/* "src/lxml/lxml.etree.pyx":2554
* @cython.final
* @cython.internal
* cdef class _MultiTagMatcher: # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2686
+/* "src/lxml/lxml.etree.pyx":2695
* return False
*
* cdef class _ElementMatchIterator: # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2715
+/* "src/lxml/lxml.etree.pyx":2724
* return current_node
*
* cdef class ElementChildIterator(_ElementMatchIterator): # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2735
+/* "src/lxml/lxml.etree.pyx":2744
* self._node = _elementFactory(node._doc, c_node) if c_node is not NULL else None
*
* cdef class SiblingsIterator(_ElementMatchIterator): # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2750
+/* "src/lxml/lxml.etree.pyx":2759
* self._storeNext(node)
*
* cdef class AncestorsIterator(_ElementMatchIterator): # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2760
+/* "src/lxml/lxml.etree.pyx":2769
* self._storeNext(node)
*
* cdef class ElementDepthFirstIterator: # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2836
+/* "src/lxml/lxml.etree.pyx":2845
* return NULL
*
* cdef class ElementTextIterator: # <<<<<<<<<<<<<<
};
-/* "src/lxml/lxml.etree.pyx":2947
+/* "src/lxml/lxml.etree.pyx":2956
* PI = ProcessingInstruction
*
* cdef class CDATA: # <<<<<<<<<<<<<<
};
-/* "src/lxml/serializer.pxi":374
+/* "src/lxml/serializer.pxi":381
* @cython.final
* @cython.internal
* cdef class _FilelikeWriter: # <<<<<<<<<<<<<<
};
-/* "src/lxml/serializer.pxi":605
+/* "src/lxml/serializer.pxi":614
* # incremental serialisation
*
* cdef class xmlfile: # <<<<<<<<<<<<<<
};
-/* "src/lxml/serializer.pxi":674
+/* "src/lxml/serializer.pxi":683
*
*
* cdef class htmlfile(xmlfile): # <<<<<<<<<<<<<<
};
-/* "src/lxml/serializer.pxi":695
+/* "src/lxml/serializer.pxi":704
* @cython.final
* @cython.internal
* cdef class _IncrementalFileWriter: # <<<<<<<<<<<<<<
};
-/* "src/lxml/serializer.pxi":958
+/* "src/lxml/serializer.pxi":968
* @cython.internal
* @cython.freelist(8)
* cdef class _FileWriterElement: # <<<<<<<<<<<<<<
};
-/* "src/lxml/xslt.pxi":698
+/* "src/lxml/xslt.pxi":700
*
* @cython.final
* cdef class _XSLTResultTree(_ElementTree): # <<<<<<<<<<<<<<
};
-/* "src/lxml/xslt.pxi":849
+/* "src/lxml/xslt.pxi":851
* return __findStylesheetByID(doc, id=id)
*
* cdef class _XSLTProcessingInstruction(PIBase): # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree_PyErrorLog *__pyx_vtabptr_4lxml_5etree_PyErrorLog;
-/* "src/lxml/lxml.etree.pyx":1531
+/* "src/lxml/lxml.etree.pyx":1540
*
* @cython.internal
* cdef class __ContentOnlyElement(_Element): # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *__pyx_vtabptr_4lxml_5etree___ContentOnlyElement;
-/* "src/lxml/lxml.etree.pyx":1598
+/* "src/lxml/lxml.etree.pyx":1607
* return []
*
* cdef class _Comment(__ContentOnlyElement): # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree__Comment *__pyx_vtabptr_4lxml_5etree__Comment;
-/* "src/lxml/lxml.etree.pyx":1606
+/* "src/lxml/lxml.etree.pyx":1615
* return u"<!--%s-->" % self.text
*
* cdef class _ProcessingInstruction(__ContentOnlyElement): # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree__ProcessingInstruction *__pyx_vtabptr_4lxml_5etree__ProcessingInstruction;
-/* "src/lxml/lxml.etree.pyx":1656
+/* "src/lxml/lxml.etree.pyx":1665
* cdef object _FIND_PI_ATTRIBUTES = re.compile(ur'\s+(\w+)\s*=\s*(?:\'([^\']*)\'|"([^"]*)")', re.U).findall
*
* cdef class _Entity(__ContentOnlyElement): # <<<<<<<<<<<<<<
__PYX_EXTERN_C DL_EXPORT(PyTypeObject) LxmlElementTreeType;
-/* "src/lxml/lxml.etree.pyx":1753
+/* "src/lxml/lxml.etree.pyx":1762
*
*
* cdef public class _ElementTree [ type LxmlElementTreeType, # <<<<<<<<<<<<<<
__PYX_EXTERN_C DL_EXPORT(PyTypeObject) LxmlElementTagMatcherType;
-/* "src/lxml/lxml.etree.pyx":2477
+/* "src/lxml/lxml.etree.pyx":2486
*
*
* cdef public class _ElementTagMatcher [ object LxmlElementTagMatcher, # <<<<<<<<<<<<<<
__PYX_EXTERN_C DL_EXPORT(PyTypeObject) LxmlElementIteratorType;
-/* "src/lxml/lxml.etree.pyx":2508
+/* "src/lxml/lxml.etree.pyx":2517
* self._name = NULL
*
* cdef public class _ElementIterator(_ElementTagMatcher) [ # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree__ElementIterator *__pyx_vtabptr_4lxml_5etree__ElementIterator;
-/* "src/lxml/lxml.etree.pyx":2545
+/* "src/lxml/lxml.etree.pyx":2554
* @cython.final
* @cython.internal
* cdef class _MultiTagMatcher: # <<<<<<<<<<<<<<
static CYTHON_INLINE int __pyx_f_4lxml_5etree_16_MultiTagMatcher_matchesAttribute(struct __pyx_obj_4lxml_5etree__MultiTagMatcher *, xmlAttr *);
-/* "src/lxml/lxml.etree.pyx":2686
+/* "src/lxml/lxml.etree.pyx":2695
* return False
*
* cdef class _ElementMatchIterator: # <<<<<<<<<<<<<<
static int __pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext(struct __pyx_obj_4lxml_5etree__ElementMatchIterator *, struct LxmlElement *);
-/* "src/lxml/lxml.etree.pyx":2715
+/* "src/lxml/lxml.etree.pyx":2724
* return current_node
*
* cdef class ElementChildIterator(_ElementMatchIterator): # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree_ElementChildIterator *__pyx_vtabptr_4lxml_5etree_ElementChildIterator;
-/* "src/lxml/lxml.etree.pyx":2735
+/* "src/lxml/lxml.etree.pyx":2744
* self._node = _elementFactory(node._doc, c_node) if c_node is not NULL else None
*
* cdef class SiblingsIterator(_ElementMatchIterator): # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree_SiblingsIterator *__pyx_vtabptr_4lxml_5etree_SiblingsIterator;
-/* "src/lxml/lxml.etree.pyx":2750
+/* "src/lxml/lxml.etree.pyx":2759
* self._storeNext(node)
*
* cdef class AncestorsIterator(_ElementMatchIterator): # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree_AncestorsIterator *__pyx_vtabptr_4lxml_5etree_AncestorsIterator;
-/* "src/lxml/lxml.etree.pyx":2760
+/* "src/lxml/lxml.etree.pyx":2769
* self._storeNext(node)
*
* cdef class ElementDepthFirstIterator: # <<<<<<<<<<<<<<
static int __pyx_f_4lxml_5etree_30_ParserSchemaValidationContext_isvalid(struct __pyx_obj_4lxml_5etree__ParserSchemaValidationContext *);
-/* "src/lxml/lxml.etree.pyx":3344
+/* "src/lxml/lxml.etree.pyx":3353
* pass
*
* cdef class _Validator: # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree__PythonSaxParserTarget *__pyx_vtabptr_4lxml_5etree__PythonSaxParserTarget;
-/* "src/lxml/serializer.pxi":374
+/* "src/lxml/serializer.pxi":381
* @cython.final
* @cython.internal
* cdef class _FilelikeWriter: # <<<<<<<<<<<<<<
static int __pyx_f_4lxml_5etree_15_FilelikeWriter_close(struct __pyx_obj_4lxml_5etree__FilelikeWriter *);
-/* "src/lxml/serializer.pxi":695
+/* "src/lxml/serializer.pxi":704
* @cython.final
* @cython.internal
* cdef class _IncrementalFileWriter: # <<<<<<<<<<<<<<
static struct __pyx_vtabstruct_4lxml_5etree_XSLT *__pyx_vtabptr_4lxml_5etree_XSLT;
-/* "src/lxml/xslt.pxi":698
+/* "src/lxml/xslt.pxi":700
*
* @cython.final
* cdef class _XSLTResultTree(_ElementTree): # <<<<<<<<<<<<<<
static PyObject *__pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize(struct __pyx_obj_4lxml_5etree__XSLTResultTree *, xmlChar **, int *);
-/* "src/lxml/xslt.pxi":849
+/* "src/lxml/xslt.pxi":851
* return __findStylesheetByID(doc, id=id)
*
* cdef class _XSLTProcessingInstruction(PIBase): # <<<<<<<<<<<<<<
#define __PYX_FORCE_INIT_THREADS 0
#endif
+static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname);
+
static CYTHON_INLINE int __Pyx_PyDict_Contains(PyObject* item, PyObject* dict, int eq) {
int result = PyDict_Contains(dict, item);
return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
#define __Pyx_PyIter_Next(obj) __Pyx_PyIter_Next2(obj, NULL)
static CYTHON_INLINE PyObject *__Pyx_PyIter_Next2(PyObject *, PyObject *);
-static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname);
-
#if CYTHON_COMPILING_IN_CPYTHON && PY_MAJOR_VERSION >= 3
#define __Pyx_PyCallable_Check(obj) ((obj)->ob_type->tp_call != NULL)
#else
static char __pyx_k_g[] = "g";
static char __pyx_k_i[] = "i";
static char __pyx_k_k[] = "k";
-static char __pyx_k_s[] = "<!--%s-->";
+static char __pyx_k_s[] = "'%s'";
static char __pyx_k_v[] = "v";
static char __pyx_k_w[] = "w";
static char __pyx_k_Ok[] = "Ok";
static char __pyx_k__14[] = " ";
static char __pyx_k__15[] = "";
static char __pyx_k__22[] = "\n";
-static char __pyx_k__25[] = "&";
-static char __pyx_k__26[] = ";";
-static char __pyx_k__30[] = "/";
-static char __pyx_k__35[] = "*";
-static char __pyx_k__36[] = "{*}*";
-static char __pyx_k__47[] = "_";
-static char __pyx_k__52[] = "'?>\n";
-static char __pyx_k__53[] = "\" \"";
-static char __pyx_k__54[] = "\"";
-static char __pyx_k__55[] = ">\n";
-static char __pyx_k__56[] = " [\n";
-static char __pyx_k__57[] = "]>\n";
-static char __pyx_k__62[] = ":";
-static char __pyx_k__64[] = "<";
-static char __pyx_k__65[] = ">";
-static char __pyx_k__66[] = "=\"";
-static char __pyx_k__72[] = "</";
-static char __pyx_k__93[] = ", ";
+static char __pyx_k__25[] = "\"";
+static char __pyx_k__26[] = "&";
+static char __pyx_k__27[] = ";";
+static char __pyx_k__31[] = "/";
+static char __pyx_k__36[] = "*";
+static char __pyx_k__37[] = "{*}*";
+static char __pyx_k__48[] = "_";
+static char __pyx_k__53[] = "'?>\n";
+static char __pyx_k__54[] = "\" ";
+static char __pyx_k__55[] = "'";
+static char __pyx_k__56[] = ">\n";
+static char __pyx_k__57[] = " [\n";
+static char __pyx_k__58[] = "]>\n";
+static char __pyx_k__63[] = ":";
+static char __pyx_k__65[] = "<";
+static char __pyx_k__66[] = ">";
+static char __pyx_k__67[] = "=\"";
+static char __pyx_k__73[] = "</";
+static char __pyx_k__94[] = ", ";
static char __pyx_k_add[] = "add";
static char __pyx_k_all[] = "__all__";
static char __pyx_k_any[] = "any";
static char __pyx_k_opt[] = "opt";
static char __pyx_k_pop[] = "pop";
static char __pyx_k_rdf[] = "rdf";
-static char __pyx_k_s_2[] = "<?%s?>";
-static char __pyx_k_s_3[] = "&%s;";
-static char __pyx_k_s_4[] = "s";
+static char __pyx_k_s_2[] = "\"%s\"";
+static char __pyx_k_s_3[] = "<!--%s-->";
+static char __pyx_k_s_4[] = "<?%s?>";
+static char __pyx_k_s_5[] = "&%s;";
+static char __pyx_k_s_6[] = "s";
static char __pyx_k_s_d[] = "%s[%d]";
static char __pyx_k_s_r[] = "%s=%r";
static char __pyx_k_s_s[] = "%s:%s";
static char __pyx_k_HTML[] = "HTML";
static char __pyx_k_UTF8[] = "UTF8";
static char __pyx_k_XSLT[] = "XSLT";
-static char __pyx_k__199[] = "(\"[^\"]*\")|('[^']*')";
-static char __pyx_k__201[] = "({[^}]+})";
+static char __pyx_k__200[] = "(\"[^\"]*\")|('[^']*')";
+static char __pyx_k__202[] = "({[^}]+})";
static char __pyx_k_args[] = "args";
static char __pyx_k_beta[] = "beta";
static char __pyx_k_c14n[] = "c14n";
static char __pyx_k_PARSER[] = "PARSER";
static char __pyx_k_PIBase[] = "PIBase";
static char __pyx_k_PUBLIC[] = " PUBLIC \"";
-static char __pyx_k_SYSTEM[] = " SYSTEM \"";
+static char __pyx_k_SYSTEM[] = " SYSTEM ";
static char __pyx_k_attrib[] = "attrib";
static char __pyx_k_c_name[] = "c_name";
static char __pyx_k_c_next[] = "c_next";
static char __pyx_k_FutureWarning[] = "FutureWarning";
static char __pyx_k_StopIteration[] = "StopIteration";
static char __pyx_k_XIncludeError[] = "XIncludeError";
-static char __pyx_k_XML_line_3049[] = "XML (line 3049)";
+static char __pyx_k_XML_line_3058[] = "XML (line 3058)";
static char __pyx_k_XSLTExtension[] = "XSLTExtension";
static char __pyx_k_XSLTSaveError[] = "XSLTSaveError";
static char __pyx_k_class_mapping[] = "class_mapping";
static char __pyx_k_s_line_d_column_d[] = "%s, line %d, column %d";
static char __pyx_k_write_declaration[] = "write_declaration";
static char __pyx_k_DOCTYPE_s_PUBLIC_s[] = "<!DOCTYPE %s PUBLIC \"%s\">";
-static char __pyx_k_DOCTYPE_s_SYSTEM_s[] = "<!DOCTYPE %s SYSTEM \"%s\">";
+static char __pyx_k_DOCTYPE_s_SYSTEM_s[] = "<!DOCTYPE %s SYSTEM %s>";
static char __pyx_k_ElementClassLookup[] = "ElementClassLookup";
static char __pyx_k_Invalid_expression[] = "Invalid expression";
static char __pyx_k_Invalid_tag_name_r[] = "Invalid tag name %r";
static char __pyx_k_internal_error_text[] = "internal error (text)";
static char __pyx_k_restructuredtext_en[] = "restructuredtext en";
static char __pyx_k_Cannot_resolve_URI_s[] = "Cannot resolve URI %s";
-static char __pyx_k_DOCTYPE_s_PUBLIC_s_s[] = "<!DOCTYPE %s PUBLIC \"%s\" \"%s\">";
+static char __pyx_k_DOCTYPE_s_PUBLIC_s_s[] = "<!DOCTYPE %s PUBLIC \"%s\" %s>";
static char __pyx_k_Invalid_child_type_r[] = "Invalid child type: %r";
static char __pyx_k_Invalid_context_size[] = "Invalid context size";
static char __pyx_k_Libxml2_error_levels[] = "Libxml2 error levels";
static PyObject *__pyx_n_s_XMLSyntaxError;
static PyObject *__pyx_n_s_XMLTreeBuilder;
static PyObject *__pyx_kp_s_XML_declaration_already_written;
-static PyObject *__pyx_kp_u_XML_line_3049;
+static PyObject *__pyx_kp_u_XML_line_3058;
static PyObject *__pyx_kp_u_XML_text_parser_None_base_url_No;
static PyObject *__pyx_n_u_XPATH_LOCATIONSET;
static PyObject *__pyx_n_u_XPATH_POINT;
static PyObject *__pyx_kp_b__15;
static PyObject *__pyx_kp_s__15;
static PyObject *__pyx_kp_u__15;
-static PyObject *__pyx_kp_b__199;
-static PyObject *__pyx_kp_b__201;
+static PyObject *__pyx_kp_b__200;
+static PyObject *__pyx_kp_b__202;
static PyObject *__pyx_kp_s__22;
static PyObject *__pyx_kp_u__22;
-static PyObject *__pyx_kp_b__25;
+static PyObject *__pyx_kp_s__25;
static PyObject *__pyx_kp_u__25;
static PyObject *__pyx_kp_b__26;
static PyObject *__pyx_kp_u__26;
+static PyObject *__pyx_kp_b__27;
+static PyObject *__pyx_kp_u__27;
static PyObject *__pyx_kp_u__3;
-static PyObject *__pyx_kp_s__30;
-static PyObject *__pyx_kp_b__35;
-static PyObject *__pyx_kp_s__35;
+static PyObject *__pyx_kp_s__31;
+static PyObject *__pyx_kp_b__36;
static PyObject *__pyx_kp_s__36;
+static PyObject *__pyx_kp_s__37;
static PyObject *__pyx_kp_b__4;
static PyObject *__pyx_kp_s__4;
static PyObject *__pyx_kp_u__4;
-static PyObject *__pyx_n_s__47;
-static PyObject *__pyx_n_u__47;
-static PyObject *__pyx_kp_u__54;
-static PyObject *__pyx_kp_b__62;
-static PyObject *__pyx_kp_u__65;
-static PyObject *__pyx_kp_u__93;
+static PyObject *__pyx_n_s__48;
+static PyObject *__pyx_n_u__48;
+static PyObject *__pyx_kp_b__63;
+static PyObject *__pyx_kp_u__66;
+static PyObject *__pyx_kp_u__94;
static PyObject *__pyx_n_s_abspath;
static PyObject *__pyx_n_s_accepted_domains;
static PyObject *__pyx_n_s_access_control;
static PyObject *__pyx_kp_u_s;
static PyObject *__pyx_kp_u_s_2;
static PyObject *__pyx_kp_u_s_3;
-static PyObject *__pyx_n_s_s_4;
+static PyObject *__pyx_kp_u_s_4;
+static PyObject *__pyx_kp_u_s_5;
+static PyObject *__pyx_n_s_s_6;
static PyObject *__pyx_kp_u_s_a_zA_Z0_9__s_s_0_9;
static PyObject *__pyx_kp_s_s_d;
static PyObject *__pyx_kp_u_s_d_d_s_s_s_s;
static PyObject *__pyx_tuple__8;
static PyObject *__pyx_slice__11;
static PyObject *__pyx_slice__13;
-static PyObject *__pyx_slice__31;
static PyObject *__pyx_slice__32;
static PyObject *__pyx_slice__33;
static PyObject *__pyx_slice__34;
-static PyObject *__pyx_slice__44;
-static PyObject *__pyx_slice__46;
-static PyObject *__pyx_slice__68;
+static PyObject *__pyx_slice__35;
+static PyObject *__pyx_slice__45;
+static PyObject *__pyx_slice__47;
static PyObject *__pyx_slice__69;
-static PyObject *__pyx_slice__71;
-static PyObject *__pyx_slice__86;
+static PyObject *__pyx_slice__70;
+static PyObject *__pyx_slice__72;
static PyObject *__pyx_slice__87;
-static PyObject *__pyx_slice__91;
+static PyObject *__pyx_slice__88;
+static PyObject *__pyx_slice__92;
static PyObject *__pyx_tuple__10;
static PyObject *__pyx_tuple__12;
static PyObject *__pyx_tuple__16;
static PyObject *__pyx_tuple__21;
static PyObject *__pyx_tuple__23;
static PyObject *__pyx_tuple__24;
-static PyObject *__pyx_tuple__27;
static PyObject *__pyx_tuple__28;
static PyObject *__pyx_tuple__29;
-static PyObject *__pyx_tuple__37;
+static PyObject *__pyx_tuple__30;
static PyObject *__pyx_tuple__38;
static PyObject *__pyx_tuple__39;
static PyObject *__pyx_tuple__40;
static PyObject *__pyx_tuple__41;
static PyObject *__pyx_tuple__42;
static PyObject *__pyx_tuple__43;
-static PyObject *__pyx_tuple__45;
-static PyObject *__pyx_tuple__48;
+static PyObject *__pyx_tuple__44;
+static PyObject *__pyx_tuple__46;
static PyObject *__pyx_tuple__49;
static PyObject *__pyx_tuple__50;
static PyObject *__pyx_tuple__51;
-static PyObject *__pyx_tuple__58;
+static PyObject *__pyx_tuple__52;
static PyObject *__pyx_tuple__59;
static PyObject *__pyx_tuple__60;
static PyObject *__pyx_tuple__61;
-static PyObject *__pyx_tuple__63;
-static PyObject *__pyx_tuple__67;
-static PyObject *__pyx_tuple__70;
-static PyObject *__pyx_tuple__73;
+static PyObject *__pyx_tuple__62;
+static PyObject *__pyx_tuple__64;
+static PyObject *__pyx_tuple__68;
+static PyObject *__pyx_tuple__71;
static PyObject *__pyx_tuple__74;
static PyObject *__pyx_tuple__75;
static PyObject *__pyx_tuple__76;
static PyObject *__pyx_tuple__83;
static PyObject *__pyx_tuple__84;
static PyObject *__pyx_tuple__85;
-static PyObject *__pyx_tuple__88;
+static PyObject *__pyx_tuple__86;
static PyObject *__pyx_tuple__89;
static PyObject *__pyx_tuple__90;
-static PyObject *__pyx_tuple__92;
-static PyObject *__pyx_tuple__94;
+static PyObject *__pyx_tuple__91;
+static PyObject *__pyx_tuple__93;
static PyObject *__pyx_tuple__95;
static PyObject *__pyx_tuple__96;
static PyObject *__pyx_tuple__97;
static PyObject *__pyx_tuple__104;
static PyObject *__pyx_tuple__105;
static PyObject *__pyx_tuple__106;
-static PyObject *__pyx_tuple__108;
-static PyObject *__pyx_tuple__110;
-static PyObject *__pyx_tuple__112;
-static PyObject *__pyx_tuple__114;
-static PyObject *__pyx_tuple__116;
-static PyObject *__pyx_tuple__118;
+static PyObject *__pyx_tuple__107;
+static PyObject *__pyx_tuple__109;
+static PyObject *__pyx_tuple__111;
+static PyObject *__pyx_tuple__113;
+static PyObject *__pyx_tuple__115;
+static PyObject *__pyx_tuple__117;
static PyObject *__pyx_tuple__119;
static PyObject *__pyx_tuple__120;
-static PyObject *__pyx_tuple__122;
-static PyObject *__pyx_tuple__124;
+static PyObject *__pyx_tuple__121;
+static PyObject *__pyx_tuple__123;
static PyObject *__pyx_tuple__125;
-static PyObject *__pyx_tuple__127;
+static PyObject *__pyx_tuple__126;
static PyObject *__pyx_tuple__128;
-static PyObject *__pyx_tuple__130;
+static PyObject *__pyx_tuple__129;
static PyObject *__pyx_tuple__131;
static PyObject *__pyx_tuple__132;
static PyObject *__pyx_tuple__133;
static PyObject *__pyx_tuple__134;
-static PyObject *__pyx_tuple__136;
-static PyObject *__pyx_tuple__138;
-static PyObject *__pyx_tuple__140;
-static PyObject *__pyx_tuple__142;
-static PyObject *__pyx_tuple__144;
-static PyObject *__pyx_tuple__146;
-static PyObject *__pyx_tuple__148;
-static PyObject *__pyx_tuple__150;
-static PyObject *__pyx_tuple__152;
-static PyObject *__pyx_tuple__154;
-static PyObject *__pyx_tuple__156;
-static PyObject *__pyx_tuple__158;
-static PyObject *__pyx_tuple__160;
-static PyObject *__pyx_tuple__162;
-static PyObject *__pyx_tuple__164;
-static PyObject *__pyx_tuple__166;
-static PyObject *__pyx_tuple__168;
-static PyObject *__pyx_tuple__170;
-static PyObject *__pyx_tuple__172;
-static PyObject *__pyx_tuple__175;
+static PyObject *__pyx_tuple__135;
+static PyObject *__pyx_tuple__137;
+static PyObject *__pyx_tuple__139;
+static PyObject *__pyx_tuple__141;
+static PyObject *__pyx_tuple__143;
+static PyObject *__pyx_tuple__145;
+static PyObject *__pyx_tuple__147;
+static PyObject *__pyx_tuple__149;
+static PyObject *__pyx_tuple__151;
+static PyObject *__pyx_tuple__153;
+static PyObject *__pyx_tuple__155;
+static PyObject *__pyx_tuple__157;
+static PyObject *__pyx_tuple__159;
+static PyObject *__pyx_tuple__161;
+static PyObject *__pyx_tuple__163;
+static PyObject *__pyx_tuple__165;
+static PyObject *__pyx_tuple__167;
+static PyObject *__pyx_tuple__169;
+static PyObject *__pyx_tuple__171;
+static PyObject *__pyx_tuple__173;
static PyObject *__pyx_tuple__176;
-static PyObject *__pyx_tuple__178;
-static PyObject *__pyx_tuple__180;
-static PyObject *__pyx_tuple__182;
-static PyObject *__pyx_tuple__184;
-static PyObject *__pyx_tuple__186;
-static PyObject *__pyx_tuple__188;
-static PyObject *__pyx_tuple__190;
-static PyObject *__pyx_tuple__192;
+static PyObject *__pyx_tuple__177;
+static PyObject *__pyx_tuple__179;
+static PyObject *__pyx_tuple__181;
+static PyObject *__pyx_tuple__183;
+static PyObject *__pyx_tuple__185;
+static PyObject *__pyx_tuple__187;
+static PyObject *__pyx_tuple__189;
+static PyObject *__pyx_tuple__191;
static PyObject *__pyx_tuple__193;
-static PyObject *__pyx_tuple__195;
-static PyObject *__pyx_tuple__197;
-static PyObject *__pyx_tuple__200;
-static PyObject *__pyx_tuple__202;
+static PyObject *__pyx_tuple__194;
+static PyObject *__pyx_tuple__196;
+static PyObject *__pyx_tuple__198;
+static PyObject *__pyx_tuple__201;
static PyObject *__pyx_tuple__203;
-static PyObject *__pyx_tuple__205;
-static PyObject *__pyx_tuple__207;
+static PyObject *__pyx_tuple__204;
+static PyObject *__pyx_tuple__206;
static PyObject *__pyx_tuple__208;
-static PyObject *__pyx_codeobj__107;
-static PyObject *__pyx_codeobj__109;
-static PyObject *__pyx_codeobj__111;
-static PyObject *__pyx_codeobj__113;
-static PyObject *__pyx_codeobj__115;
-static PyObject *__pyx_codeobj__117;
-static PyObject *__pyx_codeobj__121;
-static PyObject *__pyx_codeobj__123;
-static PyObject *__pyx_codeobj__126;
-static PyObject *__pyx_codeobj__129;
-static PyObject *__pyx_codeobj__135;
-static PyObject *__pyx_codeobj__137;
-static PyObject *__pyx_codeobj__139;
-static PyObject *__pyx_codeobj__141;
-static PyObject *__pyx_codeobj__143;
-static PyObject *__pyx_codeobj__145;
-static PyObject *__pyx_codeobj__147;
-static PyObject *__pyx_codeobj__149;
-static PyObject *__pyx_codeobj__151;
-static PyObject *__pyx_codeobj__153;
-static PyObject *__pyx_codeobj__155;
-static PyObject *__pyx_codeobj__157;
-static PyObject *__pyx_codeobj__159;
-static PyObject *__pyx_codeobj__161;
-static PyObject *__pyx_codeobj__163;
-static PyObject *__pyx_codeobj__165;
-static PyObject *__pyx_codeobj__167;
-static PyObject *__pyx_codeobj__169;
-static PyObject *__pyx_codeobj__171;
-static PyObject *__pyx_codeobj__173;
+static PyObject *__pyx_tuple__209;
+static PyObject *__pyx_codeobj__108;
+static PyObject *__pyx_codeobj__110;
+static PyObject *__pyx_codeobj__112;
+static PyObject *__pyx_codeobj__114;
+static PyObject *__pyx_codeobj__116;
+static PyObject *__pyx_codeobj__118;
+static PyObject *__pyx_codeobj__122;
+static PyObject *__pyx_codeobj__124;
+static PyObject *__pyx_codeobj__127;
+static PyObject *__pyx_codeobj__130;
+static PyObject *__pyx_codeobj__136;
+static PyObject *__pyx_codeobj__138;
+static PyObject *__pyx_codeobj__140;
+static PyObject *__pyx_codeobj__142;
+static PyObject *__pyx_codeobj__144;
+static PyObject *__pyx_codeobj__146;
+static PyObject *__pyx_codeobj__148;
+static PyObject *__pyx_codeobj__150;
+static PyObject *__pyx_codeobj__152;
+static PyObject *__pyx_codeobj__154;
+static PyObject *__pyx_codeobj__156;
+static PyObject *__pyx_codeobj__158;
+static PyObject *__pyx_codeobj__160;
+static PyObject *__pyx_codeobj__162;
+static PyObject *__pyx_codeobj__164;
+static PyObject *__pyx_codeobj__166;
+static PyObject *__pyx_codeobj__168;
+static PyObject *__pyx_codeobj__170;
+static PyObject *__pyx_codeobj__172;
static PyObject *__pyx_codeobj__174;
-static PyObject *__pyx_codeobj__177;
-static PyObject *__pyx_codeobj__179;
-static PyObject *__pyx_codeobj__181;
-static PyObject *__pyx_codeobj__183;
-static PyObject *__pyx_codeobj__185;
-static PyObject *__pyx_codeobj__187;
-static PyObject *__pyx_codeobj__189;
-static PyObject *__pyx_codeobj__191;
-static PyObject *__pyx_codeobj__194;
-static PyObject *__pyx_codeobj__196;
-static PyObject *__pyx_codeobj__198;
-static PyObject *__pyx_codeobj__204;
-static PyObject *__pyx_codeobj__206;
+static PyObject *__pyx_codeobj__175;
+static PyObject *__pyx_codeobj__178;
+static PyObject *__pyx_codeobj__180;
+static PyObject *__pyx_codeobj__182;
+static PyObject *__pyx_codeobj__184;
+static PyObject *__pyx_codeobj__186;
+static PyObject *__pyx_codeobj__188;
+static PyObject *__pyx_codeobj__190;
+static PyObject *__pyx_codeobj__192;
+static PyObject *__pyx_codeobj__195;
+static PyObject *__pyx_codeobj__197;
+static PyObject *__pyx_codeobj__199;
+static PyObject *__pyx_codeobj__205;
+static PyObject *__pyx_codeobj__207;
/* "src/lxml/lxml.etree.pyx":103
*
* u"Returns a DOCTYPE declaration string for the document."
* def __get__(self): # <<<<<<<<<<<<<<
* root_name, public_id, system_url = self._doc.getdoctype()
- * if public_id:
+ * if system_url:
*/
/* Python wrapper */
PyObject *__pyx_v_root_name = NULL;
PyObject *__pyx_v_public_id = NULL;
PyObject *__pyx_v_system_url = NULL;
+ PyObject *__pyx_v_quoted_system_url = NULL;
PyObject *__pyx_r = NULL;
__Pyx_RefNannyDeclarations
PyObject *__pyx_t_1 = NULL;
PyObject *__pyx_t_5 = NULL;
PyObject *(*__pyx_t_6)(PyObject *);
int __pyx_t_7;
+ int __pyx_t_8;
int __pyx_lineno = 0;
const char *__pyx_filename = NULL;
int __pyx_clineno = 0;
* u"Returns a DOCTYPE declaration string for the document."
* def __get__(self):
* root_name, public_id, system_url = self._doc.getdoctype() # <<<<<<<<<<<<<<
- * if public_id:
- * if system_url:
+ * if system_url:
+ * # If '"' in system_url, we must escape it with single
*/
__pyx_t_1 = __pyx_f_4lxml_5etree_9_Document_getdoctype(__pyx_v_self->_doc); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 579; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
/* "src/lxml/lxml.etree.pyx":580
* def __get__(self):
* root_name, public_id, system_url = self._doc.getdoctype()
+ * if system_url: # <<<<<<<<<<<<<<
+ * # If '"' in system_url, we must escape it with single
+ * # quotes, otherwise escape with double quotes. If url
+ */
+ __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_system_url); if (unlikely(__pyx_t_7 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 580; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__pyx_t_7) {
+
+ /* "src/lxml/lxml.etree.pyx":585
+ * # contains both a single quote and a double quote, XML
+ * # standard is being violated.
+ * if '"' in system_url: # <<<<<<<<<<<<<<
+ * quoted_system_url = u"'%s'" % system_url
+ * else:
+ */
+ __pyx_t_7 = (__Pyx_PySequence_Contains(__pyx_kp_s__25, __pyx_v_system_url, Py_EQ)); if (unlikely(__pyx_t_7 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = (__pyx_t_7 != 0);
+ if (__pyx_t_8) {
+
+ /* "src/lxml/lxml.etree.pyx":586
+ * # standard is being violated.
+ * if '"' in system_url:
+ * quoted_system_url = u"'%s'" % system_url # <<<<<<<<<<<<<<
+ * else:
+ * quoted_system_url = u'"%s"' % system_url
+ */
+ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_s, __pyx_v_system_url); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 586; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_1);
+ __pyx_v_quoted_system_url = ((PyObject*)__pyx_t_1);
+ __pyx_t_1 = 0;
+ goto __pyx_L6;
+ }
+ /*else*/ {
+
+ /* "src/lxml/lxml.etree.pyx":588
+ * quoted_system_url = u"'%s'" % system_url
+ * else:
+ * quoted_system_url = u'"%s"' % system_url # <<<<<<<<<<<<<<
+ * if public_id:
+ * if system_url:
+ */
+ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_s_2, __pyx_v_system_url); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 588; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_1);
+ __pyx_v_quoted_system_url = ((PyObject*)__pyx_t_1);
+ __pyx_t_1 = 0;
+ }
+ __pyx_L6:;
+ goto __pyx_L5;
+ }
+ __pyx_L5:;
+
+ /* "src/lxml/lxml.etree.pyx":589
+ * else:
+ * quoted_system_url = u'"%s"' % system_url
* if public_id: # <<<<<<<<<<<<<<
* if system_url:
- * return u'<!DOCTYPE %s PUBLIC "%s" "%s">' % (
+ * return u'<!DOCTYPE %s PUBLIC "%s" %s>' % (
*/
- __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_public_id); if (unlikely(__pyx_t_7 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 580; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__pyx_t_7) {
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_v_public_id); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 589; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__pyx_t_8) {
- /* "src/lxml/lxml.etree.pyx":581
- * root_name, public_id, system_url = self._doc.getdoctype()
+ /* "src/lxml/lxml.etree.pyx":590
+ * quoted_system_url = u'"%s"' % system_url
* if public_id:
* if system_url: # <<<<<<<<<<<<<<
- * return u'<!DOCTYPE %s PUBLIC "%s" "%s">' % (
- * root_name, public_id, system_url)
+ * return u'<!DOCTYPE %s PUBLIC "%s" %s>' % (
+ * root_name, public_id, quoted_system_url)
*/
- __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_system_url); if (unlikely(__pyx_t_7 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 581; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__pyx_t_7) {
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_v_system_url); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 590; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__pyx_t_8) {
- /* "src/lxml/lxml.etree.pyx":582
+ /* "src/lxml/lxml.etree.pyx":591
* if public_id:
* if system_url:
- * return u'<!DOCTYPE %s PUBLIC "%s" "%s">' % ( # <<<<<<<<<<<<<<
- * root_name, public_id, system_url)
+ * return u'<!DOCTYPE %s PUBLIC "%s" %s>' % ( # <<<<<<<<<<<<<<
+ * root_name, public_id, quoted_system_url)
* else:
*/
__Pyx_XDECREF(__pyx_r);
- /* "src/lxml/lxml.etree.pyx":583
+ /* "src/lxml/lxml.etree.pyx":592
* if system_url:
- * return u'<!DOCTYPE %s PUBLIC "%s" "%s">' % (
- * root_name, public_id, system_url) # <<<<<<<<<<<<<<
+ * return u'<!DOCTYPE %s PUBLIC "%s" %s>' % (
+ * root_name, public_id, quoted_system_url) # <<<<<<<<<<<<<<
* else:
* return u'<!DOCTYPE %s PUBLIC "%s">' % (
*/
- __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__pyx_v_quoted_system_url)) { __Pyx_RaiseUnboundLocalError("quoted_system_url"); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L1_error;} }
+ __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(__pyx_v_root_name);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_root_name);
__Pyx_INCREF(__pyx_v_public_id);
PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_public_id);
__Pyx_GIVEREF(__pyx_v_public_id);
- __Pyx_INCREF(__pyx_v_system_url);
- PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_system_url);
- __Pyx_GIVEREF(__pyx_v_system_url);
+ __Pyx_INCREF(__pyx_v_quoted_system_url);
+ PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_quoted_system_url);
+ __Pyx_GIVEREF(__pyx_v_quoted_system_url);
- /* "src/lxml/lxml.etree.pyx":582
+ /* "src/lxml/lxml.etree.pyx":591
* if public_id:
* if system_url:
- * return u'<!DOCTYPE %s PUBLIC "%s" "%s">' % ( # <<<<<<<<<<<<<<
- * root_name, public_id, system_url)
+ * return u'<!DOCTYPE %s PUBLIC "%s" %s>' % ( # <<<<<<<<<<<<<<
+ * root_name, public_id, quoted_system_url)
* else:
*/
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s_PUBLIC_s_s, __pyx_t_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 582; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s_PUBLIC_s_s, __pyx_t_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 591; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_4;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":585
- * root_name, public_id, system_url)
+ /* "src/lxml/lxml.etree.pyx":594
+ * root_name, public_id, quoted_system_url)
* else:
* return u'<!DOCTYPE %s PUBLIC "%s">' % ( # <<<<<<<<<<<<<<
* root_name, public_id)
*/
__Pyx_XDECREF(__pyx_r);
- /* "src/lxml/lxml.etree.pyx":586
+ /* "src/lxml/lxml.etree.pyx":595
* else:
* return u'<!DOCTYPE %s PUBLIC "%s">' % (
* root_name, public_id) # <<<<<<<<<<<<<<
* elif system_url:
- * return u'<!DOCTYPE %s SYSTEM "%s">' % (
+ * return u'<!DOCTYPE %s SYSTEM %s>' % (
*/
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 586; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 595; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(__pyx_v_root_name);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_root_name);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_public_id);
__Pyx_GIVEREF(__pyx_v_public_id);
- /* "src/lxml/lxml.etree.pyx":585
- * root_name, public_id, system_url)
+ /* "src/lxml/lxml.etree.pyx":594
+ * root_name, public_id, quoted_system_url)
* else:
* return u'<!DOCTYPE %s PUBLIC "%s">' % ( # <<<<<<<<<<<<<<
* root_name, public_id)
* elif system_url:
*/
- __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s_PUBLIC_s, __pyx_t_4); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s_PUBLIC_s, __pyx_t_4); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 594; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_r = __pyx_t_1;
}
}
- /* "src/lxml/lxml.etree.pyx":587
+ /* "src/lxml/lxml.etree.pyx":596
* return u'<!DOCTYPE %s PUBLIC "%s">' % (
* root_name, public_id)
* elif system_url: # <<<<<<<<<<<<<<
- * return u'<!DOCTYPE %s SYSTEM "%s">' % (
- * root_name, system_url)
+ * return u'<!DOCTYPE %s SYSTEM %s>' % (
+ * root_name, quoted_system_url)
*/
- __pyx_t_7 = __Pyx_PyObject_IsTrue(__pyx_v_system_url); if (unlikely(__pyx_t_7 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 587; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__pyx_t_7) {
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_v_system_url); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 596; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__pyx_t_8) {
- /* "src/lxml/lxml.etree.pyx":588
+ /* "src/lxml/lxml.etree.pyx":597
* root_name, public_id)
* elif system_url:
- * return u'<!DOCTYPE %s SYSTEM "%s">' % ( # <<<<<<<<<<<<<<
- * root_name, system_url)
+ * return u'<!DOCTYPE %s SYSTEM %s>' % ( # <<<<<<<<<<<<<<
+ * root_name, quoted_system_url)
* elif self._doc.hasdoctype():
*/
__Pyx_XDECREF(__pyx_r);
- /* "src/lxml/lxml.etree.pyx":589
+ /* "src/lxml/lxml.etree.pyx":598
* elif system_url:
- * return u'<!DOCTYPE %s SYSTEM "%s">' % (
- * root_name, system_url) # <<<<<<<<<<<<<<
+ * return u'<!DOCTYPE %s SYSTEM %s>' % (
+ * root_name, quoted_system_url) # <<<<<<<<<<<<<<
* elif self._doc.hasdoctype():
* return u'<!DOCTYPE %s>' % root_name
*/
- __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 589; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__pyx_v_quoted_system_url)) { __Pyx_RaiseUnboundLocalError("quoted_system_url"); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 598; __pyx_clineno = __LINE__; goto __pyx_L1_error;} }
+ __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 598; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(__pyx_v_root_name);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_root_name);
__Pyx_GIVEREF(__pyx_v_root_name);
- __Pyx_INCREF(__pyx_v_system_url);
- PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_system_url);
- __Pyx_GIVEREF(__pyx_v_system_url);
+ __Pyx_INCREF(__pyx_v_quoted_system_url);
+ PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_quoted_system_url);
+ __Pyx_GIVEREF(__pyx_v_quoted_system_url);
- /* "src/lxml/lxml.etree.pyx":588
+ /* "src/lxml/lxml.etree.pyx":597
* root_name, public_id)
* elif system_url:
- * return u'<!DOCTYPE %s SYSTEM "%s">' % ( # <<<<<<<<<<<<<<
- * root_name, system_url)
+ * return u'<!DOCTYPE %s SYSTEM %s>' % ( # <<<<<<<<<<<<<<
+ * root_name, quoted_system_url)
* elif self._doc.hasdoctype():
*/
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s_SYSTEM_s, __pyx_t_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 588; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s_SYSTEM_s, __pyx_t_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 597; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_4;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":590
- * return u'<!DOCTYPE %s SYSTEM "%s">' % (
- * root_name, system_url)
+ /* "src/lxml/lxml.etree.pyx":599
+ * return u'<!DOCTYPE %s SYSTEM %s>' % (
+ * root_name, quoted_system_url)
* elif self._doc.hasdoctype(): # <<<<<<<<<<<<<<
* return u'<!DOCTYPE %s>' % root_name
* else:
*/
- __pyx_t_7 = (__pyx_f_4lxml_5etree_9_Document_hasdoctype(__pyx_v_self->_doc) != 0);
- if (__pyx_t_7) {
+ __pyx_t_8 = (__pyx_f_4lxml_5etree_9_Document_hasdoctype(__pyx_v_self->_doc) != 0);
+ if (__pyx_t_8) {
- /* "src/lxml/lxml.etree.pyx":591
- * root_name, system_url)
+ /* "src/lxml/lxml.etree.pyx":600
+ * root_name, quoted_system_url)
* elif self._doc.hasdoctype():
* return u'<!DOCTYPE %s>' % root_name # <<<<<<<<<<<<<<
* else:
* return u""
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s, __pyx_v_root_name); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 591; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_DOCTYPE_s, __pyx_v_root_name); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 600; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":593
+ /* "src/lxml/lxml.etree.pyx":602
* return u'<!DOCTYPE %s>' % root_name
* else:
* return u"" # <<<<<<<<<<<<<<
* u"Returns a DOCTYPE declaration string for the document."
* def __get__(self): # <<<<<<<<<<<<<<
* root_name, public_id, system_url = self._doc.getdoctype()
- * if public_id:
+ * if system_url:
*/
/* function exit code */
__Pyx_XDECREF(__pyx_v_root_name);
__Pyx_XDECREF(__pyx_v_public_id);
__Pyx_XDECREF(__pyx_v_system_url);
+ __Pyx_XDECREF(__pyx_v_quoted_system_url);
__Pyx_XGIVEREF(__pyx_r);
__Pyx_RefNannyFinishContext();
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":597
+/* "src/lxml/lxml.etree.pyx":606
* property internalDTD:
* u"Returns a DTD validator based on the internal subset of the document."
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":598
+ /* "src/lxml/lxml.etree.pyx":607
* u"Returns a DTD validator based on the internal subset of the document."
* def __get__(self):
* return _dtdFactory(self._doc._c_doc.intSubset) # <<<<<<<<<<<<<<
* property externalDTD:
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__dtdFactory(__pyx_v_self->_doc->_c_doc->intSubset)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 598; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__dtdFactory(__pyx_v_self->_doc->_c_doc->intSubset)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":597
+ /* "src/lxml/lxml.etree.pyx":606
* property internalDTD:
* u"Returns a DTD validator based on the internal subset of the document."
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":602
+/* "src/lxml/lxml.etree.pyx":611
* property externalDTD:
* u"Returns a DTD validator based on the external subset of the document."
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":603
+ /* "src/lxml/lxml.etree.pyx":612
* u"Returns a DTD validator based on the external subset of the document."
* def __get__(self):
* return _dtdFactory(self._doc._c_doc.extSubset) # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__dtdFactory(__pyx_v_self->_doc->_c_doc->extSubset)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 603; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__dtdFactory(__pyx_v_self->_doc->_c_doc->extSubset)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 612; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":602
+ /* "src/lxml/lxml.etree.pyx":611
* property externalDTD:
* u"Returns a DTD validator based on the external subset of the document."
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":619
+/* "src/lxml/lxml.etree.pyx":628
* cdef object _tag
*
* def _init(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":626
+/* "src/lxml/lxml.etree.pyx":635
* """
*
* def __dealloc__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__dealloc__", 0);
- /* "src/lxml/lxml.etree.pyx":629
+ /* "src/lxml/lxml.etree.pyx":638
* #print "trying to free node:", <int>self._c_node
* #displayNode(self._c_node, 0)
* if self._c_node is not NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_c_node != NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":630
+ /* "src/lxml/lxml.etree.pyx":639
* #displayNode(self._c_node, 0)
* if self._c_node is not NULL:
* _unregisterProxy(self) # <<<<<<<<<<<<<<
* attemptDeallocation(self._c_node)
*
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__unregisterProxy(__pyx_v_self); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 630; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__unregisterProxy(__pyx_v_self); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 639; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":631
+ /* "src/lxml/lxml.etree.pyx":640
* if self._c_node is not NULL:
* _unregisterProxy(self)
* attemptDeallocation(self._c_node) # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":626
+ /* "src/lxml/lxml.etree.pyx":635
* """
*
* def __dealloc__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyFinishContext();
}
-/* "src/lxml/lxml.etree.pyx":635
+/* "src/lxml/lxml.etree.pyx":644
* # MANIPULATORS
*
* def __setitem__(self, x, value): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__setitem__", 0);
- /* "src/lxml/lxml.etree.pyx":640
+ /* "src/lxml/lxml.etree.pyx":649
* Replaces the given subelement index or slice.
* """
* cdef xmlNode* c_node = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = NULL;
- /* "src/lxml/lxml.etree.pyx":645
+ /* "src/lxml/lxml.etree.pyx":654
* cdef _Element element
* cdef bint left_to_right
* cdef Py_ssize_t slicelength = 0, step = 0 # <<<<<<<<<<<<<<
__pyx_v_slicelength = 0;
__pyx_v_step = 0;
- /* "src/lxml/lxml.etree.pyx":646
+ /* "src/lxml/lxml.etree.pyx":655
* cdef bint left_to_right
* cdef Py_ssize_t slicelength = 0, step = 0
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if value is None:
* raise ValueError, u"cannot assign None"
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 646; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":647
+ /* "src/lxml/lxml.etree.pyx":656
* cdef Py_ssize_t slicelength = 0, step = 0
* _assertValidNode(self)
* if value is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":648
+ /* "src/lxml/lxml.etree.pyx":657
* _assertValidNode(self)
* if value is None:
* raise ValueError, u"cannot assign None" # <<<<<<<<<<<<<<
* # slice assignment
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_cannot_assign_None, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 648; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 657; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":649
+ /* "src/lxml/lxml.etree.pyx":658
* if value is None:
* raise ValueError, u"cannot assign None"
* if isinstance(x, slice): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":651
+ /* "src/lxml/lxml.etree.pyx":660
* if isinstance(x, slice):
* # slice assignment
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength) # <<<<<<<<<<<<<<
* if step > 0:
* left_to_right = 1
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__findChildSlice(((PyObject*)__pyx_v_x), __pyx_v_self->_c_node, (&__pyx_v_c_node), (&__pyx_v_step), (&__pyx_v_slicelength)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 651; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__findChildSlice(((PyObject*)__pyx_v_x), __pyx_v_self->_c_node, (&__pyx_v_c_node), (&__pyx_v_step), (&__pyx_v_slicelength)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 660; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":652
+ /* "src/lxml/lxml.etree.pyx":661
* # slice assignment
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength)
* if step > 0: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_step > 0) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":653
+ /* "src/lxml/lxml.etree.pyx":662
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength)
* if step > 0:
* left_to_right = 1 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":655
+ /* "src/lxml/lxml.etree.pyx":664
* left_to_right = 1
* else:
* left_to_right = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_left_to_right = 0;
- /* "src/lxml/lxml.etree.pyx":656
+ /* "src/lxml/lxml.etree.pyx":665
* else:
* left_to_right = 0
* step = -step # <<<<<<<<<<<<<<
}
__pyx_L5:;
- /* "src/lxml/lxml.etree.pyx":657
+ /* "src/lxml/lxml.etree.pyx":666
* left_to_right = 0
* step = -step
* _replaceSlice(self, c_node, slicelength, step, left_to_right, value) # <<<<<<<<<<<<<<
* return
* else:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__replaceSlice(__pyx_v_self, __pyx_v_c_node, __pyx_v_slicelength, __pyx_v_step, __pyx_v_left_to_right, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 657; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__replaceSlice(__pyx_v_self, __pyx_v_c_node, __pyx_v_slicelength, __pyx_v_step, __pyx_v_left_to_right, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 666; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":658
+ /* "src/lxml/lxml.etree.pyx":667
* step = -step
* _replaceSlice(self, c_node, slicelength, step, left_to_right, value)
* return # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":661
+ /* "src/lxml/lxml.etree.pyx":670
* else:
* # otherwise: normal item assignment
* element = value # <<<<<<<<<<<<<<
* _assertValidNode(element)
* c_node = _findChild(self._c_node, x)
*/
- if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 661; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_4 = __pyx_v_value;
__Pyx_INCREF(__pyx_t_4);
__pyx_v_element = ((struct LxmlElement *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":662
+ /* "src/lxml/lxml.etree.pyx":671
* # otherwise: normal item assignment
* element = value
* _assertValidNode(element) # <<<<<<<<<<<<<<
* c_node = _findChild(self._c_node, x)
* if c_node is NULL:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 662; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":663
+ /* "src/lxml/lxml.etree.pyx":672
* element = value
* _assertValidNode(element)
* c_node = _findChild(self._c_node, x) # <<<<<<<<<<<<<<
* if c_node is NULL:
* raise IndexError, u"list index out of range"
*/
- __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_v_x); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 663; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_v_x); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 672; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_node = __pyx_f_4lxml_5etree__findChild(__pyx_v_self->_c_node, __pyx_t_5);
- /* "src/lxml/lxml.etree.pyx":664
+ /* "src/lxml/lxml.etree.pyx":673
* _assertValidNode(element)
* c_node = _findChild(self._c_node, x)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":665
+ /* "src/lxml/lxml.etree.pyx":674
* c_node = _findChild(self._c_node, x)
* if c_node is NULL:
* raise IndexError, u"list index out of range" # <<<<<<<<<<<<<<
* c_next = element._c_node.next
*/
__Pyx_Raise(__pyx_builtin_IndexError, __pyx_kp_u_list_index_out_of_range, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":666
+ /* "src/lxml/lxml.etree.pyx":675
* if c_node is NULL:
* raise IndexError, u"list index out of range"
* c_source_doc = element._c_node.doc # <<<<<<<<<<<<<<
__pyx_t_6 = __pyx_v_element->_c_node->doc;
__pyx_v_c_source_doc = __pyx_t_6;
- /* "src/lxml/lxml.etree.pyx":667
+ /* "src/lxml/lxml.etree.pyx":676
* raise IndexError, u"list index out of range"
* c_source_doc = element._c_node.doc
* c_next = element._c_node.next # <<<<<<<<<<<<<<
__pyx_t_7 = __pyx_v_element->_c_node->next;
__pyx_v_c_next = __pyx_t_7;
- /* "src/lxml/lxml.etree.pyx":668
+ /* "src/lxml/lxml.etree.pyx":677
* c_source_doc = element._c_node.doc
* c_next = element._c_node.next
* _removeText(c_node.next) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__removeText(__pyx_v_c_node->next);
- /* "src/lxml/lxml.etree.pyx":669
+ /* "src/lxml/lxml.etree.pyx":678
* c_next = element._c_node.next
* _removeText(c_node.next)
* tree.xmlReplaceNode(c_node, element._c_node) # <<<<<<<<<<<<<<
*/
xmlReplaceNode(__pyx_v_c_node, __pyx_v_element->_c_node);
- /* "src/lxml/lxml.etree.pyx":670
+ /* "src/lxml/lxml.etree.pyx":679
* _removeText(c_node.next)
* tree.xmlReplaceNode(c_node, element._c_node)
* _moveTail(c_next, element._c_node) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__moveTail(__pyx_v_c_next, __pyx_v_element->_c_node);
- /* "src/lxml/lxml.etree.pyx":671
+ /* "src/lxml/lxml.etree.pyx":680
* tree.xmlReplaceNode(c_node, element._c_node)
* _moveTail(c_next, element._c_node)
* moveNodeToDocument(self._doc, c_source_doc, element._c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_4 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_4);
- __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_source_doc, __pyx_v_element->_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_source_doc, __pyx_v_element->_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 680; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":672
+ /* "src/lxml/lxml.etree.pyx":681
* _moveTail(c_next, element._c_node)
* moveNodeToDocument(self._doc, c_source_doc, element._c_node)
* if not attemptDeallocation(c_node): # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(__pyx_f_4lxml_5etree_attemptDeallocation(__pyx_v_c_node) != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":673
+ /* "src/lxml/lxml.etree.pyx":682
* moveNodeToDocument(self._doc, c_source_doc, element._c_node)
* if not attemptDeallocation(c_node):
* moveNodeToDocument(self._doc, c_node.doc, c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_4 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_4);
- __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_node->doc, __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 673; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_node->doc, __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
goto __pyx_L7;
}
__pyx_L7:;
}
- /* "src/lxml/lxml.etree.pyx":635
+ /* "src/lxml/lxml.etree.pyx":644
* # MANIPULATORS
*
* def __setitem__(self, x, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":675
+/* "src/lxml/lxml.etree.pyx":684
* moveNodeToDocument(self._doc, c_node.doc, c_node)
*
* def __delitem__(self, x): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__delitem__", 0);
- /* "src/lxml/lxml.etree.pyx":680
+ /* "src/lxml/lxml.etree.pyx":689
* Deletes the given subelement or a slice.
* """
* cdef xmlNode* c_node = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = NULL;
- /* "src/lxml/lxml.etree.pyx":682
+ /* "src/lxml/lxml.etree.pyx":691
* cdef xmlNode* c_node = NULL
* cdef xmlNode* c_next
* cdef Py_ssize_t step = 0, slicelength = 0 # <<<<<<<<<<<<<<
__pyx_v_step = 0;
__pyx_v_slicelength = 0;
- /* "src/lxml/lxml.etree.pyx":683
+ /* "src/lxml/lxml.etree.pyx":692
* cdef xmlNode* c_next
* cdef Py_ssize_t step = 0, slicelength = 0
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if isinstance(x, slice):
* # slice deletion
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 692; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":684
+ /* "src/lxml/lxml.etree.pyx":693
* cdef Py_ssize_t step = 0, slicelength = 0
* _assertValidNode(self)
* if isinstance(x, slice): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":686
+ /* "src/lxml/lxml.etree.pyx":695
* if isinstance(x, slice):
* # slice deletion
* if _isFullSlice(<slice>x): # <<<<<<<<<<<<<<
* c_node = self._c_node.children
* if c_node is not NULL:
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__isFullSlice(((PyObject*)__pyx_v_x)); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 686; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__isFullSlice(((PyObject*)__pyx_v_x)); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 695; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":687
+ /* "src/lxml/lxml.etree.pyx":696
* # slice deletion
* if _isFullSlice(<slice>x):
* c_node = self._c_node.children # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_self->_c_node->children;
__pyx_v_c_node = __pyx_t_4;
- /* "src/lxml/lxml.etree.pyx":688
+ /* "src/lxml/lxml.etree.pyx":697
* if _isFullSlice(<slice>x):
* c_node = self._c_node.children
* if c_node is not NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_node != NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":689
+ /* "src/lxml/lxml.etree.pyx":698
* c_node = self._c_node.children
* if c_node is not NULL:
* if not _isElement(c_node): # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(_isElement(__pyx_v_c_node) != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":690
+ /* "src/lxml/lxml.etree.pyx":699
* if c_node is not NULL:
* if not _isElement(c_node):
* c_node = _nextElement(c_node) # <<<<<<<<<<<<<<
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":691
+ /* "src/lxml/lxml.etree.pyx":700
* if not _isElement(c_node):
* c_node = _nextElement(c_node)
* while c_node is not NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_node != NULL) != 0);
if (!__pyx_t_2) break;
- /* "src/lxml/lxml.etree.pyx":692
+ /* "src/lxml/lxml.etree.pyx":701
* c_node = _nextElement(c_node)
* while c_node is not NULL:
* c_next = _nextElement(c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_next = __pyx_f_4lxml_5etree__nextElement(__pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":693
+ /* "src/lxml/lxml.etree.pyx":702
* while c_node is not NULL:
* c_next = _nextElement(c_node)
* _removeNode(self._doc, c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_1 = __pyx_f_4lxml_5etree__removeNode(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 693; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__removeNode(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":694
+ /* "src/lxml/lxml.etree.pyx":703
* c_next = _nextElement(c_node)
* _removeNode(self._doc, c_node)
* c_node = c_next # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":696
+ /* "src/lxml/lxml.etree.pyx":705
* c_node = c_next
* else:
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength) # <<<<<<<<<<<<<<
* _deleteSlice(self._doc, c_node, slicelength, step)
* else:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__findChildSlice(((PyObject*)__pyx_v_x), __pyx_v_self->_c_node, (&__pyx_v_c_node), (&__pyx_v_step), (&__pyx_v_slicelength)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 696; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__findChildSlice(((PyObject*)__pyx_v_x), __pyx_v_self->_c_node, (&__pyx_v_c_node), (&__pyx_v_step), (&__pyx_v_slicelength)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":697
+ /* "src/lxml/lxml.etree.pyx":706
* else:
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength)
* _deleteSlice(self._doc, c_node, slicelength, step) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_1 = __pyx_f_4lxml_5etree__deleteSlice(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node, __pyx_v_slicelength, __pyx_v_step); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 697; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__deleteSlice(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node, __pyx_v_slicelength, __pyx_v_step); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 706; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__pyx_L4:;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":700
+ /* "src/lxml/lxml.etree.pyx":709
* else:
* # item deletion
* c_node = _findChild(self._c_node, x) # <<<<<<<<<<<<<<
* if c_node is NULL:
* raise IndexError, u"index out of range: %d" % x
*/
- __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_v_x); if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 700; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_v_x); if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 709; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_node = __pyx_f_4lxml_5etree__findChild(__pyx_v_self->_c_node, __pyx_t_6);
- /* "src/lxml/lxml.etree.pyx":701
+ /* "src/lxml/lxml.etree.pyx":710
* # item deletion
* c_node = _findChild(self._c_node, x)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":702
+ /* "src/lxml/lxml.etree.pyx":711
* c_node = _findChild(self._c_node, x)
* if c_node is NULL:
* raise IndexError, u"index out of range: %d" % x # <<<<<<<<<<<<<<
* _removeText(c_node.next)
* _removeNode(self._doc, c_node)
*/
- __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_index_out_of_range_d, __pyx_v_x); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_index_out_of_range_d, __pyx_v_x); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 711; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_Raise(__pyx_builtin_IndexError, __pyx_t_5, 0, 0);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 711; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":703
+ /* "src/lxml/lxml.etree.pyx":712
* if c_node is NULL:
* raise IndexError, u"index out of range: %d" % x
* _removeText(c_node.next) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__removeText(__pyx_v_c_node->next);
- /* "src/lxml/lxml.etree.pyx":704
+ /* "src/lxml/lxml.etree.pyx":713
* raise IndexError, u"index out of range: %d" % x
* _removeText(c_node.next)
* _removeNode(self._doc, c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_1 = __pyx_f_4lxml_5etree__removeNode(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 704; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__removeNode(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 713; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":675
+ /* "src/lxml/lxml.etree.pyx":684
* moveNodeToDocument(self._doc, c_node.doc, c_node)
*
* def __delitem__(self, x): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":706
+/* "src/lxml/lxml.etree.pyx":715
* _removeNode(self._doc, c_node)
*
* def __deepcopy__(self, memo): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__deepcopy__", 0);
- /* "src/lxml/lxml.etree.pyx":708
+ /* "src/lxml/lxml.etree.pyx":717
* def __deepcopy__(self, memo):
* u"__deepcopy__(self, memo)"
* return self.__copy__() # <<<<<<<<<<<<<<
* def __copy__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_copy_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 708; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_copy_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 717; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_3 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
}
}
if (__pyx_t_3) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 708; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 717; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
} else {
- __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 708; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 717; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":706
+ /* "src/lxml/lxml.etree.pyx":715
* _removeNode(self._doc, c_node)
*
* def __deepcopy__(self, memo): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":710
+/* "src/lxml/lxml.etree.pyx":719
* return self.__copy__()
*
* def __copy__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__copy__", 0);
- /* "src/lxml/lxml.etree.pyx":715
+ /* "src/lxml/lxml.etree.pyx":724
* cdef xmlNode* c_node
* cdef _Document new_doc
* _assertValidNode(self) # <<<<<<<<<<<<<<
* c_doc = _copyDocRoot(self._doc._c_doc, self._c_node) # recursive
* new_doc = _documentFactory(c_doc, self._doc._parser)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":716
+ /* "src/lxml/lxml.etree.pyx":725
* cdef _Document new_doc
* _assertValidNode(self)
* c_doc = _copyDocRoot(self._doc._c_doc, self._c_node) # recursive # <<<<<<<<<<<<<<
* new_doc = _documentFactory(c_doc, self._doc._parser)
* root = new_doc.getroot()
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__copyDocRoot(__pyx_v_self->_doc->_c_doc, __pyx_v_self->_c_node); if (unlikely(__pyx_t_2 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 716; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__copyDocRoot(__pyx_v_self->_doc->_c_doc, __pyx_v_self->_c_node); if (unlikely(__pyx_t_2 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 725; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":717
+ /* "src/lxml/lxml.etree.pyx":726
* _assertValidNode(self)
* c_doc = _copyDocRoot(self._doc._c_doc, self._c_node) # recursive
* new_doc = _documentFactory(c_doc, self._doc._parser) # <<<<<<<<<<<<<<
*/
__pyx_t_3 = ((PyObject *)__pyx_v_self->_doc->_parser);
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_3))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 717; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_3))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 726; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_new_doc = ((struct LxmlDocument *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":718
+ /* "src/lxml/lxml.etree.pyx":727
* c_doc = _copyDocRoot(self._doc._c_doc, self._c_node) # recursive
* new_doc = _documentFactory(c_doc, self._doc._parser)
* root = new_doc.getroot() # <<<<<<<<<<<<<<
* if root is not None:
* return root
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_new_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 718; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_new_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_root = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":719
+ /* "src/lxml/lxml.etree.pyx":728
* new_doc = _documentFactory(c_doc, self._doc._parser)
* root = new_doc.getroot()
* if root is not None: # <<<<<<<<<<<<<<
__pyx_t_6 = (__pyx_t_5 != 0);
if (__pyx_t_6) {
- /* "src/lxml/lxml.etree.pyx":720
+ /* "src/lxml/lxml.etree.pyx":729
* root = new_doc.getroot()
* if root is not None:
* return root # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":722
+ /* "src/lxml/lxml.etree.pyx":731
* return root
* # Comment/PI
* c_node = c_doc.children # <<<<<<<<<<<<<<
__pyx_t_7 = __pyx_v_c_doc->children;
__pyx_v_c_node = __pyx_t_7;
- /* "src/lxml/lxml.etree.pyx":723
+ /* "src/lxml/lxml.etree.pyx":732
* # Comment/PI
* c_node = c_doc.children
* while c_node is not NULL and c_node.type != self._c_node.type: # <<<<<<<<<<<<<<
__pyx_L6_bool_binop_done:;
if (!__pyx_t_6) break;
- /* "src/lxml/lxml.etree.pyx":724
+ /* "src/lxml/lxml.etree.pyx":733
* c_node = c_doc.children
* while c_node is not NULL and c_node.type != self._c_node.type:
* c_node = c_node.next # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_t_7;
}
- /* "src/lxml/lxml.etree.pyx":725
+ /* "src/lxml/lxml.etree.pyx":734
* while c_node is not NULL and c_node.type != self._c_node.type:
* c_node = c_node.next
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_6 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_6) {
- /* "src/lxml/lxml.etree.pyx":726
+ /* "src/lxml/lxml.etree.pyx":735
* c_node = c_node.next
* if c_node is NULL:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":727
+ /* "src/lxml/lxml.etree.pyx":736
* if c_node is NULL:
* return None
* return _elementFactory(new_doc, c_node) # <<<<<<<<<<<<<<
* def set(self, key, value):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_new_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_new_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":710
+ /* "src/lxml/lxml.etree.pyx":719
* return self.__copy__()
*
* def __copy__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":729
+/* "src/lxml/lxml.etree.pyx":738
* return _elementFactory(new_doc, c_node)
*
* def set(self, key, value): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 729; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.set", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("set", 0);
- /* "src/lxml/lxml.etree.pyx":734
+ /* "src/lxml/lxml.etree.pyx":743
* Sets an element attribute.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _setAttributeValue(self, key, value)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":735
+ /* "src/lxml/lxml.etree.pyx":744
* """
* _assertValidNode(self)
* _setAttributeValue(self, key, value) # <<<<<<<<<<<<<<
*
* def append(self, _Element element not None):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__setAttributeValue(__pyx_v_self, __pyx_v_key, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__setAttributeValue(__pyx_v_self, __pyx_v_key, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":729
+ /* "src/lxml/lxml.etree.pyx":738
* return _elementFactory(new_doc, c_node)
*
* def set(self, key, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":737
+/* "src/lxml/lxml.etree.pyx":746
* _setAttributeValue(self, key, value)
*
* def append(self, _Element element not None): # <<<<<<<<<<<<<<
PyObject *__pyx_r = 0;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("append (wrapper)", 0);
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_14append(((struct LxmlElement *)__pyx_v_self), ((struct LxmlElement *)__pyx_v_element));
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("append", 0);
- /* "src/lxml/lxml.etree.pyx":742
+ /* "src/lxml/lxml.etree.pyx":751
* Adds a subelement to the end of this element.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _assertValidNode(element)
* _appendChild(self, element)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":743
+ /* "src/lxml/lxml.etree.pyx":752
* """
* _assertValidNode(self)
* _assertValidNode(element) # <<<<<<<<<<<<<<
* _appendChild(self, element)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 752; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":744
+ /* "src/lxml/lxml.etree.pyx":753
* _assertValidNode(self)
* _assertValidNode(element)
* _appendChild(self, element) # <<<<<<<<<<<<<<
*
* def addnext(self, _Element element not None):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__appendChild(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__appendChild(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 753; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":737
+ /* "src/lxml/lxml.etree.pyx":746
* _setAttributeValue(self, key, value)
*
* def append(self, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":746
+/* "src/lxml/lxml.etree.pyx":755
* _appendChild(self, element)
*
* def addnext(self, _Element element not None): # <<<<<<<<<<<<<<
PyObject *__pyx_r = 0;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("addnext (wrapper)", 0);
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 755; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_16addnext(((struct LxmlElement *)__pyx_v_self), ((struct LxmlElement *)__pyx_v_element));
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("addnext", 0);
- /* "src/lxml/lxml.etree.pyx":756
+ /* "src/lxml/lxml.etree.pyx":765
* discarded when adding at the root level.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _assertValidNode(element)
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 756; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 765; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":757
+ /* "src/lxml/lxml.etree.pyx":766
* """
* _assertValidNode(self)
* _assertValidNode(element) # <<<<<<<<<<<<<<
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
* if element._c_node.type != tree.XML_PI_NODE:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 757; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 766; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":758
+ /* "src/lxml/lxml.etree.pyx":767
* _assertValidNode(self)
* _assertValidNode(element)
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent): # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":759
+ /* "src/lxml/lxml.etree.pyx":768
* _assertValidNode(element)
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
* if element._c_node.type != tree.XML_PI_NODE: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_element->_c_node->type != XML_PI_NODE) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":760
+ /* "src/lxml/lxml.etree.pyx":769
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
* if element._c_node.type != tree.XML_PI_NODE:
* if element._c_node.type != tree.XML_COMMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_element->_c_node->type != XML_COMMENT_NODE) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":761
+ /* "src/lxml/lxml.etree.pyx":770
* if element._c_node.type != tree.XML_PI_NODE:
* if element._c_node.type != tree.XML_COMMENT_NODE:
* raise TypeError, u"Only processing instructions and comments can be siblings of the root element" # <<<<<<<<<<<<<<
* _appendSibling(self, element)
*/
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_u_Only_processing_instructions_and, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 761; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 770; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L6;
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":762
+ /* "src/lxml/lxml.etree.pyx":771
* if element._c_node.type != tree.XML_COMMENT_NODE:
* raise TypeError, u"Only processing instructions and comments can be siblings of the root element"
* element.tail = None # <<<<<<<<<<<<<<
* _appendSibling(self, element)
*
*/
- if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_tail, Py_None) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 762; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_tail, Py_None) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 771; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L3;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":763
+ /* "src/lxml/lxml.etree.pyx":772
* raise TypeError, u"Only processing instructions and comments can be siblings of the root element"
* element.tail = None
* _appendSibling(self, element) # <<<<<<<<<<<<<<
*
* def addprevious(self, _Element element not None):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__appendSibling(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 763; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__appendSibling(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 772; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":746
+ /* "src/lxml/lxml.etree.pyx":755
* _appendChild(self, element)
*
* def addnext(self, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":765
+/* "src/lxml/lxml.etree.pyx":774
* _appendSibling(self, element)
*
* def addprevious(self, _Element element not None): # <<<<<<<<<<<<<<
PyObject *__pyx_r = 0;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("addprevious (wrapper)", 0);
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 765; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 774; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_18addprevious(((struct LxmlElement *)__pyx_v_self), ((struct LxmlElement *)__pyx_v_element));
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("addprevious", 0);
- /* "src/lxml/lxml.etree.pyx":775
+ /* "src/lxml/lxml.etree.pyx":784
* automatically discarded when adding at the root level.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _assertValidNode(element)
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 775; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 784; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":776
+ /* "src/lxml/lxml.etree.pyx":785
* """
* _assertValidNode(self)
* _assertValidNode(element) # <<<<<<<<<<<<<<
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
* if element._c_node.type != tree.XML_PI_NODE:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 776; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 785; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":777
+ /* "src/lxml/lxml.etree.pyx":786
* _assertValidNode(self)
* _assertValidNode(element)
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent): # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":778
+ /* "src/lxml/lxml.etree.pyx":787
* _assertValidNode(element)
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
* if element._c_node.type != tree.XML_PI_NODE: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_element->_c_node->type != XML_PI_NODE) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":779
+ /* "src/lxml/lxml.etree.pyx":788
* if self._c_node.parent != NULL and not _isElement(self._c_node.parent):
* if element._c_node.type != tree.XML_PI_NODE:
* if element._c_node.type != tree.XML_COMMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_element->_c_node->type != XML_COMMENT_NODE) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":780
+ /* "src/lxml/lxml.etree.pyx":789
* if element._c_node.type != tree.XML_PI_NODE:
* if element._c_node.type != tree.XML_COMMENT_NODE:
* raise TypeError, u"Only processing instructions and comments can be siblings of the root element" # <<<<<<<<<<<<<<
* _prependSibling(self, element)
*/
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_u_Only_processing_instructions_and, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L6;
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":781
+ /* "src/lxml/lxml.etree.pyx":790
* if element._c_node.type != tree.XML_COMMENT_NODE:
* raise TypeError, u"Only processing instructions and comments can be siblings of the root element"
* element.tail = None # <<<<<<<<<<<<<<
* _prependSibling(self, element)
*
*/
- if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_tail, Py_None) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 781; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_tail, Py_None) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L3;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":782
+ /* "src/lxml/lxml.etree.pyx":791
* raise TypeError, u"Only processing instructions and comments can be siblings of the root element"
* element.tail = None
* _prependSibling(self, element) # <<<<<<<<<<<<<<
*
* def extend(self, elements):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__prependSibling(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 782; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__prependSibling(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":765
+ /* "src/lxml/lxml.etree.pyx":774
* _appendSibling(self, element)
*
* def addprevious(self, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":784
+/* "src/lxml/lxml.etree.pyx":793
* _prependSibling(self, element)
*
* def extend(self, elements): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("extend", 0);
- /* "src/lxml/lxml.etree.pyx":790
+ /* "src/lxml/lxml.etree.pyx":799
* """
* cdef _Element element
* _assertValidNode(self) # <<<<<<<<<<<<<<
* for element in elements:
* if element is None:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 799; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":791
+ /* "src/lxml/lxml.etree.pyx":800
* cdef _Element element
* _assertValidNode(self)
* for element in elements: # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_elements; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0;
__pyx_t_4 = NULL;
} else {
- __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_v_elements); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_v_elements); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
for (;;) {
if (likely(!__pyx_t_4)) {
if (likely(PyList_CheckExact(__pyx_t_2))) {
if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_5 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_5 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
} else {
if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_5 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
}
} else {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
break;
}
__Pyx_GOTREF(__pyx_t_5);
}
- if (!(likely(((__pyx_t_5) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_5, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_5) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_5, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_XDECREF_SET(__pyx_v_element, ((struct LxmlElement *)__pyx_t_5));
__pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":792
+ /* "src/lxml/lxml.etree.pyx":801
* _assertValidNode(self)
* for element in elements:
* if element is None: # <<<<<<<<<<<<<<
__pyx_t_7 = (__pyx_t_6 != 0);
if (__pyx_t_7) {
- /* "src/lxml/lxml.etree.pyx":793
+ /* "src/lxml/lxml.etree.pyx":802
* for element in elements:
* if element is None:
* raise TypeError, u"Node must not be None" # <<<<<<<<<<<<<<
* _appendChild(self, element)
*/
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_u_Node_must_not_be_None, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":794
+ /* "src/lxml/lxml.etree.pyx":803
* if element is None:
* raise TypeError, u"Node must not be None"
* _assertValidNode(element) # <<<<<<<<<<<<<<
* _appendChild(self, element)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 803; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":795
+ /* "src/lxml/lxml.etree.pyx":804
* raise TypeError, u"Node must not be None"
* _assertValidNode(element)
* _appendChild(self, element) # <<<<<<<<<<<<<<
*
* def clear(self):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__appendChild(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 795; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__appendChild(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":791
+ /* "src/lxml/lxml.etree.pyx":800
* cdef _Element element
* _assertValidNode(self)
* for element in elements: # <<<<<<<<<<<<<<
}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":784
+ /* "src/lxml/lxml.etree.pyx":793
* _prependSibling(self, element)
*
* def extend(self, elements): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":797
+/* "src/lxml/lxml.etree.pyx":806
* _appendChild(self, element)
*
* def clear(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("clear", 0);
- /* "src/lxml/lxml.etree.pyx":807
+ /* "src/lxml/lxml.etree.pyx":816
* cdef xmlNode* c_node
* cdef xmlNode* c_node_next
* _assertValidNode(self) # <<<<<<<<<<<<<<
* c_node = self._c_node
* # remove self.text and self.tail
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 807; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 816; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":808
+ /* "src/lxml/lxml.etree.pyx":817
* cdef xmlNode* c_node_next
* _assertValidNode(self)
* c_node = self._c_node # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_self->_c_node;
__pyx_v_c_node = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":810
+ /* "src/lxml/lxml.etree.pyx":819
* c_node = self._c_node
* # remove self.text and self.tail
* _removeText(c_node.children) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__removeText(__pyx_v_c_node->children);
- /* "src/lxml/lxml.etree.pyx":811
+ /* "src/lxml/lxml.etree.pyx":820
* # remove self.text and self.tail
* _removeText(c_node.children)
* _removeText(c_node.next) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__removeText(__pyx_v_c_node->next);
- /* "src/lxml/lxml.etree.pyx":813
+ /* "src/lxml/lxml.etree.pyx":822
* _removeText(c_node.next)
* # remove all attributes
* c_attr = c_node.properties # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_c_node->properties;
__pyx_v_c_attr = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":814
+ /* "src/lxml/lxml.etree.pyx":823
* # remove all attributes
* c_attr = c_node.properties
* while c_attr is not NULL: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_attr != NULL) != 0);
if (!__pyx_t_4) break;
- /* "src/lxml/lxml.etree.pyx":815
+ /* "src/lxml/lxml.etree.pyx":824
* c_attr = c_node.properties
* while c_attr is not NULL:
* c_attr_next = c_attr.next # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_c_attr->next;
__pyx_v_c_attr_next = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":816
+ /* "src/lxml/lxml.etree.pyx":825
* while c_attr is not NULL:
* c_attr_next = c_attr.next
* tree.xmlRemoveProp(c_attr) # <<<<<<<<<<<<<<
*/
xmlRemoveProp(__pyx_v_c_attr);
- /* "src/lxml/lxml.etree.pyx":817
+ /* "src/lxml/lxml.etree.pyx":826
* c_attr_next = c_attr.next
* tree.xmlRemoveProp(c_attr)
* c_attr = c_attr_next # <<<<<<<<<<<<<<
__pyx_v_c_attr = __pyx_v_c_attr_next;
}
- /* "src/lxml/lxml.etree.pyx":819
+ /* "src/lxml/lxml.etree.pyx":828
* c_attr = c_attr_next
* # remove all subelements
* c_node = c_node.children # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_c_node->children;
__pyx_v_c_node = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":820
+ /* "src/lxml/lxml.etree.pyx":829
* # remove all subelements
* c_node = c_node.children
* if c_node is not NULL: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_node != NULL) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":821
+ /* "src/lxml/lxml.etree.pyx":830
* c_node = c_node.children
* if c_node is not NULL:
* if not _isElement(c_node): # <<<<<<<<<<<<<<
__pyx_t_4 = ((!(_isElement(__pyx_v_c_node) != 0)) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":822
+ /* "src/lxml/lxml.etree.pyx":831
* if c_node is not NULL:
* if not _isElement(c_node):
* c_node = _nextElement(c_node) # <<<<<<<<<<<<<<
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":823
+ /* "src/lxml/lxml.etree.pyx":832
* if not _isElement(c_node):
* c_node = _nextElement(c_node)
* while c_node is not NULL: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_node != NULL) != 0);
if (!__pyx_t_4) break;
- /* "src/lxml/lxml.etree.pyx":824
+ /* "src/lxml/lxml.etree.pyx":833
* c_node = _nextElement(c_node)
* while c_node is not NULL:
* c_node_next = _nextElement(c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node_next = __pyx_f_4lxml_5etree__nextElement(__pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":825
+ /* "src/lxml/lxml.etree.pyx":834
* while c_node is not NULL:
* c_node_next = _nextElement(c_node)
* _removeNode(self._doc, c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_1 = __pyx_f_4lxml_5etree__removeNode(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 825; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__removeNode(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 834; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":826
+ /* "src/lxml/lxml.etree.pyx":835
* c_node_next = _nextElement(c_node)
* _removeNode(self._doc, c_node)
* c_node = c_node_next # <<<<<<<<<<<<<<
}
__pyx_L5:;
- /* "src/lxml/lxml.etree.pyx":797
+ /* "src/lxml/lxml.etree.pyx":806
* _appendChild(self, element)
*
* def clear(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":828
+/* "src/lxml/lxml.etree.pyx":837
* c_node = c_node_next
*
* def insert(self, index, _Element element not None): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_element)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "insert") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "insert") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.insert", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_24insert(((struct LxmlElement *)__pyx_v_self), __pyx_v_index, __pyx_v_element);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("insert", 0);
- /* "src/lxml/lxml.etree.pyx":836
+ /* "src/lxml/lxml.etree.pyx":845
* cdef xmlNode* c_next
* cdef xmlDoc* c_source_doc
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _assertValidNode(element)
* c_node = _findChild(self._c_node, index)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 845; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":837
+ /* "src/lxml/lxml.etree.pyx":846
* cdef xmlDoc* c_source_doc
* _assertValidNode(self)
* _assertValidNode(element) # <<<<<<<<<<<<<<
* c_node = _findChild(self._c_node, index)
* if c_node is NULL:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":838
+ /* "src/lxml/lxml.etree.pyx":847
* _assertValidNode(self)
* _assertValidNode(element)
* c_node = _findChild(self._c_node, index) # <<<<<<<<<<<<<<
* if c_node is NULL:
* _appendChild(self, element)
*/
- __pyx_t_2 = __Pyx_PyIndex_AsSsize_t(__pyx_v_index); if (unlikely((__pyx_t_2 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyIndex_AsSsize_t(__pyx_v_index); if (unlikely((__pyx_t_2 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_node = __pyx_f_4lxml_5etree__findChild(__pyx_v_self->_c_node, __pyx_t_2);
- /* "src/lxml/lxml.etree.pyx":839
+ /* "src/lxml/lxml.etree.pyx":848
* _assertValidNode(element)
* c_node = _findChild(self._c_node, index)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":840
+ /* "src/lxml/lxml.etree.pyx":849
* c_node = _findChild(self._c_node, index)
* if c_node is NULL:
* _appendChild(self, element) # <<<<<<<<<<<<<<
* return
* c_source_doc = c_node.doc
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__appendChild(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__appendChild(__pyx_v_self, __pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":841
+ /* "src/lxml/lxml.etree.pyx":850
* if c_node is NULL:
* _appendChild(self, element)
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":842
+ /* "src/lxml/lxml.etree.pyx":851
* _appendChild(self, element)
* return
* c_source_doc = c_node.doc # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_c_node->doc;
__pyx_v_c_source_doc = __pyx_t_4;
- /* "src/lxml/lxml.etree.pyx":843
+ /* "src/lxml/lxml.etree.pyx":852
* return
* c_source_doc = c_node.doc
* c_next = element._c_node.next # <<<<<<<<<<<<<<
__pyx_t_5 = __pyx_v_element->_c_node->next;
__pyx_v_c_next = __pyx_t_5;
- /* "src/lxml/lxml.etree.pyx":844
+ /* "src/lxml/lxml.etree.pyx":853
* c_source_doc = c_node.doc
* c_next = element._c_node.next
* tree.xmlAddPrevSibling(c_node, element._c_node) # <<<<<<<<<<<<<<
*/
xmlAddPrevSibling(__pyx_v_c_node, __pyx_v_element->_c_node);
- /* "src/lxml/lxml.etree.pyx":845
+ /* "src/lxml/lxml.etree.pyx":854
* c_next = element._c_node.next
* tree.xmlAddPrevSibling(c_node, element._c_node)
* _moveTail(c_next, element._c_node) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__moveTail(__pyx_v_c_next, __pyx_v_element->_c_node);
- /* "src/lxml/lxml.etree.pyx":846
+ /* "src/lxml/lxml.etree.pyx":855
* tree.xmlAddPrevSibling(c_node, element._c_node)
* _moveTail(c_next, element._c_node)
* moveNodeToDocument(self._doc, c_source_doc, element._c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_6 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_6);
- __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_6), __pyx_v_c_source_doc, __pyx_v_element->_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_6), __pyx_v_c_source_doc, __pyx_v_element->_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":828
+ /* "src/lxml/lxml.etree.pyx":837
* c_node = c_node_next
*
* def insert(self, index, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":848
+/* "src/lxml/lxml.etree.pyx":857
* moveNodeToDocument(self._doc, c_source_doc, element._c_node)
*
* def remove(self, _Element element not None): # <<<<<<<<<<<<<<
PyObject *__pyx_r = 0;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("remove (wrapper)", 0);
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_26remove(((struct LxmlElement *)__pyx_v_self), ((struct LxmlElement *)__pyx_v_element));
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("remove", 0);
- /* "src/lxml/lxml.etree.pyx":857
+ /* "src/lxml/lxml.etree.pyx":866
* cdef xmlNode* c_node
* cdef xmlNode* c_next
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _assertValidNode(element)
* c_node = element._c_node
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 866; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":858
+ /* "src/lxml/lxml.etree.pyx":867
* cdef xmlNode* c_next
* _assertValidNode(self)
* _assertValidNode(element) # <<<<<<<<<<<<<<
* c_node = element._c_node
* if c_node.parent is not self._c_node:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 858; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 867; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":859
+ /* "src/lxml/lxml.etree.pyx":868
* _assertValidNode(self)
* _assertValidNode(element)
* c_node = element._c_node # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_element->_c_node;
__pyx_v_c_node = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":860
+ /* "src/lxml/lxml.etree.pyx":869
* _assertValidNode(element)
* c_node = element._c_node
* if c_node.parent is not self._c_node: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node->parent != __pyx_v_self->_c_node) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":861
+ /* "src/lxml/lxml.etree.pyx":870
* c_node = element._c_node
* if c_node.parent is not self._c_node:
* raise ValueError, u"Element is not a child of this node." # <<<<<<<<<<<<<<
* tree.xmlUnlinkNode(c_node)
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_a_child_of_this_n, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 861; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 870; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":862
+ /* "src/lxml/lxml.etree.pyx":871
* if c_node.parent is not self._c_node:
* raise ValueError, u"Element is not a child of this node."
* c_next = element._c_node.next # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_element->_c_node->next;
__pyx_v_c_next = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":863
+ /* "src/lxml/lxml.etree.pyx":872
* raise ValueError, u"Element is not a child of this node."
* c_next = element._c_node.next
* tree.xmlUnlinkNode(c_node) # <<<<<<<<<<<<<<
*/
xmlUnlinkNode(__pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":864
+ /* "src/lxml/lxml.etree.pyx":873
* c_next = element._c_node.next
* tree.xmlUnlinkNode(c_node)
* _moveTail(c_next, c_node) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__moveTail(__pyx_v_c_next, __pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":866
+ /* "src/lxml/lxml.etree.pyx":875
* _moveTail(c_next, c_node)
* # fix namespace declarations
* moveNodeToDocument(self._doc, c_node.doc, c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_4 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_4);
- __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_node->doc, __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 866; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_node->doc, __pyx_v_c_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 875; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":848
+ /* "src/lxml/lxml.etree.pyx":857
* moveNodeToDocument(self._doc, c_source_doc, element._c_node)
*
* def remove(self, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":868
+/* "src/lxml/lxml.etree.pyx":877
* moveNodeToDocument(self._doc, c_node.doc, c_node)
*
* def replace(self, _Element old_element not None, # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_new_element)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("replace", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("replace", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 877; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "replace") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "replace") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 877; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("replace", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("replace", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 877; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.replace", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_old_element), __pyx_ptype_4lxml_5etree__Element, 0, "old_element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_new_element), __pyx_ptype_4lxml_5etree__Element, 0, "new_element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 869; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_old_element), __pyx_ptype_4lxml_5etree__Element, 0, "old_element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 877; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_new_element), __pyx_ptype_4lxml_5etree__Element, 0, "new_element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 878; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_28replace(((struct LxmlElement *)__pyx_v_self), __pyx_v_old_element, __pyx_v_new_element);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("replace", 0);
- /* "src/lxml/lxml.etree.pyx":879
+ /* "src/lxml/lxml.etree.pyx":888
* cdef xmlNode* c_new_next
* cdef xmlDoc* c_source_doc
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _assertValidNode(old_element)
* _assertValidNode(new_element)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 879; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":880
+ /* "src/lxml/lxml.etree.pyx":889
* cdef xmlDoc* c_source_doc
* _assertValidNode(self)
* _assertValidNode(old_element) # <<<<<<<<<<<<<<
* _assertValidNode(new_element)
* c_old_node = old_element._c_node
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_old_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 880; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_old_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 889; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":881
+ /* "src/lxml/lxml.etree.pyx":890
* _assertValidNode(self)
* _assertValidNode(old_element)
* _assertValidNode(new_element) # <<<<<<<<<<<<<<
* c_old_node = old_element._c_node
* if c_old_node.parent is not self._c_node:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_new_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 881; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_new_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 890; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":882
+ /* "src/lxml/lxml.etree.pyx":891
* _assertValidNode(old_element)
* _assertValidNode(new_element)
* c_old_node = old_element._c_node # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_old_element->_c_node;
__pyx_v_c_old_node = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":883
+ /* "src/lxml/lxml.etree.pyx":892
* _assertValidNode(new_element)
* c_old_node = old_element._c_node
* if c_old_node.parent is not self._c_node: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_old_node->parent != __pyx_v_self->_c_node) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":884
+ /* "src/lxml/lxml.etree.pyx":893
* c_old_node = old_element._c_node
* if c_old_node.parent is not self._c_node:
* raise ValueError, u"Element is not a child of this node." # <<<<<<<<<<<<<<
* c_new_node = new_element._c_node
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_a_child_of_this_n, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 884; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":885
+ /* "src/lxml/lxml.etree.pyx":894
* if c_old_node.parent is not self._c_node:
* raise ValueError, u"Element is not a child of this node."
* c_old_next = c_old_node.next # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_c_old_node->next;
__pyx_v_c_old_next = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":886
+ /* "src/lxml/lxml.etree.pyx":895
* raise ValueError, u"Element is not a child of this node."
* c_old_next = c_old_node.next
* c_new_node = new_element._c_node # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_new_element->_c_node;
__pyx_v_c_new_node = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":887
+ /* "src/lxml/lxml.etree.pyx":896
* c_old_next = c_old_node.next
* c_new_node = new_element._c_node
* c_new_next = c_new_node.next # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_c_new_node->next;
__pyx_v_c_new_next = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":888
+ /* "src/lxml/lxml.etree.pyx":897
* c_new_node = new_element._c_node
* c_new_next = c_new_node.next
* c_source_doc = c_new_node.doc # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_c_new_node->doc;
__pyx_v_c_source_doc = __pyx_t_4;
- /* "src/lxml/lxml.etree.pyx":889
+ /* "src/lxml/lxml.etree.pyx":898
* c_new_next = c_new_node.next
* c_source_doc = c_new_node.doc
* tree.xmlReplaceNode(c_old_node, c_new_node) # <<<<<<<<<<<<<<
*/
xmlReplaceNode(__pyx_v_c_old_node, __pyx_v_c_new_node);
- /* "src/lxml/lxml.etree.pyx":890
+ /* "src/lxml/lxml.etree.pyx":899
* c_source_doc = c_new_node.doc
* tree.xmlReplaceNode(c_old_node, c_new_node)
* _moveTail(c_new_next, c_new_node) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__moveTail(__pyx_v_c_new_next, __pyx_v_c_new_node);
- /* "src/lxml/lxml.etree.pyx":891
+ /* "src/lxml/lxml.etree.pyx":900
* tree.xmlReplaceNode(c_old_node, c_new_node)
* _moveTail(c_new_next, c_new_node)
* _moveTail(c_old_next, c_old_node) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__moveTail(__pyx_v_c_old_next, __pyx_v_c_old_node);
- /* "src/lxml/lxml.etree.pyx":892
+ /* "src/lxml/lxml.etree.pyx":901
* _moveTail(c_new_next, c_new_node)
* _moveTail(c_old_next, c_old_node)
* moveNodeToDocument(self._doc, c_source_doc, c_new_node) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_source_doc, __pyx_v_c_new_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 892; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_source_doc, __pyx_v_c_new_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":894
+ /* "src/lxml/lxml.etree.pyx":903
* moveNodeToDocument(self._doc, c_source_doc, c_new_node)
* # fix namespace declarations
* moveNodeToDocument(self._doc, c_old_node.doc, c_old_node) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_old_node->doc, __pyx_v_c_old_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 894; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_moveNodeToDocument(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_old_node->doc, __pyx_v_c_old_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":868
+ /* "src/lxml/lxml.etree.pyx":877
* moveNodeToDocument(self._doc, c_node.doc, c_node)
*
* def replace(self, _Element old_element not None, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":900
+/* "src/lxml/lxml.etree.pyx":909
* u"""Element tag
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":901
+ /* "src/lxml/lxml.etree.pyx":910
* """
* def __get__(self):
* if self._tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":902
+ /* "src/lxml/lxml.etree.pyx":911
* def __get__(self):
* if self._tag is not None:
* return self._tag # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":903
+ /* "src/lxml/lxml.etree.pyx":912
* if self._tag is not None:
* return self._tag
* _assertValidNode(self) # <<<<<<<<<<<<<<
* self._tag = _namespacedName(self._c_node)
* return self._tag
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 912; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":904
+ /* "src/lxml/lxml.etree.pyx":913
* return self._tag
* _assertValidNode(self)
* self._tag = _namespacedName(self._c_node) # <<<<<<<<<<<<<<
* return self._tag
*
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedName(__pyx_v_self->_c_node); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedName(__pyx_v_self->_c_node); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_GIVEREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_v_self->_tag);
__pyx_v_self->_tag = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":905
+ /* "src/lxml/lxml.etree.pyx":914
* _assertValidNode(self)
* self._tag = _namespacedName(self._c_node)
* return self._tag # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_self->_tag;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":900
+ /* "src/lxml/lxml.etree.pyx":909
* u"""Element tag
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":907
+/* "src/lxml/lxml.etree.pyx":916
* return self._tag
*
* def __set__(self, value): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__set__", 0);
- /* "src/lxml/lxml.etree.pyx":909
+ /* "src/lxml/lxml.etree.pyx":918
* def __set__(self, value):
* cdef _BaseParser parser
* _assertValidNode(self) # <<<<<<<<<<<<<<
* ns, name = _getNsTag(value)
* parser = self._doc._parser
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":910
+ /* "src/lxml/lxml.etree.pyx":919
* cdef _BaseParser parser
* _assertValidNode(self)
* ns, name = _getNsTag(value) # <<<<<<<<<<<<<<
* parser = self._doc._parser
* if parser is not None and parser._for_html:
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
if (likely(__pyx_t_2 != Py_None)) {
PyObject* sequence = __pyx_t_2;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
__pyx_t_3 = PyTuple_GET_ITEM(sequence, 0);
__Pyx_INCREF(__pyx_t_3);
__Pyx_INCREF(__pyx_t_4);
#else
- __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
#endif
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
} else {
- __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_v_ns = __pyx_t_3;
__pyx_t_3 = 0;
__pyx_v_name = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":911
+ /* "src/lxml/lxml.etree.pyx":920
* _assertValidNode(self)
* ns, name = _getNsTag(value)
* parser = self._doc._parser # <<<<<<<<<<<<<<
__pyx_v_parser = ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":912
+ /* "src/lxml/lxml.etree.pyx":921
* ns, name = _getNsTag(value)
* parser = self._doc._parser
* if parser is not None and parser._for_html: # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":913
+ /* "src/lxml/lxml.etree.pyx":922
* parser = self._doc._parser
* if parser is not None and parser._for_html:
* _htmlTagValidOrRaise(name) # <<<<<<<<<<<<<<
* else:
* _tagValidOrRaise(name)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__htmlTagValidOrRaise(__pyx_v_name); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__htmlTagValidOrRaise(__pyx_v_name); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 922; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L3;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":915
+ /* "src/lxml/lxml.etree.pyx":924
* _htmlTagValidOrRaise(name)
* else:
* _tagValidOrRaise(name) # <<<<<<<<<<<<<<
* self._tag = value
* tree.xmlNodeSetName(self._c_node, _xcstr(name))
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__tagValidOrRaise(__pyx_v_name); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__tagValidOrRaise(__pyx_v_name); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":916
+ /* "src/lxml/lxml.etree.pyx":925
* else:
* _tagValidOrRaise(name)
* self._tag = value # <<<<<<<<<<<<<<
__Pyx_DECREF(__pyx_v_self->_tag);
__pyx_v_self->_tag = __pyx_v_value;
- /* "src/lxml/lxml.etree.pyx":917
+ /* "src/lxml/lxml.etree.pyx":926
* _tagValidOrRaise(name)
* self._tag = value
* tree.xmlNodeSetName(self._c_node, _xcstr(name)) # <<<<<<<<<<<<<<
*/
xmlNodeSetName(__pyx_v_self->_c_node, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_name));
- /* "src/lxml/lxml.etree.pyx":918
+ /* "src/lxml/lxml.etree.pyx":927
* self._tag = value
* tree.xmlNodeSetName(self._c_node, _xcstr(name))
* if ns is None: # <<<<<<<<<<<<<<
__pyx_t_7 = (__pyx_t_5 != 0);
if (__pyx_t_7) {
- /* "src/lxml/lxml.etree.pyx":919
+ /* "src/lxml/lxml.etree.pyx":928
* tree.xmlNodeSetName(self._c_node, _xcstr(name))
* if ns is None:
* self._c_node.ns = NULL # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":921
+ /* "src/lxml/lxml.etree.pyx":930
* self._c_node.ns = NULL
* else:
* self._doc._setNodeNs(self._c_node, _xcstr(ns)) # <<<<<<<<<<<<<<
*
* property attrib:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_9_Document__setNodeNs(__pyx_v_self->_doc, __pyx_v_self->_c_node, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_ns)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 921; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_9_Document__setNodeNs(__pyx_v_self->_doc, __pyx_v_self->_c_node, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_ns)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 930; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":907
+ /* "src/lxml/lxml.etree.pyx":916
* return self._tag
*
* def __set__(self, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":927
+/* "src/lxml/lxml.etree.pyx":936
* keys(), values() and items() to access element attributes.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":928
+ /* "src/lxml/lxml.etree.pyx":937
* """
* def __get__(self):
* return _Attrib.__new__(_Attrib, self) # <<<<<<<<<<<<<<
* property text:
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_2 = __pyx_tp_new_4lxml_5etree__Attrib(((PyTypeObject *)((PyObject*)__pyx_ptype_4lxml_5etree__Attrib)), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_tp_new_4lxml_5etree__Attrib(((PyTypeObject *)((PyObject*)__pyx_ptype_4lxml_5etree__Attrib)), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":927
+ /* "src/lxml/lxml.etree.pyx":936
* keys(), values() and items() to access element attributes.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":934
+/* "src/lxml/lxml.etree.pyx":943
* the value None, if there was no text.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":935
+ /* "src/lxml/lxml.etree.pyx":944
* """
* def __get__(self):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _collectText(self._c_node.children)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 935; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 944; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":936
+ /* "src/lxml/lxml.etree.pyx":945
* def __get__(self):
* _assertValidNode(self)
* return _collectText(self._c_node.children) # <<<<<<<<<<<<<<
* def __set__(self, value):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree__collectText(__pyx_v_self->_c_node->children); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 936; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__collectText(__pyx_v_self->_c_node->children); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":934
+ /* "src/lxml/lxml.etree.pyx":943
* the value None, if there was no text.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":938
+/* "src/lxml/lxml.etree.pyx":947
* return _collectText(self._c_node.children)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("__set__", 0);
__Pyx_INCREF(__pyx_v_value);
- /* "src/lxml/lxml.etree.pyx":939
+ /* "src/lxml/lxml.etree.pyx":948
*
* def __set__(self, value):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if isinstance(value, QName):
* value = _resolveQNameText(self, value).decode('utf8')
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 939; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 948; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":940
+ /* "src/lxml/lxml.etree.pyx":949
* def __set__(self, value):
* _assertValidNode(self)
* if isinstance(value, QName): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":941
+ /* "src/lxml/lxml.etree.pyx":950
* _assertValidNode(self)
* if isinstance(value, QName):
* value = _resolveQNameText(self, value).decode('utf8') # <<<<<<<<<<<<<<
* _setNodeText(self._c_node, value)
*
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__resolveQNameText(__pyx_v_self, __pyx_v_value); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 941; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__resolveQNameText(__pyx_v_self, __pyx_v_value); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 950; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
if (unlikely(__pyx_t_4 == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "decode");
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 941; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 950; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_5 = __Pyx_decode_bytes(__pyx_t_4, 0, PY_SSIZE_T_MAX, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 941; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_decode_bytes(__pyx_t_4, 0, PY_SSIZE_T_MAX, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 950; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF_SET(__pyx_v_value, __pyx_t_5);
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":942
+ /* "src/lxml/lxml.etree.pyx":951
* if isinstance(value, QName):
* value = _resolveQNameText(self, value).decode('utf8')
* _setNodeText(self._c_node, value) # <<<<<<<<<<<<<<
*
* # using 'del el.text' is the wrong thing to do
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__setNodeText(__pyx_v_self->_c_node, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 942; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__setNodeText(__pyx_v_self->_c_node, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 951; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":938
+ /* "src/lxml/lxml.etree.pyx":947
* return _collectText(self._c_node.children)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":953
+/* "src/lxml/lxml.etree.pyx":962
* there was no text.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":954
+ /* "src/lxml/lxml.etree.pyx":963
* """
* def __get__(self):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _collectText(self._c_node.next)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 954; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 963; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":955
+ /* "src/lxml/lxml.etree.pyx":964
* def __get__(self):
* _assertValidNode(self)
* return _collectText(self._c_node.next) # <<<<<<<<<<<<<<
* def __set__(self, value):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree__collectText(__pyx_v_self->_c_node->next); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 955; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__collectText(__pyx_v_self->_c_node->next); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 964; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":953
+ /* "src/lxml/lxml.etree.pyx":962
* there was no text.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":957
+/* "src/lxml/lxml.etree.pyx":966
* return _collectText(self._c_node.next)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__set__", 0);
- /* "src/lxml/lxml.etree.pyx":958
+ /* "src/lxml/lxml.etree.pyx":967
*
* def __set__(self, value):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _setTailText(self._c_node, value)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 958; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 967; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":959
+ /* "src/lxml/lxml.etree.pyx":968
* def __set__(self, value):
* _assertValidNode(self)
* _setTailText(self._c_node, value) # <<<<<<<<<<<<<<
*
* # using 'del el.tail' is the wrong thing to do
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__setTailText(__pyx_v_self->_c_node, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 959; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__setTailText(__pyx_v_self->_c_node, __pyx_v_value); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 968; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":957
+ /* "src/lxml/lxml.etree.pyx":966
* return _collectText(self._c_node.next)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":969
+/* "src/lxml/lxml.etree.pyx":978
* u"""Namespace prefix or None.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":970
+ /* "src/lxml/lxml.etree.pyx":979
* """
* def __get__(self):
* if self._c_node.ns is not NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_c_node->ns != NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":971
+ /* "src/lxml/lxml.etree.pyx":980
* def __get__(self):
* if self._c_node.ns is not NULL:
* if self._c_node.ns.prefix is not NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_c_node->ns->prefix != NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":972
+ /* "src/lxml/lxml.etree.pyx":981
* if self._c_node.ns is not NULL:
* if self._c_node.ns.prefix is not NULL:
* return funicode(self._c_node.ns.prefix) # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->_c_node->ns->prefix); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 972; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->_c_node->ns->prefix); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 981; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":973
+ /* "src/lxml/lxml.etree.pyx":982
* if self._c_node.ns.prefix is not NULL:
* return funicode(self._c_node.ns.prefix)
* return None # <<<<<<<<<<<<<<
__pyx_r = Py_None;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":969
+ /* "src/lxml/lxml.etree.pyx":978
* u"""Namespace prefix or None.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":979
+/* "src/lxml/lxml.etree.pyx":988
* u"""Original line number as found by the parser or None if unknown.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":981
+ /* "src/lxml/lxml.etree.pyx":990
* def __get__(self):
* cdef long line
* _assertValidNode(self) # <<<<<<<<<<<<<<
* line = tree.xmlGetLineNo(self._c_node)
* return line if line > 0 else None
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 981; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":982
+ /* "src/lxml/lxml.etree.pyx":991
* cdef long line
* _assertValidNode(self)
* line = tree.xmlGetLineNo(self._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_line = xmlGetLineNo(__pyx_v_self->_c_node);
- /* "src/lxml/lxml.etree.pyx":983
+ /* "src/lxml/lxml.etree.pyx":992
* _assertValidNode(self)
* line = tree.xmlGetLineNo(self._c_node)
* return line if line > 0 else None # <<<<<<<<<<<<<<
*/
__Pyx_XDECREF(__pyx_r);
if (((__pyx_v_line > 0) != 0)) {
- __pyx_t_3 = __Pyx_PyInt_From_long(__pyx_v_line); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 983; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyInt_From_long(__pyx_v_line); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 992; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_2 = __pyx_t_3;
__pyx_t_3 = 0;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":979
+ /* "src/lxml/lxml.etree.pyx":988
* u"""Original line number as found by the parser or None if unknown.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":985
+/* "src/lxml/lxml.etree.pyx":994
* return line if line > 0 else None
*
* def __set__(self, line): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__set__", 0);
- /* "src/lxml/lxml.etree.pyx":986
+ /* "src/lxml/lxml.etree.pyx":995
*
* def __set__(self, line):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if line <= 0:
* self._c_node.line = 0
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 986; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 995; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":987
+ /* "src/lxml/lxml.etree.pyx":996
* def __set__(self, line):
* _assertValidNode(self)
* if line <= 0: # <<<<<<<<<<<<<<
* self._c_node.line = 0
* else:
*/
- __pyx_t_2 = PyObject_RichCompare(__pyx_v_line, __pyx_int_0, Py_LE); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 987; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 987; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_RichCompare(__pyx_v_line, __pyx_int_0, Py_LE); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 996; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 996; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":988
+ /* "src/lxml/lxml.etree.pyx":997
* _assertValidNode(self)
* if line <= 0:
* self._c_node.line = 0 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":990
+ /* "src/lxml/lxml.etree.pyx":999
* self._c_node.line = 0
* else:
* self._c_node.line = line # <<<<<<<<<<<<<<
*
* # not in ElementTree, read-only
*/
- __pyx_t_4 = __Pyx_PyInt_As_unsigned_short(__pyx_v_line); if (unlikely((__pyx_t_4 == (unsigned short)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyInt_As_unsigned_short(__pyx_v_line); if (unlikely((__pyx_t_4 == (unsigned short)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_self->_c_node->line = __pyx_t_4;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":985
+ /* "src/lxml/lxml.etree.pyx":994
* return line if line > 0 else None
*
* def __set__(self, line): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1000
+/* "src/lxml/lxml.etree.pyx":1009
* Note that changing the returned dict has no effect on the Element.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1003
+ /* "src/lxml/lxml.etree.pyx":1012
* cdef xmlNode* c_node
* cdef xmlNs* c_ns
* _assertValidNode(self) # <<<<<<<<<<<<<<
* nsmap = {}
* c_node = self._c_node
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1003; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1012; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1004
+ /* "src/lxml/lxml.etree.pyx":1013
* cdef xmlNs* c_ns
* _assertValidNode(self)
* nsmap = {} # <<<<<<<<<<<<<<
* c_node = self._c_node
* while c_node is not NULL and c_node.type == tree.XML_ELEMENT_NODE:
*/
- __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1004; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1013; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_v_nsmap = ((PyObject*)__pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":1005
+ /* "src/lxml/lxml.etree.pyx":1014
* _assertValidNode(self)
* nsmap = {}
* c_node = self._c_node # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_self->_c_node;
__pyx_v_c_node = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":1006
+ /* "src/lxml/lxml.etree.pyx":1015
* nsmap = {}
* c_node = self._c_node
* while c_node is not NULL and c_node.type == tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_L5_bool_binop_done:;
if (!__pyx_t_4) break;
- /* "src/lxml/lxml.etree.pyx":1007
+ /* "src/lxml/lxml.etree.pyx":1016
* c_node = self._c_node
* while c_node is not NULL and c_node.type == tree.XML_ELEMENT_NODE:
* c_ns = c_node.nsDef # <<<<<<<<<<<<<<
__pyx_t_6 = __pyx_v_c_node->nsDef;
__pyx_v_c_ns = __pyx_t_6;
- /* "src/lxml/lxml.etree.pyx":1008
+ /* "src/lxml/lxml.etree.pyx":1017
* while c_node is not NULL and c_node.type == tree.XML_ELEMENT_NODE:
* c_ns = c_node.nsDef
* while c_ns is not NULL: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_ns != NULL) != 0);
if (!__pyx_t_4) break;
- /* "src/lxml/lxml.etree.pyx":1009
+ /* "src/lxml/lxml.etree.pyx":1018
* c_ns = c_node.nsDef
* while c_ns is not NULL:
* prefix = funicodeOrNone(c_ns.prefix) # <<<<<<<<<<<<<<
* if prefix not in nsmap:
* nsmap[prefix] = funicodeOrNone(c_ns.href)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_funicodeOrNone(__pyx_v_c_ns->prefix); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1009; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_funicodeOrNone(__pyx_v_c_ns->prefix); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1018; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":1010
+ /* "src/lxml/lxml.etree.pyx":1019
* while c_ns is not NULL:
* prefix = funicodeOrNone(c_ns.prefix)
* if prefix not in nsmap: # <<<<<<<<<<<<<<
* nsmap[prefix] = funicodeOrNone(c_ns.href)
* c_ns = c_ns.next
*/
- __pyx_t_4 = (__Pyx_PyDict_Contains(__pyx_v_prefix, __pyx_v_nsmap, Py_NE)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1010; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = (__Pyx_PyDict_Contains(__pyx_v_prefix, __pyx_v_nsmap, Py_NE)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1019; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1011
+ /* "src/lxml/lxml.etree.pyx":1020
* prefix = funicodeOrNone(c_ns.prefix)
* if prefix not in nsmap:
* nsmap[prefix] = funicodeOrNone(c_ns.href) # <<<<<<<<<<<<<<
* c_ns = c_ns.next
* c_node = c_node.parent
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_funicodeOrNone(__pyx_v_c_ns->href); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1011; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_funicodeOrNone(__pyx_v_c_ns->href); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1020; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- if (unlikely(PyDict_SetItem(__pyx_v_nsmap, __pyx_v_prefix, __pyx_t_2) < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1011; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(PyDict_SetItem(__pyx_v_nsmap, __pyx_v_prefix, __pyx_t_2) < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1020; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
goto __pyx_L9;
}
__pyx_L9:;
- /* "src/lxml/lxml.etree.pyx":1012
+ /* "src/lxml/lxml.etree.pyx":1021
* if prefix not in nsmap:
* nsmap[prefix] = funicodeOrNone(c_ns.href)
* c_ns = c_ns.next # <<<<<<<<<<<<<<
__pyx_v_c_ns = __pyx_t_6;
}
- /* "src/lxml/lxml.etree.pyx":1013
+ /* "src/lxml/lxml.etree.pyx":1022
* nsmap[prefix] = funicodeOrNone(c_ns.href)
* c_ns = c_ns.next
* c_node = c_node.parent # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_t_3;
}
- /* "src/lxml/lxml.etree.pyx":1014
+ /* "src/lxml/lxml.etree.pyx":1023
* c_ns = c_ns.next
* c_node = c_node.parent
* return nsmap # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_nsmap;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1000
+ /* "src/lxml/lxml.etree.pyx":1009
* Note that changing the returned dict has no effect on the Element.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1028
+/* "src/lxml/lxml.etree.pyx":1037
* Element, regardless of the document type (XML or HTML).
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1029
+ /* "src/lxml/lxml.etree.pyx":1038
* """
* def __get__(self):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* c_base = tree.xmlNodeGetBase(self._doc._c_doc, self._c_node)
* if c_base is NULL:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1029; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1038; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1030
+ /* "src/lxml/lxml.etree.pyx":1039
* def __get__(self):
* _assertValidNode(self)
* c_base = tree.xmlNodeGetBase(self._doc._c_doc, self._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_base = xmlNodeGetBase(__pyx_v_self->_doc->_c_doc, __pyx_v_self->_c_node);
- /* "src/lxml/lxml.etree.pyx":1031
+ /* "src/lxml/lxml.etree.pyx":1040
* _assertValidNode(self)
* c_base = tree.xmlNodeGetBase(self._doc._c_doc, self._c_node)
* if c_base is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_base == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1032
+ /* "src/lxml/lxml.etree.pyx":1041
* c_base = tree.xmlNodeGetBase(self._doc._c_doc, self._c_node)
* if c_base is NULL:
* if self._doc._c_doc.URL is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_self->_doc->_c_doc->URL == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1033
+ /* "src/lxml/lxml.etree.pyx":1042
* if c_base is NULL:
* if self._doc._c_doc.URL is NULL:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1034
+ /* "src/lxml/lxml.etree.pyx":1043
* if self._doc._c_doc.URL is NULL:
* return None
* return _decodeFilename(self._doc._c_doc.URL) # <<<<<<<<<<<<<<
* base = _decodeFilename(c_base)
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __pyx_f_4lxml_5etree__decodeFilename(__pyx_v_self->_doc->_c_doc->URL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1034; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__decodeFilename(__pyx_v_self->_doc->_c_doc->URL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1043; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1035
+ /* "src/lxml/lxml.etree.pyx":1044
* return None
* return _decodeFilename(self._doc._c_doc.URL)
* try: # <<<<<<<<<<<<<<
*/
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":1036
+ /* "src/lxml/lxml.etree.pyx":1045
* return _decodeFilename(self._doc._c_doc.URL)
* try:
* base = _decodeFilename(c_base) # <<<<<<<<<<<<<<
* finally:
* tree.xmlFree(c_base)
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__decodeFilename(__pyx_v_c_base); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1036; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__decodeFilename(__pyx_v_c_base); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1045; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_base = __pyx_t_3;
__pyx_t_3 = 0;
}
- /* "src/lxml/lxml.etree.pyx":1038
+ /* "src/lxml/lxml.etree.pyx":1047
* base = _decodeFilename(c_base)
* finally:
* tree.xmlFree(c_base) # <<<<<<<<<<<<<<
__pyx_L7:;
}
- /* "src/lxml/lxml.etree.pyx":1039
+ /* "src/lxml/lxml.etree.pyx":1048
* finally:
* tree.xmlFree(c_base)
* return base # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_base;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1028
+ /* "src/lxml/lxml.etree.pyx":1037
* Element, regardless of the document type (XML or HTML).
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1041
+/* "src/lxml/lxml.etree.pyx":1050
* return base
*
* def __set__(self, url): # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("__set__", 0);
__Pyx_INCREF(__pyx_v_url);
- /* "src/lxml/lxml.etree.pyx":1042
+ /* "src/lxml/lxml.etree.pyx":1051
*
* def __set__(self, url):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if url is None:
* c_base = <const_xmlChar*>NULL
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1042; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1051; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1043
+ /* "src/lxml/lxml.etree.pyx":1052
* def __set__(self, url):
* _assertValidNode(self)
* if url is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1044
+ /* "src/lxml/lxml.etree.pyx":1053
* _assertValidNode(self)
* if url is None:
* c_base = <const_xmlChar*>NULL # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1046
+ /* "src/lxml/lxml.etree.pyx":1055
* c_base = <const_xmlChar*>NULL
* else:
* url = _encodeFilename(url) # <<<<<<<<<<<<<<
* c_base = _xcstr(url)
* tree.xmlNodeSetBase(self._c_node, c_base)
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_url); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1046; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_url); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1055; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_url, __pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1047
+ /* "src/lxml/lxml.etree.pyx":1056
* else:
* url = _encodeFilename(url)
* c_base = _xcstr(url) # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1048
+ /* "src/lxml/lxml.etree.pyx":1057
* url = _encodeFilename(url)
* c_base = _xcstr(url)
* tree.xmlNodeSetBase(self._c_node, c_base) # <<<<<<<<<<<<<<
*/
xmlNodeSetBase(__pyx_v_self->_c_node, __pyx_v_c_base);
- /* "src/lxml/lxml.etree.pyx":1041
+ /* "src/lxml/lxml.etree.pyx":1050
* return base
*
* def __set__(self, url): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1051
+/* "src/lxml/lxml.etree.pyx":1060
*
* # ACCESSORS
* def __repr__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__repr__", 0);
- /* "src/lxml/lxml.etree.pyx":1053
+ /* "src/lxml/lxml.etree.pyx":1062
* def __repr__(self):
* u"__repr__(self)"
* return u"<Element %s at 0x%x>" % (self.tag, id(self)) # <<<<<<<<<<<<<<
* def __getitem__(self, x):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_tag); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1053; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_tag); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1062; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1053; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1062; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_id, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1053; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_id, __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1062; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1053; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1062; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_3);
__pyx_t_1 = 0;
__pyx_t_3 = 0;
- __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_Element_s_at_0x_x, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1053; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_Element_s_at_0x_x, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1062; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1051
+ /* "src/lxml/lxml.etree.pyx":1060
*
* # ACCESSORS
* def __repr__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1055
+/* "src/lxml/lxml.etree.pyx":1064
* return u"<Element %s at 0x%x>" % (self.tag, id(self))
*
* def __getitem__(self, x): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__getitem__", 0);
- /* "src/lxml/lxml.etree.pyx":1059
+ /* "src/lxml/lxml.etree.pyx":1068
* slice.
* """
* cdef xmlNode* c_node = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = NULL;
- /* "src/lxml/lxml.etree.pyx":1060
+ /* "src/lxml/lxml.etree.pyx":1069
* """
* cdef xmlNode* c_node = NULL
* cdef Py_ssize_t step = 0, slicelength = 0 # <<<<<<<<<<<<<<
__pyx_v_step = 0;
__pyx_v_slicelength = 0;
- /* "src/lxml/lxml.etree.pyx":1064
+ /* "src/lxml/lxml.etree.pyx":1073
* cdef _node_to_node_function next_element
* cdef list result
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if isinstance(x, slice):
* # slicing
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1064; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1073; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1065
+ /* "src/lxml/lxml.etree.pyx":1074
* cdef list result
* _assertValidNode(self)
* if isinstance(x, slice): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1067
+ /* "src/lxml/lxml.etree.pyx":1076
* if isinstance(x, slice):
* # slicing
* if _isFullSlice(<slice>x): # <<<<<<<<<<<<<<
* return _collectChildren(self)
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength)
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__isFullSlice(((PyObject*)__pyx_v_x)); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1067; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__isFullSlice(((PyObject*)__pyx_v_x)); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1076; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1068
+ /* "src/lxml/lxml.etree.pyx":1077
* # slicing
* if _isFullSlice(<slice>x):
* return _collectChildren(self) # <<<<<<<<<<<<<<
* if c_node is NULL:
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __pyx_f_4lxml_5etree__collectChildren(__pyx_v_self); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1068; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__collectChildren(__pyx_v_self); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1077; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1069
+ /* "src/lxml/lxml.etree.pyx":1078
* if _isFullSlice(<slice>x):
* return _collectChildren(self)
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength) # <<<<<<<<<<<<<<
* if c_node is NULL:
* return []
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__findChildSlice(((PyObject*)__pyx_v_x), __pyx_v_self->_c_node, (&__pyx_v_c_node), (&__pyx_v_step), (&__pyx_v_slicelength)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1069; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__findChildSlice(((PyObject*)__pyx_v_x), __pyx_v_self->_c_node, (&__pyx_v_c_node), (&__pyx_v_step), (&__pyx_v_slicelength)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1078; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1070
+ /* "src/lxml/lxml.etree.pyx":1079
* return _collectChildren(self)
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1071
+ /* "src/lxml/lxml.etree.pyx":1080
* _findChildSlice(<slice>x, self._c_node, &c_node, &step, &slicelength)
* if c_node is NULL:
* return [] # <<<<<<<<<<<<<<
* next_element = _nextElement
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1071; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1080; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1072
+ /* "src/lxml/lxml.etree.pyx":1081
* if c_node is NULL:
* return []
* if step > 0: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_step > 0) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1073
+ /* "src/lxml/lxml.etree.pyx":1082
* return []
* if step > 0:
* next_element = _nextElement # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1075
+ /* "src/lxml/lxml.etree.pyx":1084
* next_element = _nextElement
* else:
* step = -step # <<<<<<<<<<<<<<
*/
__pyx_v_step = (-__pyx_v_step);
- /* "src/lxml/lxml.etree.pyx":1076
+ /* "src/lxml/lxml.etree.pyx":1085
* else:
* step = -step
* next_element = _previousElement # <<<<<<<<<<<<<<
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":1077
+ /* "src/lxml/lxml.etree.pyx":1086
* step = -step
* next_element = _previousElement
* result = [] # <<<<<<<<<<<<<<
* c = 0
* while c_node is not NULL and c < slicelength:
*/
- __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1077; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1086; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_result = ((PyObject*)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1078
+ /* "src/lxml/lxml.etree.pyx":1087
* next_element = _previousElement
* result = []
* c = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_c = 0;
- /* "src/lxml/lxml.etree.pyx":1079
+ /* "src/lxml/lxml.etree.pyx":1088
* result = []
* c = 0
* while c_node is not NULL and c < slicelength: # <<<<<<<<<<<<<<
__pyx_L9_bool_binop_done:;
if (!__pyx_t_2) break;
- /* "src/lxml/lxml.etree.pyx":1080
+ /* "src/lxml/lxml.etree.pyx":1089
* c = 0
* while c_node is not NULL and c < slicelength:
* result.append(_elementFactory(self._doc, c_node)) # <<<<<<<<<<<<<<
*/
__pyx_t_4 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_4);
- __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_node)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1080; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_4), __pyx_v_c_node)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1089; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_result, __pyx_t_5); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1080; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_result, __pyx_t_5); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1089; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":1081
+ /* "src/lxml/lxml.etree.pyx":1090
* while c_node is not NULL and c < slicelength:
* result.append(_elementFactory(self._doc, c_node))
* c += 1 # <<<<<<<<<<<<<<
*/
__pyx_v_c = (__pyx_v_c + 1);
- /* "src/lxml/lxml.etree.pyx":1082
+ /* "src/lxml/lxml.etree.pyx":1091
* result.append(_elementFactory(self._doc, c_node))
* c += 1
* for i in range(step): # <<<<<<<<<<<<<<
for (__pyx_t_8 = 0; __pyx_t_8 < __pyx_t_7; __pyx_t_8+=1) {
__pyx_v_i = __pyx_t_8;
- /* "src/lxml/lxml.etree.pyx":1083
+ /* "src/lxml/lxml.etree.pyx":1092
* c += 1
* for i in range(step):
* c_node = next_element(c_node) # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/lxml.etree.pyx":1084
+ /* "src/lxml/lxml.etree.pyx":1093
* for i in range(step):
* c_node = next_element(c_node)
* return result # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1087
+ /* "src/lxml/lxml.etree.pyx":1096
* else:
* # indexing
* c_node = _findChild(self._c_node, x) # <<<<<<<<<<<<<<
* if c_node is NULL:
* raise IndexError, u"list index out of range"
*/
- __pyx_t_7 = __Pyx_PyIndex_AsSsize_t(__pyx_v_x); if (unlikely((__pyx_t_7 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1087; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_PyIndex_AsSsize_t(__pyx_v_x); if (unlikely((__pyx_t_7 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1096; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_node = __pyx_f_4lxml_5etree__findChild(__pyx_v_self->_c_node, __pyx_t_7);
- /* "src/lxml/lxml.etree.pyx":1088
+ /* "src/lxml/lxml.etree.pyx":1097
* # indexing
* c_node = _findChild(self._c_node, x)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1089
+ /* "src/lxml/lxml.etree.pyx":1098
* c_node = _findChild(self._c_node, x)
* if c_node is NULL:
* raise IndexError, u"list index out of range" # <<<<<<<<<<<<<<
*
*/
__Pyx_Raise(__pyx_builtin_IndexError, __pyx_kp_u_list_index_out_of_range, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1089; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1098; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1090
+ /* "src/lxml/lxml.etree.pyx":1099
* if c_node is NULL:
* raise IndexError, u"list index out of range"
* return _elementFactory(self._doc, c_node) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_5 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1090; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_r = __pyx_t_4;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1055
+ /* "src/lxml/lxml.etree.pyx":1064
* return u"<Element %s at 0x%x>" % (self.tag, id(self))
*
* def __getitem__(self, x): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1092
+/* "src/lxml/lxml.etree.pyx":1101
* return _elementFactory(self._doc, c_node)
*
* def __len__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__len__", 0);
- /* "src/lxml/lxml.etree.pyx":1097
+ /* "src/lxml/lxml.etree.pyx":1106
* Returns the number of subelements.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _countElements(self._c_node.children)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1097; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1098
+ /* "src/lxml/lxml.etree.pyx":1107
* """
* _assertValidNode(self)
* return _countElements(self._c_node.children) # <<<<<<<<<<<<<<
__pyx_r = __pyx_f_4lxml_5etree__countElements(__pyx_v_self->_c_node->children);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1092
+ /* "src/lxml/lxml.etree.pyx":1101
* return _elementFactory(self._doc, c_node)
*
* def __len__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1100
+/* "src/lxml/lxml.etree.pyx":1109
* return _countElements(self._c_node.children)
*
* def __nonzero__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__nonzero__", 0);
- /* "src/lxml/lxml.etree.pyx":1102
+ /* "src/lxml/lxml.etree.pyx":1111
* def __nonzero__(self):
* #u"__nonzero__(self)" # currently fails in Py3.1
* import warnings # <<<<<<<<<<<<<<
* warnings.warn(
* u"The behavior of this method will change in future versions. "
*/
- __pyx_t_1 = __Pyx_Import(__pyx_n_s_warnings, 0, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1102; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_Import(__pyx_n_s_warnings, 0, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1111; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_warnings = __pyx_t_1;
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":1103
+ /* "src/lxml/lxml.etree.pyx":1112
* #u"__nonzero__(self)" # currently fails in Py3.1
* import warnings
* warnings.warn( # <<<<<<<<<<<<<<
* u"The behavior of this method will change in future versions. "
* u"Use specific 'len(elem)' or 'elem is not None' test instead.",
*/
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_warnings, __pyx_n_s_warn); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_warnings, __pyx_n_s_warn); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- /* "src/lxml/lxml.etree.pyx":1107
+ /* "src/lxml/lxml.etree.pyx":1116
* u"Use specific 'len(elem)' or 'elem is not None' test instead.",
* FutureWarning
* ) # <<<<<<<<<<<<<<
__pyx_t_4 = 1;
}
}
- __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
if (__pyx_t_3) {
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __pyx_t_3 = NULL;
__Pyx_INCREF(__pyx_builtin_FutureWarning);
PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_4, __pyx_builtin_FutureWarning);
__Pyx_GIVEREF(__pyx_builtin_FutureWarning);
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":1109
+ /* "src/lxml/lxml.etree.pyx":1118
* )
* # emulate old behaviour
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _hasChild(self._c_node)
*
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1110
+ /* "src/lxml/lxml.etree.pyx":1119
* # emulate old behaviour
* _assertValidNode(self)
* return _hasChild(self._c_node) # <<<<<<<<<<<<<<
__pyx_r = __pyx_f_4lxml_5etree__hasChild(__pyx_v_self->_c_node);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1100
+ /* "src/lxml/lxml.etree.pyx":1109
* return _countElements(self._c_node.children)
*
* def __nonzero__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1112
+/* "src/lxml/lxml.etree.pyx":1121
* return _hasChild(self._c_node)
*
* def __contains__(self, element): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__contains__", 0);
- /* "src/lxml/lxml.etree.pyx":1115
+ /* "src/lxml/lxml.etree.pyx":1124
* u"__contains__(self, element)"
* cdef xmlNode* c_node
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if not isinstance(element, _Element):
* return 0
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1116
+ /* "src/lxml/lxml.etree.pyx":1125
* cdef xmlNode* c_node
* _assertValidNode(self)
* if not isinstance(element, _Element): # <<<<<<<<<<<<<<
__pyx_t_3 = ((!(__pyx_t_2 != 0)) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1117
+ /* "src/lxml/lxml.etree.pyx":1126
* _assertValidNode(self)
* if not isinstance(element, _Element):
* return 0 # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1118
+ /* "src/lxml/lxml.etree.pyx":1127
* if not isinstance(element, _Element):
* return 0
* c_node = (<_Element>element)._c_node # <<<<<<<<<<<<<<
__pyx_t_4 = ((struct LxmlElement *)__pyx_v_element)->_c_node;
__pyx_v_c_node = __pyx_t_4;
- /* "src/lxml/lxml.etree.pyx":1119
+ /* "src/lxml/lxml.etree.pyx":1128
* return 0
* c_node = (<_Element>element)._c_node
* return c_node is not NULL and c_node.parent is self._c_node # <<<<<<<<<<<<<<
__pyx_r = __pyx_t_1;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1112
+ /* "src/lxml/lxml.etree.pyx":1121
* return _hasChild(self._c_node)
*
* def __contains__(self, element): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1121
+/* "src/lxml/lxml.etree.pyx":1130
* return c_node is not NULL and c_node.parent is self._c_node
*
* def __iter__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__iter__", 0);
- /* "src/lxml/lxml.etree.pyx":1123
+ /* "src/lxml/lxml.etree.pyx":1132
* def __iter__(self):
* u"__iter__(self)"
* return ElementChildIterator(self) # <<<<<<<<<<<<<<
* def __reversed__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1123; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementChildIterator)), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1123; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementChildIterator)), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1121
+ /* "src/lxml/lxml.etree.pyx":1130
* return c_node is not NULL and c_node.parent is self._c_node
*
* def __iter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1125
+/* "src/lxml/lxml.etree.pyx":1134
* return ElementChildIterator(self)
*
* def __reversed__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__reversed__", 0);
- /* "src/lxml/lxml.etree.pyx":1127
+ /* "src/lxml/lxml.etree.pyx":1136
* def __reversed__(self):
* u"__reversed__(self)"
* return ElementChildIterator(self, reversed=True) # <<<<<<<<<<<<<<
* def index(self, _Element child not None, start=None, stop=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_reversed, Py_True) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementChildIterator)), __pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_reversed, Py_True) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementChildIterator)), __pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1125
+ /* "src/lxml/lxml.etree.pyx":1134
* return ElementChildIterator(self)
*
* def __reversed__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1129
+/* "src/lxml/lxml.etree.pyx":1138
* return ElementChildIterator(self, reversed=True)
*
* def index(self, _Element child not None, start=None, stop=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "index") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1129; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "index") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1138; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("index", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1129; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("index", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1138; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.index", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_child), __pyx_ptype_4lxml_5etree__Element, 0, "child", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_child), __pyx_ptype_4lxml_5etree__Element, 0, "child", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1138; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_44index(((struct LxmlElement *)__pyx_v_self), __pyx_v_child, __pyx_v_start, __pyx_v_stop);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("index", 0);
- /* "src/lxml/lxml.etree.pyx":1140
+ /* "src/lxml/lxml.etree.pyx":1149
* cdef xmlNode* c_child
* cdef xmlNode* c_start_node
* _assertValidNode(self) # <<<<<<<<<<<<<<
* _assertValidNode(child)
* c_child = child._c_node
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1140; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1149; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1141
+ /* "src/lxml/lxml.etree.pyx":1150
* cdef xmlNode* c_start_node
* _assertValidNode(self)
* _assertValidNode(child) # <<<<<<<<<<<<<<
* c_child = child._c_node
* if c_child.parent is not self._c_node:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_child); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_child); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1150; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1142
+ /* "src/lxml/lxml.etree.pyx":1151
* _assertValidNode(self)
* _assertValidNode(child)
* c_child = child._c_node # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_child->_c_node;
__pyx_v_c_child = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":1143
+ /* "src/lxml/lxml.etree.pyx":1152
* _assertValidNode(child)
* c_child = child._c_node
* if c_child.parent is not self._c_node: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_child->parent != __pyx_v_self->_c_node) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1144
+ /* "src/lxml/lxml.etree.pyx":1153
* c_child = child._c_node
* if c_child.parent is not self._c_node:
* raise ValueError, u"Element is not a child of this node." # <<<<<<<<<<<<<<
* # handle the unbounded search straight away (normal case)
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_a_child_of_this_n, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1153; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1147
+ /* "src/lxml/lxml.etree.pyx":1156
*
* # handle the unbounded search straight away (normal case)
* if stop is None and (start is None or start == 0): # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_t_4;
goto __pyx_L5_bool_binop_done;
}
- __pyx_t_6 = PyObject_RichCompare(__pyx_v_start, __pyx_int_0, Py_EQ); __Pyx_XGOTREF(__pyx_t_6); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyObject_RichCompare(__pyx_v_start, __pyx_int_0, Py_EQ); __Pyx_XGOTREF(__pyx_t_6); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1156; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1156; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_t_3 = __pyx_t_4;
__pyx_L5_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1148
+ /* "src/lxml/lxml.etree.pyx":1157
* # handle the unbounded search straight away (normal case)
* if stop is None and (start is None or start == 0):
* k = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_k = 0;
- /* "src/lxml/lxml.etree.pyx":1149
+ /* "src/lxml/lxml.etree.pyx":1158
* if stop is None and (start is None or start == 0):
* k = 0
* c_child = c_child.prev # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_c_child->prev;
__pyx_v_c_child = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":1150
+ /* "src/lxml/lxml.etree.pyx":1159
* k = 0
* c_child = c_child.prev
* while c_child is not NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_child != NULL) != 0);
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":1151
+ /* "src/lxml/lxml.etree.pyx":1160
* c_child = c_child.prev
* while c_child is not NULL:
* if _isElement(c_child): # <<<<<<<<<<<<<<
__pyx_t_3 = (_isElement(__pyx_v_c_child) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1152
+ /* "src/lxml/lxml.etree.pyx":1161
* while c_child is not NULL:
* if _isElement(c_child):
* k += 1 # <<<<<<<<<<<<<<
}
__pyx_L10:;
- /* "src/lxml/lxml.etree.pyx":1153
+ /* "src/lxml/lxml.etree.pyx":1162
* if _isElement(c_child):
* k += 1
* c_child = c_child.prev # <<<<<<<<<<<<<<
__pyx_v_c_child = __pyx_t_2;
}
- /* "src/lxml/lxml.etree.pyx":1154
+ /* "src/lxml/lxml.etree.pyx":1163
* k += 1
* c_child = c_child.prev
* return k # <<<<<<<<<<<<<<
* # check indices
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1154; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1163; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_r = __pyx_t_6;
__pyx_t_6 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1157
+ /* "src/lxml/lxml.etree.pyx":1166
*
* # check indices
* if start is None: # <<<<<<<<<<<<<<
__pyx_t_4 = (__pyx_t_3 != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":1158
+ /* "src/lxml/lxml.etree.pyx":1167
* # check indices
* if start is None:
* c_start = 0 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1160
+ /* "src/lxml/lxml.etree.pyx":1169
* c_start = 0
* else:
* c_start = start # <<<<<<<<<<<<<<
* if stop is None:
* c_stop = 0
*/
- __pyx_t_7 = __Pyx_PyIndex_AsSsize_t(__pyx_v_start); if (unlikely((__pyx_t_7 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1160; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_PyIndex_AsSsize_t(__pyx_v_start); if (unlikely((__pyx_t_7 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1169; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_start = __pyx_t_7;
}
__pyx_L11:;
- /* "src/lxml/lxml.etree.pyx":1161
+ /* "src/lxml/lxml.etree.pyx":1170
* else:
* c_start = start
* if stop is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_4 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1162
+ /* "src/lxml/lxml.etree.pyx":1171
* c_start = start
* if stop is None:
* c_stop = 0 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1164
+ /* "src/lxml/lxml.etree.pyx":1173
* c_stop = 0
* else:
* c_stop = stop # <<<<<<<<<<<<<<
* if c_stop == 0 or \
* c_start >= c_stop and (c_stop > 0 or c_start < 0):
*/
- __pyx_t_7 = __Pyx_PyIndex_AsSsize_t(__pyx_v_stop); if (unlikely((__pyx_t_7 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1164; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_PyIndex_AsSsize_t(__pyx_v_stop); if (unlikely((__pyx_t_7 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_stop = __pyx_t_7;
- /* "src/lxml/lxml.etree.pyx":1165
+ /* "src/lxml/lxml.etree.pyx":1174
* else:
* c_stop = stop
* if c_stop == 0 or \ # <<<<<<<<<<<<<<
goto __pyx_L14_bool_binop_done;
}
- /* "src/lxml/lxml.etree.pyx":1166
+ /* "src/lxml/lxml.etree.pyx":1175
* c_stop = stop
* if c_stop == 0 or \
* c_start >= c_stop and (c_stop > 0 or c_start < 0): # <<<<<<<<<<<<<<
__pyx_L14_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1167
+ /* "src/lxml/lxml.etree.pyx":1176
* if c_stop == 0 or \
* c_start >= c_stop and (c_stop > 0 or c_start < 0):
* raise ValueError, u"list.index(x): x not in slice" # <<<<<<<<<<<<<<
* # for negative slice indices, check slice before searching index
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_list_index_x_x_not_in_slice, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1167; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1176; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
__pyx_L12:;
- /* "src/lxml/lxml.etree.pyx":1170
+ /* "src/lxml/lxml.etree.pyx":1179
*
* # for negative slice indices, check slice before searching index
* if c_start < 0 or c_stop < 0: # <<<<<<<<<<<<<<
__pyx_L19_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1172
+ /* "src/lxml/lxml.etree.pyx":1181
* if c_start < 0 or c_stop < 0:
* # start from right, at most up to leftmost(c_start, c_stop)
* if c_start < c_stop: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_start < __pyx_v_c_stop) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1173
+ /* "src/lxml/lxml.etree.pyx":1182
* # start from right, at most up to leftmost(c_start, c_stop)
* if c_start < c_stop:
* k = -c_start # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1175
+ /* "src/lxml/lxml.etree.pyx":1184
* k = -c_start
* else:
* k = -c_stop # <<<<<<<<<<<<<<
}
__pyx_L21:;
- /* "src/lxml/lxml.etree.pyx":1176
+ /* "src/lxml/lxml.etree.pyx":1185
* else:
* k = -c_stop
* c_start_node = self._c_node.last # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_self->_c_node->last;
__pyx_v_c_start_node = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":1177
+ /* "src/lxml/lxml.etree.pyx":1186
* k = -c_stop
* c_start_node = self._c_node.last
* l = 1 # <<<<<<<<<<<<<<
*/
__pyx_v_l = 1;
- /* "src/lxml/lxml.etree.pyx":1178
+ /* "src/lxml/lxml.etree.pyx":1187
* c_start_node = self._c_node.last
* l = 1
* while c_start_node != c_child and l < k: # <<<<<<<<<<<<<<
__pyx_L24_bool_binop_done:;
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":1179
+ /* "src/lxml/lxml.etree.pyx":1188
* l = 1
* while c_start_node != c_child and l < k:
* if _isElement(c_start_node): # <<<<<<<<<<<<<<
__pyx_t_3 = (_isElement(__pyx_v_c_start_node) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1180
+ /* "src/lxml/lxml.etree.pyx":1189
* while c_start_node != c_child and l < k:
* if _isElement(c_start_node):
* l += 1 # <<<<<<<<<<<<<<
}
__pyx_L26:;
- /* "src/lxml/lxml.etree.pyx":1181
+ /* "src/lxml/lxml.etree.pyx":1190
* if _isElement(c_start_node):
* l += 1
* c_start_node = c_start_node.prev # <<<<<<<<<<<<<<
__pyx_v_c_start_node = __pyx_t_2;
}
- /* "src/lxml/lxml.etree.pyx":1182
+ /* "src/lxml/lxml.etree.pyx":1191
* l += 1
* c_start_node = c_start_node.prev
* if c_start_node == c_child: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_start_node == __pyx_v_c_child) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1184
+ /* "src/lxml/lxml.etree.pyx":1193
* if c_start_node == c_child:
* # found! before slice end?
* if c_stop < 0 and l <= -c_stop: # <<<<<<<<<<<<<<
__pyx_L29_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1185
+ /* "src/lxml/lxml.etree.pyx":1194
* # found! before slice end?
* if c_stop < 0 and l <= -c_stop:
* raise ValueError, u"list.index(x): x not in slice" # <<<<<<<<<<<<<<
* raise ValueError, u"list.index(x): x not in slice"
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_list_index_x_x_not_in_slice, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1185; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L27;
}
- /* "src/lxml/lxml.etree.pyx":1186
+ /* "src/lxml/lxml.etree.pyx":1195
* if c_stop < 0 and l <= -c_stop:
* raise ValueError, u"list.index(x): x not in slice"
* elif c_start < 0: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_start < 0) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1187
+ /* "src/lxml/lxml.etree.pyx":1196
* raise ValueError, u"list.index(x): x not in slice"
* elif c_start < 0:
* raise ValueError, u"list.index(x): x not in slice" # <<<<<<<<<<<<<<
* # now determine the index backwards from child
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_list_index_x_x_not_in_slice, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1187; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1196; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L27:;
goto __pyx_L18;
}
__pyx_L18:;
- /* "src/lxml/lxml.etree.pyx":1190
+ /* "src/lxml/lxml.etree.pyx":1199
*
* # now determine the index backwards from child
* c_child = c_child.prev # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_v_c_child->prev;
__pyx_v_c_child = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":1191
+ /* "src/lxml/lxml.etree.pyx":1200
* # now determine the index backwards from child
* c_child = c_child.prev
* k = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_k = 0;
- /* "src/lxml/lxml.etree.pyx":1192
+ /* "src/lxml/lxml.etree.pyx":1201
* c_child = c_child.prev
* k = 0
* if c_stop > 0: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_stop > 0) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1194
+ /* "src/lxml/lxml.etree.pyx":1203
* if c_stop > 0:
* # we can optimize: stop after c_stop elements if not found
* while c_child != NULL and k < c_stop: # <<<<<<<<<<<<<<
__pyx_L34_bool_binop_done:;
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":1195
+ /* "src/lxml/lxml.etree.pyx":1204
* # we can optimize: stop after c_stop elements if not found
* while c_child != NULL and k < c_stop:
* if _isElement(c_child): # <<<<<<<<<<<<<<
__pyx_t_3 = (_isElement(__pyx_v_c_child) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1196
+ /* "src/lxml/lxml.etree.pyx":1205
* while c_child != NULL and k < c_stop:
* if _isElement(c_child):
* k += 1 # <<<<<<<<<<<<<<
}
__pyx_L36:;
- /* "src/lxml/lxml.etree.pyx":1197
+ /* "src/lxml/lxml.etree.pyx":1206
* if _isElement(c_child):
* k += 1
* c_child = c_child.prev # <<<<<<<<<<<<<<
__pyx_v_c_child = __pyx_t_2;
}
- /* "src/lxml/lxml.etree.pyx":1198
+ /* "src/lxml/lxml.etree.pyx":1207
* k += 1
* c_child = c_child.prev
* if k < c_stop: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_k < __pyx_v_c_stop) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1199
+ /* "src/lxml/lxml.etree.pyx":1208
* c_child = c_child.prev
* if k < c_stop:
* return k # <<<<<<<<<<<<<<
* # traverse all
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1199; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_r = __pyx_t_6;
__pyx_t_6 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1202
+ /* "src/lxml/lxml.etree.pyx":1211
* else:
* # traverse all
* while c_child != NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_child != NULL) != 0);
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":1203
+ /* "src/lxml/lxml.etree.pyx":1212
* # traverse all
* while c_child != NULL:
* if _isElement(c_child): # <<<<<<<<<<<<<<
__pyx_t_3 = (_isElement(__pyx_v_c_child) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1204
+ /* "src/lxml/lxml.etree.pyx":1213
* while c_child != NULL:
* if _isElement(c_child):
* k = k + 1 # <<<<<<<<<<<<<<
}
__pyx_L40:;
- /* "src/lxml/lxml.etree.pyx":1205
+ /* "src/lxml/lxml.etree.pyx":1214
* if _isElement(c_child):
* k = k + 1
* c_child = c_child.prev # <<<<<<<<<<<<<<
__pyx_v_c_child = __pyx_t_2;
}
- /* "src/lxml/lxml.etree.pyx":1206
+ /* "src/lxml/lxml.etree.pyx":1215
* k = k + 1
* c_child = c_child.prev
* if c_start > 0: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_start > 0) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1207
+ /* "src/lxml/lxml.etree.pyx":1216
* c_child = c_child.prev
* if c_start > 0:
* if k >= c_start: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_k >= __pyx_v_c_start) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1208
+ /* "src/lxml/lxml.etree.pyx":1217
* if c_start > 0:
* if k >= c_start:
* return k # <<<<<<<<<<<<<<
* return k
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1217; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_r = __pyx_t_6;
__pyx_t_6 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1210
+ /* "src/lxml/lxml.etree.pyx":1219
* return k
* else:
* return k # <<<<<<<<<<<<<<
* raise ValueError, u"list.index(x): x not in slice"
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1210; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_k); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1219; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_r = __pyx_t_6;
__pyx_t_6 = 0;
}
__pyx_L31:;
- /* "src/lxml/lxml.etree.pyx":1211
+ /* "src/lxml/lxml.etree.pyx":1220
* else:
* return k
* if c_start != 0 or c_stop != 0: # <<<<<<<<<<<<<<
__pyx_L44_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1212
+ /* "src/lxml/lxml.etree.pyx":1221
* return k
* if c_start != 0 or c_stop != 0:
* raise ValueError, u"list.index(x): x not in slice" # <<<<<<<<<<<<<<
* raise ValueError, u"list.index(x): x not in list"
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_list_index_x_x_not_in_slice, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1214
+ /* "src/lxml/lxml.etree.pyx":1223
* raise ValueError, u"list.index(x): x not in slice"
* else:
* raise ValueError, u"list.index(x): x not in list" # <<<<<<<<<<<<<<
* def get(self, key, default=None):
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_list_index_x_x_not_in_list, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1129
+ /* "src/lxml/lxml.etree.pyx":1138
* return ElementChildIterator(self, reversed=True)
*
* def index(self, _Element child not None, start=None, stop=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1216
+/* "src/lxml/lxml.etree.pyx":1225
* raise ValueError, u"list.index(x): x not in list"
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1216; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1225; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1216; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1225; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.get", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("get", 0);
- /* "src/lxml/lxml.etree.pyx":1221
+ /* "src/lxml/lxml.etree.pyx":1230
* Gets an element attribute.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _getAttributeValue(self, key, default)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1222
+ /* "src/lxml/lxml.etree.pyx":1231
* """
* _assertValidNode(self)
* return _getAttributeValue(self, key, default) # <<<<<<<<<<<<<<
* def keys(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree__getAttributeValue(__pyx_v_self, __pyx_v_key, __pyx_v_default); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1222; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__getAttributeValue(__pyx_v_self, __pyx_v_key, __pyx_v_default); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1231; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1216
+ /* "src/lxml/lxml.etree.pyx":1225
* raise ValueError, u"list.index(x): x not in list"
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1224
+/* "src/lxml/lxml.etree.pyx":1233
* return _getAttributeValue(self, key, default)
*
* def keys(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("keys", 0);
- /* "src/lxml/lxml.etree.pyx":1230
+ /* "src/lxml/lxml.etree.pyx":1239
* arbitrary order (just like for an ordinary Python dictionary).
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _collectAttributes(self._c_node, 1)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1231
+ /* "src/lxml/lxml.etree.pyx":1240
* """
* _assertValidNode(self)
* return _collectAttributes(self._c_node, 1) # <<<<<<<<<<<<<<
* def values(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_c_node, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1231; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_c_node, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1240; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1224
+ /* "src/lxml/lxml.etree.pyx":1233
* return _getAttributeValue(self, key, default)
*
* def keys(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1233
+/* "src/lxml/lxml.etree.pyx":1242
* return _collectAttributes(self._c_node, 1)
*
* def values(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("values", 0);
- /* "src/lxml/lxml.etree.pyx":1239
+ /* "src/lxml/lxml.etree.pyx":1248
* attributes are returned in an arbitrary order.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _collectAttributes(self._c_node, 2)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1240
+ /* "src/lxml/lxml.etree.pyx":1249
* """
* _assertValidNode(self)
* return _collectAttributes(self._c_node, 2) # <<<<<<<<<<<<<<
* def items(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_c_node, 2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1240; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_c_node, 2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1249; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1233
+ /* "src/lxml/lxml.etree.pyx":1242
* return _collectAttributes(self._c_node, 1)
*
* def values(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1242
+/* "src/lxml/lxml.etree.pyx":1251
* return _collectAttributes(self._c_node, 2)
*
* def items(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("items", 0);
- /* "src/lxml/lxml.etree.pyx":1248
+ /* "src/lxml/lxml.etree.pyx":1257
* an arbitrary order.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _collectAttributes(self._c_node, 3)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1257; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1249
+ /* "src/lxml/lxml.etree.pyx":1258
* """
* _assertValidNode(self)
* return _collectAttributes(self._c_node, 3) # <<<<<<<<<<<<<<
* def getchildren(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_c_node, 3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1249; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_c_node, 3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1258; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1242
+ /* "src/lxml/lxml.etree.pyx":1251
* return _collectAttributes(self._c_node, 2)
*
* def items(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1251
+/* "src/lxml/lxml.etree.pyx":1260
* return _collectAttributes(self._c_node, 3)
*
* def getchildren(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("getchildren", 0);
- /* "src/lxml/lxml.etree.pyx":1261
+ /* "src/lxml/lxml.etree.pyx":1270
* ``list(element)`` or simply iterate over elements.
* """
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return _collectChildren(self)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1261; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1270; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1262
+ /* "src/lxml/lxml.etree.pyx":1271
* """
* _assertValidNode(self)
* return _collectChildren(self) # <<<<<<<<<<<<<<
* def getparent(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree__collectChildren(__pyx_v_self); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1262; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__collectChildren(__pyx_v_self); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1271; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1251
+ /* "src/lxml/lxml.etree.pyx":1260
* return _collectAttributes(self._c_node, 3)
*
* def getchildren(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1264
+/* "src/lxml/lxml.etree.pyx":1273
* return _collectChildren(self)
*
* def getparent(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("getparent", 0);
- /* "src/lxml/lxml.etree.pyx":1271
+ /* "src/lxml/lxml.etree.pyx":1280
* cdef xmlNode* c_node
* #_assertValidNode(self) # not needed
* c_node = _parentElement(self._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__parentElement(__pyx_v_self->_c_node);
- /* "src/lxml/lxml.etree.pyx":1272
+ /* "src/lxml/lxml.etree.pyx":1281
* #_assertValidNode(self) # not needed
* c_node = _parentElement(self._c_node)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1273
+ /* "src/lxml/lxml.etree.pyx":1282
* c_node = _parentElement(self._c_node)
* if c_node is NULL:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1274
+ /* "src/lxml/lxml.etree.pyx":1283
* if c_node is NULL:
* return None
* return _elementFactory(self._doc, c_node) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_2 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_2), __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1274; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_2), __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1283; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1264
+ /* "src/lxml/lxml.etree.pyx":1273
* return _collectChildren(self)
*
* def getparent(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1276
+/* "src/lxml/lxml.etree.pyx":1285
* return _elementFactory(self._doc, c_node)
*
* def getnext(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("getnext", 0);
- /* "src/lxml/lxml.etree.pyx":1283
+ /* "src/lxml/lxml.etree.pyx":1292
* cdef xmlNode* c_node
* #_assertValidNode(self) # not needed
* c_node = _nextElement(self._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__nextElement(__pyx_v_self->_c_node);
- /* "src/lxml/lxml.etree.pyx":1284
+ /* "src/lxml/lxml.etree.pyx":1293
* #_assertValidNode(self) # not needed
* c_node = _nextElement(self._c_node)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1285
+ /* "src/lxml/lxml.etree.pyx":1294
* c_node = _nextElement(self._c_node)
* if c_node is NULL:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1286
+ /* "src/lxml/lxml.etree.pyx":1295
* if c_node is NULL:
* return None
* return _elementFactory(self._doc, c_node) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_2 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_2), __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1286; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_2), __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1295; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1276
+ /* "src/lxml/lxml.etree.pyx":1285
* return _elementFactory(self._doc, c_node)
*
* def getnext(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1288
+/* "src/lxml/lxml.etree.pyx":1297
* return _elementFactory(self._doc, c_node)
*
* def getprevious(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("getprevious", 0);
- /* "src/lxml/lxml.etree.pyx":1295
+ /* "src/lxml/lxml.etree.pyx":1304
* cdef xmlNode* c_node
* #_assertValidNode(self) # not needed
* c_node = _previousElement(self._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__previousElement(__pyx_v_self->_c_node);
- /* "src/lxml/lxml.etree.pyx":1296
+ /* "src/lxml/lxml.etree.pyx":1305
* #_assertValidNode(self) # not needed
* c_node = _previousElement(self._c_node)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1297
+ /* "src/lxml/lxml.etree.pyx":1306
* c_node = _previousElement(self._c_node)
* if c_node is NULL:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1298
+ /* "src/lxml/lxml.etree.pyx":1307
* if c_node is NULL:
* return None
* return _elementFactory(self._doc, c_node) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_2 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_2), __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1298; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_2), __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1288
+ /* "src/lxml/lxml.etree.pyx":1297
* return _elementFactory(self._doc, c_node)
*
* def getprevious(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1300
+/* "src/lxml/lxml.etree.pyx":1309
* return _elementFactory(self._doc, c_node)
*
* def itersiblings(self, tag=None, *tags, preceding=False): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "itersiblings") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1300; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "itersiblings") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1309; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("itersiblings", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":1314
+ /* "src/lxml/lxml.etree.pyx":1323
* see `iter`.
* """
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1315
+ /* "src/lxml/lxml.etree.pyx":1324
* """
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return SiblingsIterator(self, tags, preceding=preceding)
*
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1315; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1324; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1315; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1324; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1316
+ /* "src/lxml/lxml.etree.pyx":1325
* if tag is not None:
* tags += (tag,)
* return SiblingsIterator(self, tags, preceding=preceding) # <<<<<<<<<<<<<<
* def iterancestors(self, tag=None, *tags):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_preceding, __pyx_v_preceding) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_SiblingsIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_preceding, __pyx_v_preceding) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_SiblingsIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_5 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1300
+ /* "src/lxml/lxml.etree.pyx":1309
* return _elementFactory(self._doc, c_node)
*
* def itersiblings(self, tag=None, *tags, preceding=False): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1318
+/* "src/lxml/lxml.etree.pyx":1327
* return SiblingsIterator(self, tags, preceding=preceding)
*
* def iterancestors(self, tag=None, *tags): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iterancestors") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1318; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iterancestors") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1327; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("iterancestors", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":1326
+ /* "src/lxml/lxml.etree.pyx":1335
* see `iter`.
* """
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1327
+ /* "src/lxml/lxml.etree.pyx":1336
* """
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return AncestorsIterator(self, tags)
*
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1327; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1327; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1328
+ /* "src/lxml/lxml.etree.pyx":1337
* if tag is not None:
* tags += (tag,)
* return AncestorsIterator(self, tags) # <<<<<<<<<<<<<<
* def iterdescendants(self, tag=None, *tags):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1328; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1337; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_AncestorsIterator)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1328; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_AncestorsIterator)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1337; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1318
+ /* "src/lxml/lxml.etree.pyx":1327
* return SiblingsIterator(self, tags, preceding=preceding)
*
* def iterancestors(self, tag=None, *tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1330
+/* "src/lxml/lxml.etree.pyx":1339
* return AncestorsIterator(self, tags)
*
* def iterdescendants(self, tag=None, *tags): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iterdescendants") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1330; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iterdescendants") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1339; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("iterdescendants", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":1339
+ /* "src/lxml/lxml.etree.pyx":1348
* with a specific tag, see `iter`.
* """
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1340
+ /* "src/lxml/lxml.etree.pyx":1349
* """
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return ElementDepthFirstIterator(self, tags, inclusive=False)
*
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1340; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1349; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1340; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1349; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1341
+ /* "src/lxml/lxml.etree.pyx":1350
* if tag is not None:
* tags += (tag,)
* return ElementDepthFirstIterator(self, tags, inclusive=False) # <<<<<<<<<<<<<<
* def iterchildren(self, tag=None, *tags, reversed=False):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1341; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1350; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1341; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1350; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_inclusive, Py_False) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1341; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementDepthFirstIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1341; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_inclusive, Py_False) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1350; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementDepthFirstIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1350; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_5 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1330
+ /* "src/lxml/lxml.etree.pyx":1339
* return AncestorsIterator(self, tags)
*
* def iterdescendants(self, tag=None, *tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1343
+/* "src/lxml/lxml.etree.pyx":1352
* return ElementDepthFirstIterator(self, tags, inclusive=False)
*
* def iterchildren(self, tag=None, *tags, reversed=False): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iterchildren") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1343; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iterchildren") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1352; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("iterchildren", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":1352
+ /* "src/lxml/lxml.etree.pyx":1361
* to find only elements with a specific tag, see `iter`.
* """
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1353
+ /* "src/lxml/lxml.etree.pyx":1362
* """
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return ElementChildIterator(self, tags, reversed=reversed)
*
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1362; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1362; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1354
+ /* "src/lxml/lxml.etree.pyx":1363
* if tag is not None:
* tags += (tag,)
* return ElementChildIterator(self, tags, reversed=reversed) # <<<<<<<<<<<<<<
* def getroottree(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1354; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1363; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1354; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1363; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_reversed, __pyx_v_reversed) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1354; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementChildIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1354; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_reversed, __pyx_v_reversed) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1363; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementChildIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1363; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_5 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1343
+ /* "src/lxml/lxml.etree.pyx":1352
* return ElementDepthFirstIterator(self, tags, inclusive=False)
*
* def iterchildren(self, tag=None, *tags, reversed=False): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1356
+/* "src/lxml/lxml.etree.pyx":1365
* return ElementChildIterator(self, tags, reversed=reversed)
*
* def getroottree(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("getroottree", 0);
- /* "src/lxml/lxml.etree.pyx":1365
+ /* "src/lxml/lxml.etree.pyx":1374
* returns None (for the root element) and then build an ElementTree for
* the last parent that was returned."""
* _assertValidDoc(self._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1365; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":1366
+ /* "src/lxml/lxml.etree.pyx":1375
* the last parent that was returned."""
* _assertValidDoc(self._doc)
* return _elementTreeFactory(self._doc, None) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_1 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_1), ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1366; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_1), ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1375; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1356
+ /* "src/lxml/lxml.etree.pyx":1365
* return ElementChildIterator(self, tags, reversed=reversed)
*
* def getroottree(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1368
+/* "src/lxml/lxml.etree.pyx":1377
* return _elementTreeFactory(self._doc, None)
*
* def getiterator(self, tag=None, *tags): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "getiterator") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1368; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "getiterator") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1377; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("getiterator", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":1386
+ /* "src/lxml/lxml.etree.pyx":1395
* with older versions of lxml or ElementTree.
* """
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1387
+ /* "src/lxml/lxml.etree.pyx":1396
* """
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return ElementDepthFirstIterator(self, tags)
*
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1396; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1396; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1388
+ /* "src/lxml/lxml.etree.pyx":1397
* if tag is not None:
* tags += (tag,)
* return ElementDepthFirstIterator(self, tags) # <<<<<<<<<<<<<<
* def iter(self, tag=None, *tags):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1397; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementDepthFirstIterator)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementDepthFirstIterator)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1397; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1368
+ /* "src/lxml/lxml.etree.pyx":1377
* return _elementTreeFactory(self._doc, None)
*
* def getiterator(self, tag=None, *tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1390
+/* "src/lxml/lxml.etree.pyx":1399
* return ElementDepthFirstIterator(self, tags)
*
* def iter(self, tag=None, *tags): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iter") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1390; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iter") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1399; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("iter", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":1409
+ /* "src/lxml/lxml.etree.pyx":1418
* matching any of these tags, in document order.
* """
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1410
+ /* "src/lxml/lxml.etree.pyx":1419
* """
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return ElementDepthFirstIterator(self, tags)
*
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1410; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1410; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1411
+ /* "src/lxml/lxml.etree.pyx":1420
* if tag is not None:
* tags += (tag,)
* return ElementDepthFirstIterator(self, tags) # <<<<<<<<<<<<<<
* def itertext(self, tag=None, *tags, with_tail=True):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1411; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1420; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementDepthFirstIterator)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1411; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementDepthFirstIterator)), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1420; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1390
+ /* "src/lxml/lxml.etree.pyx":1399
* return ElementDepthFirstIterator(self, tags)
*
* def iter(self, tag=None, *tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1413
+/* "src/lxml/lxml.etree.pyx":1422
* return ElementDepthFirstIterator(self, tags)
*
* def itertext(self, tag=None, *tags, with_tail=True): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "itertext") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1413; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "itertext") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1422; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("itertext", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":1424
+ /* "src/lxml/lxml.etree.pyx":1433
* over tail text.
* """
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1425
+ /* "src/lxml/lxml.etree.pyx":1434
* """
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return ElementTextIterator(self, tags, with_tail=with_tail)
*
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1425; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1425; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1426
+ /* "src/lxml/lxml.etree.pyx":1435
* if tag is not None:
* tags += (tag,)
* return ElementTextIterator(self, tags, with_tail=with_tail) # <<<<<<<<<<<<<<
* def makeelement(self, _tag, attrib=None, nsmap=None, **_extra):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_with_tail, __pyx_v_with_tail) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementTextIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_with_tail, __pyx_v_with_tail) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_ElementTextIterator)), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_5 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1413
+ /* "src/lxml/lxml.etree.pyx":1422
* return ElementDepthFirstIterator(self, tags)
*
* def itertext(self, tag=None, *tags, with_tail=True): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1428
+/* "src/lxml/lxml.etree.pyx":1437
* return ElementTextIterator(self, tags, with_tail=with_tail)
*
* def makeelement(self, _tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "makeelement") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1428; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "makeelement") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1437; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("makeelement", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1428; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("makeelement", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1437; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v__extra); __pyx_v__extra = 0;
__Pyx_AddTraceback("lxml.etree._Element.makeelement", __pyx_clineno, __pyx_lineno, __pyx_filename);
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("makeelement", 0);
- /* "src/lxml/lxml.etree.pyx":1433
+ /* "src/lxml/lxml.etree.pyx":1442
* Creates a new element associated with the same document.
* """
* _assertValidDoc(self._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1433; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1442; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":1434
+ /* "src/lxml/lxml.etree.pyx":1443
* """
* _assertValidDoc(self._doc)
* return _makeElement(_tag, NULL, self._doc, None, None, None, # <<<<<<<<<<<<<<
__pyx_t_1 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_1);
- /* "src/lxml/lxml.etree.pyx":1435
+ /* "src/lxml/lxml.etree.pyx":1444
* _assertValidDoc(self._doc)
* return _makeElement(_tag, NULL, self._doc, None, None, None,
* attrib, nsmap, _extra) # <<<<<<<<<<<<<<
*
* def find(self, path, namespaces=None):
*/
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__makeElement(__pyx_v__tag, NULL, ((struct LxmlDocument *)__pyx_t_1), ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None), Py_None, Py_None, __pyx_v_attrib, __pyx_v_nsmap, __pyx_v__extra)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1434; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__makeElement(__pyx_v__tag, NULL, ((struct LxmlDocument *)__pyx_t_1), ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None), Py_None, Py_None, __pyx_v_attrib, __pyx_v_nsmap, __pyx_v__extra)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1443; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1428
+ /* "src/lxml/lxml.etree.pyx":1437
* return ElementTextIterator(self, tags, with_tail=with_tail)
*
* def makeelement(self, _tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1437
+/* "src/lxml/lxml.etree.pyx":1446
* attrib, nsmap, _extra)
*
* def find(self, path, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "find") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1437; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "find") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1446; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("find", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1437; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("find", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1446; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.find", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("find", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":1446
+ /* "src/lxml/lxml.etree.pyx":1455
* prefixes in the path expression.
* """
* if isinstance(path, QName): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1447
+ /* "src/lxml/lxml.etree.pyx":1456
* """
* if isinstance(path, QName):
* path = (<QName>path).text # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1448
+ /* "src/lxml/lxml.etree.pyx":1457
* if isinstance(path, QName):
* path = (<QName>path).text
* return _elementpath.find(self, path, namespaces) # <<<<<<<<<<<<<<
* def findtext(self, path, default=None, namespaces=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_find); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1448; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_find); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1448; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_5) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1448; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1437
+ /* "src/lxml/lxml.etree.pyx":1446
* attrib, nsmap, _extra)
*
* def find(self, path, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1450
+/* "src/lxml/lxml.etree.pyx":1459
* return _elementpath.find(self, path, namespaces)
*
* def findtext(self, path, default=None, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findtext") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1450; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findtext") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1459; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("findtext", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1450; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("findtext", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1459; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.findtext", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("findtext", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":1459
+ /* "src/lxml/lxml.etree.pyx":1468
* prefixes in the path expression.
* """
* if isinstance(path, QName): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1460
+ /* "src/lxml/lxml.etree.pyx":1469
* """
* if isinstance(path, QName):
* path = (<QName>path).text # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1461
+ /* "src/lxml/lxml.etree.pyx":1470
* if isinstance(path, QName):
* path = (<QName>path).text
* return _elementpath.findtext(self, path, default, namespaces) # <<<<<<<<<<<<<<
* def findall(self, path, namespaces=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_findtext); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1461; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_findtext); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1470; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(4+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1461; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(4+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1470; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_5) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 3+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1461; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1470; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1450
+ /* "src/lxml/lxml.etree.pyx":1459
* return _elementpath.find(self, path, namespaces)
*
* def findtext(self, path, default=None, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1463
+/* "src/lxml/lxml.etree.pyx":1472
* return _elementpath.findtext(self, path, default, namespaces)
*
* def findall(self, path, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findall") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1463; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findall") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1472; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("findall", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1463; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("findall", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1472; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.findall", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("findall", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":1472
+ /* "src/lxml/lxml.etree.pyx":1481
* prefixes in the path expression.
* """
* if isinstance(path, QName): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1473
+ /* "src/lxml/lxml.etree.pyx":1482
* """
* if isinstance(path, QName):
* path = (<QName>path).text # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1474
+ /* "src/lxml/lxml.etree.pyx":1483
* if isinstance(path, QName):
* path = (<QName>path).text
* return _elementpath.findall(self, path, namespaces) # <<<<<<<<<<<<<<
* def iterfind(self, path, namespaces=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_findall); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1474; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_findall); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1483; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1474; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1483; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_5) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1474; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1483; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1463
+ /* "src/lxml/lxml.etree.pyx":1472
* return _elementpath.findtext(self, path, default, namespaces)
*
* def findall(self, path, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1476
+/* "src/lxml/lxml.etree.pyx":1485
* return _elementpath.findall(self, path, namespaces)
*
* def iterfind(self, path, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "iterfind") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1476; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "iterfind") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1485; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("iterfind", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1476; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("iterfind", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1485; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Element.iterfind", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("iterfind", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":1485
+ /* "src/lxml/lxml.etree.pyx":1494
* prefixes in the path expression.
* """
* if isinstance(path, QName): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1486
+ /* "src/lxml/lxml.etree.pyx":1495
* """
* if isinstance(path, QName):
* path = (<QName>path).text # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1487
+ /* "src/lxml/lxml.etree.pyx":1496
* if isinstance(path, QName):
* path = (<QName>path).text
* return _elementpath.iterfind(self, path, namespaces) # <<<<<<<<<<<<<<
* def xpath(self, _path, *, namespaces=None, extensions=None,
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_iterfind); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1487; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__elementpath, __pyx_n_s_iterfind); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1496; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1487; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1496; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_5) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1487; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1496; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1476
+ /* "src/lxml/lxml.etree.pyx":1485
* return _elementpath.findall(self, path, namespaces)
*
* def iterfind(self, path, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1489
+/* "src/lxml/lxml.etree.pyx":1498
* return _elementpath.iterfind(self, path, namespaces)
*
* def xpath(self, _path, *, namespaces=None, extensions=None, # <<<<<<<<<<<<<<
values[1] = ((PyObject *)Py_None);
values[2] = ((PyObject *)Py_None);
- /* "src/lxml/lxml.etree.pyx":1490
+ /* "src/lxml/lxml.etree.pyx":1499
*
* def xpath(self, _path, *, namespaces=None, extensions=None,
* smart_strings=True, **_variables): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__variables, values, pos_args, "xpath") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1489; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__variables, values, pos_args, "xpath") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1498; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("xpath", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1489; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("xpath", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1498; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v__variables); __pyx_v__variables = 0;
__Pyx_AddTraceback("lxml.etree._Element.xpath", __pyx_clineno, __pyx_lineno, __pyx_filename);
__pyx_L4_argument_unpacking_done:;
__pyx_r = __pyx_pf_4lxml_5etree_8_Element_88xpath(((struct LxmlElement *)__pyx_v_self), __pyx_v__path, __pyx_v_namespaces, __pyx_v_extensions, __pyx_v_smart_strings, __pyx_v__variables);
- /* "src/lxml/lxml.etree.pyx":1489
+ /* "src/lxml/lxml.etree.pyx":1498
* return _elementpath.iterfind(self, path, namespaces)
*
* def xpath(self, _path, *, namespaces=None, extensions=None, # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("xpath", 0);
- /* "src/lxml/lxml.etree.pyx":1495
+ /* "src/lxml/lxml.etree.pyx":1504
* Evaluate an xpath expression using the element as context node.
* """
* evaluator = XPathElementEvaluator(self, namespaces=namespaces, # <<<<<<<<<<<<<<
* extensions=extensions,
* smart_strings=smart_strings)
*/
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_namespaces, __pyx_v_namespaces) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_namespaces, __pyx_v_namespaces) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1496
+ /* "src/lxml/lxml.etree.pyx":1505
* """
* evaluator = XPathElementEvaluator(self, namespaces=namespaces,
* extensions=extensions, # <<<<<<<<<<<<<<
* smart_strings=smart_strings)
* return evaluator(_path, **_variables)
*/
- if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_extensions, __pyx_v_extensions) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_extensions, __pyx_v_extensions) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1497
+ /* "src/lxml/lxml.etree.pyx":1506
* evaluator = XPathElementEvaluator(self, namespaces=namespaces,
* extensions=extensions,
* smart_strings=smart_strings) # <<<<<<<<<<<<<<
* return evaluator(_path, **_variables)
*
*/
- if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_smart_strings, __pyx_v_smart_strings) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_smart_strings, __pyx_v_smart_strings) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1495
+ /* "src/lxml/lxml.etree.pyx":1504
* Evaluate an xpath expression using the element as context node.
* """
* evaluator = XPathElementEvaluator(self, namespaces=namespaces, # <<<<<<<<<<<<<<
* extensions=extensions,
* smart_strings=smart_strings)
*/
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPathElementEvaluator)), __pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPathElementEvaluator)), __pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_v_evaluator = ((struct __pyx_obj_4lxml_5etree_XPathElementEvaluator *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":1498
+ /* "src/lxml/lxml.etree.pyx":1507
* extensions=extensions,
* smart_strings=smart_strings)
* return evaluator(_path, **_variables) # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1498; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1507; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v__path);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v__path);
__Pyx_GIVEREF(__pyx_v__path);
__pyx_t_2 = __pyx_v__variables;
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_evaluator), __pyx_t_3, __pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1498; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_evaluator), __pyx_t_3, __pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1507; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1489
+ /* "src/lxml/lxml.etree.pyx":1498
* return _elementpath.iterfind(self, path, namespaces)
*
* def xpath(self, _path, *, namespaces=None, extensions=None, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1505
+/* "src/lxml/lxml.etree.pyx":1514
* cdef object NEW_ELEMENT "PY_NEW" (object t)
*
* cdef _Element _elementFactory(_Document doc, xmlNode* c_node): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_elementFactory", 0);
- /* "src/lxml/lxml.etree.pyx":1507
+ /* "src/lxml/lxml.etree.pyx":1516
* cdef _Element _elementFactory(_Document doc, xmlNode* c_node):
* cdef _Element result
* result = getProxy(c_node) # <<<<<<<<<<<<<<
* if result is not None:
* return result
*/
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree_getProxy(__pyx_v_c_node)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1507; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree_getProxy(__pyx_v_c_node)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1516; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_result = ((struct LxmlElement *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":1508
+ /* "src/lxml/lxml.etree.pyx":1517
* cdef _Element result
* result = getProxy(c_node)
* if result is not None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1509
+ /* "src/lxml/lxml.etree.pyx":1518
* result = getProxy(c_node)
* if result is not None:
* return result # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1510
+ /* "src/lxml/lxml.etree.pyx":1519
* if result is not None:
* return result
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1511
+ /* "src/lxml/lxml.etree.pyx":1520
* return result
* if c_node is NULL:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1514
+ /* "src/lxml/lxml.etree.pyx":1523
*
* element_class = LOOKUP_ELEMENT_CLASS(
* ELEMENT_CLASS_LOOKUP_STATE, doc, c_node) # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_4lxml_5etree_ELEMENT_CLASS_LOOKUP_STATE;
__Pyx_INCREF(__pyx_t_1);
- /* "src/lxml/lxml.etree.pyx":1513
+ /* "src/lxml/lxml.etree.pyx":1522
* return None
*
* element_class = LOOKUP_ELEMENT_CLASS( # <<<<<<<<<<<<<<
* ELEMENT_CLASS_LOOKUP_STATE, doc, c_node)
* if hasProxy(c_node):
*/
- __pyx_t_4 = __pyx_v_4lxml_5etree_LOOKUP_ELEMENT_CLASS(__pyx_t_1, __pyx_v_doc, __pyx_v_c_node); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1513; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_v_4lxml_5etree_LOOKUP_ELEMENT_CLASS(__pyx_t_1, __pyx_v_doc, __pyx_v_c_node); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1522; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_v_element_class = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1515
+ /* "src/lxml/lxml.etree.pyx":1524
* element_class = LOOKUP_ELEMENT_CLASS(
* ELEMENT_CLASS_LOOKUP_STATE, doc, c_node)
* if hasProxy(c_node): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_f_4lxml_5etree_hasProxy(__pyx_v_c_node) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1517
+ /* "src/lxml/lxml.etree.pyx":1526
* if hasProxy(c_node):
* # prevent re-entry race condition - we just called into Python
* return getProxy(c_node) # <<<<<<<<<<<<<<
* if hasProxy(c_node):
*/
__Pyx_XDECREF(((PyObject *)__pyx_r));
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree_getProxy(__pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1517; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree_getProxy(__pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = ((struct LxmlElement *)__pyx_t_4);
__pyx_t_4 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1518
+ /* "src/lxml/lxml.etree.pyx":1527
* # prevent re-entry race condition - we just called into Python
* return getProxy(c_node)
* result = NEW_ELEMENT(element_class) # <<<<<<<<<<<<<<
* if hasProxy(c_node):
* # prevent re-entry race condition - we just called into Python
*/
- __pyx_t_4 = PY_NEW(__pyx_v_element_class); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1518; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PY_NEW(__pyx_v_element_class); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1527; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1518; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1527; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF_SET(__pyx_v_result, ((struct LxmlElement *)__pyx_t_4));
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1519
+ /* "src/lxml/lxml.etree.pyx":1528
* return getProxy(c_node)
* result = NEW_ELEMENT(element_class)
* if hasProxy(c_node): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_f_4lxml_5etree_hasProxy(__pyx_v_c_node) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1521
+ /* "src/lxml/lxml.etree.pyx":1530
* if hasProxy(c_node):
* # prevent re-entry race condition - we just called into Python
* result._c_node = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_result->_c_node = NULL;
- /* "src/lxml/lxml.etree.pyx":1522
+ /* "src/lxml/lxml.etree.pyx":1531
* # prevent re-entry race condition - we just called into Python
* result._c_node = NULL
* return getProxy(c_node) # <<<<<<<<<<<<<<
* _registerProxy(result, doc, c_node)
*/
__Pyx_XDECREF(((PyObject *)__pyx_r));
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree_getProxy(__pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1522; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree_getProxy(__pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = ((struct LxmlElement *)__pyx_t_4);
__pyx_t_4 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1524
+ /* "src/lxml/lxml.etree.pyx":1533
* return getProxy(c_node)
*
* _registerProxy(result, doc, c_node) # <<<<<<<<<<<<<<
* if element_class is not _Element:
* result._init()
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__registerProxy(__pyx_v_result, __pyx_v_doc, __pyx_v_c_node); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1524; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__registerProxy(__pyx_v_result, __pyx_v_doc, __pyx_v_c_node); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1533; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1525
+ /* "src/lxml/lxml.etree.pyx":1534
*
* _registerProxy(result, doc, c_node)
* if element_class is not _Element: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1526
+ /* "src/lxml/lxml.etree.pyx":1535
* _registerProxy(result, doc, c_node)
* if element_class is not _Element:
* result._init() # <<<<<<<<<<<<<<
* return result
*
*/
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_result), __pyx_n_s_init_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_result), __pyx_n_s_init_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_1))) {
}
}
if (__pyx_t_6) {
- __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
- __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1526; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1535; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
}
__pyx_L7:;
- /* "src/lxml/lxml.etree.pyx":1527
+ /* "src/lxml/lxml.etree.pyx":1536
* if element_class is not _Element:
* result._init()
* return result # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_result;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1505
+ /* "src/lxml/lxml.etree.pyx":1514
* cdef object NEW_ELEMENT "PY_NEW" (object t)
*
* cdef _Element _elementFactory(_Document doc, xmlNode* c_node): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1532
+/* "src/lxml/lxml.etree.pyx":1541
* @cython.internal
* cdef class __ContentOnlyElement(_Element):
* cdef int _raiseImmutable(self) except -1: # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_raiseImmutable", 0);
- /* "src/lxml/lxml.etree.pyx":1533
+ /* "src/lxml/lxml.etree.pyx":1542
* cdef class __ContentOnlyElement(_Element):
* cdef int _raiseImmutable(self) except -1:
* raise TypeError, u"this element does not have children or attributes" # <<<<<<<<<<<<<<
* def set(self, key, value):
*/
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_u_this_element_does_not_have_child, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1533; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1542; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1532
+ /* "src/lxml/lxml.etree.pyx":1541
* @cython.internal
* cdef class __ContentOnlyElement(_Element):
* cdef int _raiseImmutable(self) except -1: # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1535
+/* "src/lxml/lxml.etree.pyx":1544
* raise TypeError, u"this element does not have children or attributes"
*
* def set(self, key, value): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1535; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1544; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1535; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1544; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1535; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1544; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.__ContentOnlyElement.set", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("set", 0);
- /* "src/lxml/lxml.etree.pyx":1537
+ /* "src/lxml/lxml.etree.pyx":1546
* def set(self, key, value):
* u"set(self, key, value)"
* self._raiseImmutable() # <<<<<<<<<<<<<<
*
* def append(self, value):
*/
- __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1537; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1546; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1535
+ /* "src/lxml/lxml.etree.pyx":1544
* raise TypeError, u"this element does not have children or attributes"
*
* def set(self, key, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1539
+/* "src/lxml/lxml.etree.pyx":1548
* self._raiseImmutable()
*
* def append(self, value): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("append", 0);
- /* "src/lxml/lxml.etree.pyx":1541
+ /* "src/lxml/lxml.etree.pyx":1550
* def append(self, value):
* u"append(self, value)"
* self._raiseImmutable() # <<<<<<<<<<<<<<
*
* def insert(self, index, value):
*/
- __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1541; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1550; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1539
+ /* "src/lxml/lxml.etree.pyx":1548
* self._raiseImmutable()
*
* def append(self, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1543
+/* "src/lxml/lxml.etree.pyx":1552
* self._raiseImmutable()
*
* def insert(self, index, value): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1543; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1552; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "insert") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1543; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "insert") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1552; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1543; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("insert", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1552; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.__ContentOnlyElement.insert", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("insert", 0);
- /* "src/lxml/lxml.etree.pyx":1545
+ /* "src/lxml/lxml.etree.pyx":1554
* def insert(self, index, value):
* u"insert(self, index, value)"
* self._raiseImmutable() # <<<<<<<<<<<<<<
*
* def __setitem__(self, index, value):
*/
- __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1545; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1554; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1543
+ /* "src/lxml/lxml.etree.pyx":1552
* self._raiseImmutable()
*
* def insert(self, index, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1547
+/* "src/lxml/lxml.etree.pyx":1556
* self._raiseImmutable()
*
* def __setitem__(self, index, value): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__setitem__", 0);
- /* "src/lxml/lxml.etree.pyx":1549
+ /* "src/lxml/lxml.etree.pyx":1558
* def __setitem__(self, index, value):
* u"__setitem__(self, index, value)"
* self._raiseImmutable() # <<<<<<<<<<<<<<
*
* property attrib:
*/
- __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1549; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree___ContentOnlyElement *)__pyx_v_self->__pyx_vtab)->_raiseImmutable(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1558; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1547
+ /* "src/lxml/lxml.etree.pyx":1556
* self._raiseImmutable()
*
* def __setitem__(self, index, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1552
+/* "src/lxml/lxml.etree.pyx":1561
*
* property attrib:
* def __get__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1553
+ /* "src/lxml/lxml.etree.pyx":1562
* property attrib:
* def __get__(self):
* return IMMUTABLE_EMPTY_MAPPING # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_4lxml_5etree_IMMUTABLE_EMPTY_MAPPING;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1552
+ /* "src/lxml/lxml.etree.pyx":1561
*
* property attrib:
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1556
+/* "src/lxml/lxml.etree.pyx":1565
*
* property text:
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1557
+ /* "src/lxml/lxml.etree.pyx":1566
* property text:
* def __get__(self):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return funicodeOrEmpty(self._c_node.content)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1557; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1566; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1558
+ /* "src/lxml/lxml.etree.pyx":1567
* def __get__(self):
* _assertValidNode(self)
* return funicodeOrEmpty(self._c_node.content) # <<<<<<<<<<<<<<
* def __set__(self, value):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree_funicodeOrEmpty(__pyx_v_self->__pyx_base._c_node->content); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1558; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_funicodeOrEmpty(__pyx_v_self->__pyx_base._c_node->content); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1567; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1556
+ /* "src/lxml/lxml.etree.pyx":1565
*
* property text:
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1560
+/* "src/lxml/lxml.etree.pyx":1569
* return funicodeOrEmpty(self._c_node.content)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("__set__", 0);
__Pyx_INCREF(__pyx_v_value);
- /* "src/lxml/lxml.etree.pyx":1562
+ /* "src/lxml/lxml.etree.pyx":1571
* def __set__(self, value):
* cdef tree.xmlDict* c_dict
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if value is None:
* c_text = <const_xmlChar*>NULL
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1562; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1571; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1563
+ /* "src/lxml/lxml.etree.pyx":1572
* cdef tree.xmlDict* c_dict
* _assertValidNode(self)
* if value is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1564
+ /* "src/lxml/lxml.etree.pyx":1573
* _assertValidNode(self)
* if value is None:
* c_text = <const_xmlChar*>NULL # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1566
+ /* "src/lxml/lxml.etree.pyx":1575
* c_text = <const_xmlChar*>NULL
* else:
* value = _utf8(value) # <<<<<<<<<<<<<<
* c_text = _xcstr(value)
* tree.xmlNodeSetContent(self._c_node, c_text)
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1566; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1575; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_value, __pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1567
+ /* "src/lxml/lxml.etree.pyx":1576
* else:
* value = _utf8(value)
* c_text = _xcstr(value) # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1568
+ /* "src/lxml/lxml.etree.pyx":1577
* value = _utf8(value)
* c_text = _xcstr(value)
* tree.xmlNodeSetContent(self._c_node, c_text) # <<<<<<<<<<<<<<
*/
xmlNodeSetContent(__pyx_v_self->__pyx_base._c_node, __pyx_v_c_text);
- /* "src/lxml/lxml.etree.pyx":1560
+ /* "src/lxml/lxml.etree.pyx":1569
* return funicodeOrEmpty(self._c_node.content)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1571
+/* "src/lxml/lxml.etree.pyx":1580
*
* # ACCESSORS
* def __getitem__(self, x): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__getitem__", 0);
- /* "src/lxml/lxml.etree.pyx":1573
+ /* "src/lxml/lxml.etree.pyx":1582
* def __getitem__(self, x):
* u"__getitem__(self, x)"
* if isinstance(x, slice): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1574
+ /* "src/lxml/lxml.etree.pyx":1583
* u"__getitem__(self, x)"
* if isinstance(x, slice):
* return [] # <<<<<<<<<<<<<<
* raise IndexError, u"list index out of range"
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1583; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1576
+ /* "src/lxml/lxml.etree.pyx":1585
* return []
* else:
* raise IndexError, u"list index out of range" # <<<<<<<<<<<<<<
* def __len__(self):
*/
__Pyx_Raise(__pyx_builtin_IndexError, __pyx_kp_u_list_index_out_of_range, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1576; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1585; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1571
+ /* "src/lxml/lxml.etree.pyx":1580
*
* # ACCESSORS
* def __getitem__(self, x): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1578
+/* "src/lxml/lxml.etree.pyx":1587
* raise IndexError, u"list index out of range"
*
* def __len__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__len__", 0);
- /* "src/lxml/lxml.etree.pyx":1580
+ /* "src/lxml/lxml.etree.pyx":1589
* def __len__(self):
* u"__len__(self)"
* return 0 # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1578
+ /* "src/lxml/lxml.etree.pyx":1587
* raise IndexError, u"list index out of range"
*
* def __len__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1582
+/* "src/lxml/lxml.etree.pyx":1591
* return 0
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1582; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1591; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1582; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1591; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.__ContentOnlyElement.get", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("get", 0);
- /* "src/lxml/lxml.etree.pyx":1584
+ /* "src/lxml/lxml.etree.pyx":1593
* def get(self, key, default=None):
* u"get(self, key, default=None)"
* return None # <<<<<<<<<<<<<<
__pyx_r = Py_None;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1582
+ /* "src/lxml/lxml.etree.pyx":1591
* return 0
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1586
+/* "src/lxml/lxml.etree.pyx":1595
* return None
*
* def keys(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("keys", 0);
- /* "src/lxml/lxml.etree.pyx":1588
+ /* "src/lxml/lxml.etree.pyx":1597
* def keys(self):
* u"keys(self)"
* return [] # <<<<<<<<<<<<<<
* def items(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1588; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1597; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1586
+ /* "src/lxml/lxml.etree.pyx":1595
* return None
*
* def keys(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1590
+/* "src/lxml/lxml.etree.pyx":1599
* return []
*
* def items(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("items", 0);
- /* "src/lxml/lxml.etree.pyx":1592
+ /* "src/lxml/lxml.etree.pyx":1601
* def items(self):
* u"items(self)"
* return [] # <<<<<<<<<<<<<<
* def values(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1590
+ /* "src/lxml/lxml.etree.pyx":1599
* return []
*
* def items(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1594
+/* "src/lxml/lxml.etree.pyx":1603
* return []
*
* def values(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("values", 0);
- /* "src/lxml/lxml.etree.pyx":1596
+ /* "src/lxml/lxml.etree.pyx":1605
* def values(self):
* u"values(self)"
* return [] # <<<<<<<<<<<<<<
* cdef class _Comment(__ContentOnlyElement):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1596; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1605; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1594
+ /* "src/lxml/lxml.etree.pyx":1603
* return []
*
* def values(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1600
+/* "src/lxml/lxml.etree.pyx":1609
* cdef class _Comment(__ContentOnlyElement):
* property tag:
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1601
+ /* "src/lxml/lxml.etree.pyx":1610
* property tag:
* def __get__(self):
* return Comment # <<<<<<<<<<<<<<
* def __repr__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Comment); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Comment); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1600
+ /* "src/lxml/lxml.etree.pyx":1609
* cdef class _Comment(__ContentOnlyElement):
* property tag:
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1603
+/* "src/lxml/lxml.etree.pyx":1612
* return Comment
*
* def __repr__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__repr__", 0);
- /* "src/lxml/lxml.etree.pyx":1604
+ /* "src/lxml/lxml.etree.pyx":1613
*
* def __repr__(self):
* return u"<!--%s-->" % self.text # <<<<<<<<<<<<<<
* cdef class _ProcessingInstruction(__ContentOnlyElement):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1604; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1613; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_s, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1604; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_s_3, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1613; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1603
+ /* "src/lxml/lxml.etree.pyx":1612
* return Comment
*
* def __repr__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1608
+/* "src/lxml/lxml.etree.pyx":1617
* cdef class _ProcessingInstruction(__ContentOnlyElement):
* property tag:
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1609
+ /* "src/lxml/lxml.etree.pyx":1618
* property tag:
* def __get__(self):
* return ProcessingInstruction # <<<<<<<<<<<<<<
* property target:
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1609; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1608
+ /* "src/lxml/lxml.etree.pyx":1617
* cdef class _ProcessingInstruction(__ContentOnlyElement):
* property tag:
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1613
+/* "src/lxml/lxml.etree.pyx":1622
* property target:
* # not in ElementTree
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1614
+ /* "src/lxml/lxml.etree.pyx":1623
* # not in ElementTree
* def __get__(self):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return funicode(self._c_node.name)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1623; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1615
+ /* "src/lxml/lxml.etree.pyx":1624
* def __get__(self):
* _assertValidNode(self)
* return funicode(self._c_node.name) # <<<<<<<<<<<<<<
* def __set__(self, value):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->__pyx_base.__pyx_base._c_node->name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->__pyx_base.__pyx_base._c_node->name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1624; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1613
+ /* "src/lxml/lxml.etree.pyx":1622
* property target:
* # not in ElementTree
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1617
+/* "src/lxml/lxml.etree.pyx":1626
* return funicode(self._c_node.name)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("__set__", 0);
__Pyx_INCREF(__pyx_v_value);
- /* "src/lxml/lxml.etree.pyx":1618
+ /* "src/lxml/lxml.etree.pyx":1627
*
* def __set__(self, value):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* value = _utf8(value)
* c_text = _xcstr(value)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1627; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1619
+ /* "src/lxml/lxml.etree.pyx":1628
* def __set__(self, value):
* _assertValidNode(self)
* value = _utf8(value) # <<<<<<<<<<<<<<
* c_text = _xcstr(value)
* tree.xmlNodeSetName(self._c_node, c_text)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF_SET(__pyx_v_value, __pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":1620
+ /* "src/lxml/lxml.etree.pyx":1629
* _assertValidNode(self)
* value = _utf8(value)
* c_text = _xcstr(value) # <<<<<<<<<<<<<<
*/
__pyx_v_c_text = (const xmlChar*)PyBytes_AS_STRING(__pyx_v_value);
- /* "src/lxml/lxml.etree.pyx":1621
+ /* "src/lxml/lxml.etree.pyx":1630
* value = _utf8(value)
* c_text = _xcstr(value)
* tree.xmlNodeSetName(self._c_node, c_text) # <<<<<<<<<<<<<<
*/
xmlNodeSetName(__pyx_v_self->__pyx_base.__pyx_base._c_node, __pyx_v_c_text);
- /* "src/lxml/lxml.etree.pyx":1617
+ /* "src/lxml/lxml.etree.pyx":1626
* return funicode(self._c_node.name)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1623
+/* "src/lxml/lxml.etree.pyx":1632
* tree.xmlNodeSetName(self._c_node, c_text)
*
* def __repr__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__repr__", 0);
- /* "src/lxml/lxml.etree.pyx":1624
+ /* "src/lxml/lxml.etree.pyx":1633
*
* def __repr__(self):
* text = self.text # <<<<<<<<<<<<<<
* if text:
* return u"<?%s %s?>" % (self.target, text)
*/
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1624; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_text = __pyx_t_1;
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":1625
+ /* "src/lxml/lxml.etree.pyx":1634
* def __repr__(self):
* text = self.text
* if text: # <<<<<<<<<<<<<<
* return u"<?%s %s?>" % (self.target, text)
* else:
*/
- __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_text); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1625; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_text); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1634; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1626
+ /* "src/lxml/lxml.etree.pyx":1635
* text = self.text
* if text:
* return u"<?%s %s?>" % (self.target, text) # <<<<<<<<<<<<<<
* return u"<?%s?>" % self.target
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_target); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1626; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_target); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1626; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_text);
__Pyx_GIVEREF(__pyx_v_text);
__pyx_t_1 = 0;
- __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_s_s_3, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1626; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_s_s_3, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_r = __pyx_t_1;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1628
+ /* "src/lxml/lxml.etree.pyx":1637
* return u"<?%s %s?>" % (self.target, text)
* else:
* return u"<?%s?>" % self.target # <<<<<<<<<<<<<<
* def get(self, key, default=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_target); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_target); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1637; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s_2, __pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s_4, __pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1637; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1623
+ /* "src/lxml/lxml.etree.pyx":1632
* tree.xmlNodeSetName(self._c_node, c_text)
*
* def __repr__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1630
+/* "src/lxml/lxml.etree.pyx":1639
* return u"<?%s?>" % self.target
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1630; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1639; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1630; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1639; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ProcessingInstruction.get", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("get", 0);
- /* "src/lxml/lxml.etree.pyx":1642
+ /* "src/lxml/lxml.etree.pyx":1651
* It is not guaranteed to work for all possible text content.
* """
* return self.attrib.get(key, default) # <<<<<<<<<<<<<<
* property attrib:
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_attrib); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1642; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_attrib); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1651; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_get); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1642; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_get); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1651; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_2 = NULL;
__pyx_t_4 = 1;
}
}
- __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1642; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1651; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
if (__pyx_t_2) {
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_2); __Pyx_GIVEREF(__pyx_t_2); __pyx_t_2 = NULL;
__Pyx_INCREF(__pyx_v_default);
PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_4, __pyx_v_default);
__Pyx_GIVEREF(__pyx_v_default);
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1642; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1651; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1630
+ /* "src/lxml/lxml.etree.pyx":1639
* return u"<?%s?>" % self.target
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1650
+/* "src/lxml/lxml.etree.pyx":1659
* XML node, although this is not guaranteed to stay this way.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1651
+ /* "src/lxml/lxml.etree.pyx":1660
* """
* def __get__(self):
* return { attr : (value1 or value2) # <<<<<<<<<<<<<<
PyObject *__pyx_7genexpr__pyx_v_attr = NULL;
PyObject *__pyx_7genexpr__pyx_v_value1 = NULL;
PyObject *__pyx_7genexpr__pyx_v_value2 = NULL;
- __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1651; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1660; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_1);
- /* "src/lxml/lxml.etree.pyx":1652
+ /* "src/lxml/lxml.etree.pyx":1661
* def __get__(self):
* return { attr : (value1 or value2)
* for attr, value1, value2 in _FIND_PI_ATTRIBUTES(u' ' + self.text) } # <<<<<<<<<<<<<<
*
* cdef object _FIND_PI_ATTRIBUTES = re.compile(ur'\s+(\w+)\s*=\s*(?:\'([^\']*)\'|"([^"]*)")', re.U).findall
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = PyNumber_Add(__pyx_kp_u__14, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_4 = PyNumber_Add(__pyx_kp_u__14, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_INCREF(__pyx_v_4lxml_5etree__FIND_PI_ATTRIBUTES);
}
}
if (!__pyx_t_5) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_GOTREF(__pyx_t_2);
} else {
- __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_6);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_t_4);
__Pyx_GIVEREF(__pyx_t_4);
__pyx_t_4 = 0;
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
__pyx_t_3 = __pyx_t_2; __Pyx_INCREF(__pyx_t_3); __pyx_t_7 = 0;
__pyx_t_8 = NULL;
} else {
- __pyx_t_7 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_7 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_8 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_8 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
for (;;) {
if (likely(PyList_CheckExact(__pyx_t_3))) {
if (__pyx_t_7 >= PyList_GET_SIZE(__pyx_t_3)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_2 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_7); __Pyx_INCREF(__pyx_t_2); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_2 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_7); __Pyx_INCREF(__pyx_t_2); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
#else
- __pyx_t_2 = PySequence_ITEM(__pyx_t_3, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_2 = PySequence_ITEM(__pyx_t_3, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
#endif
} else {
if (__pyx_t_7 >= PyTuple_GET_SIZE(__pyx_t_3)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_2 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_7); __Pyx_INCREF(__pyx_t_2); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_2 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_7); __Pyx_INCREF(__pyx_t_2); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
#else
- __pyx_t_2 = PySequence_ITEM(__pyx_t_3, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_2 = PySequence_ITEM(__pyx_t_3, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
#endif
}
} else {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
}
break;
}
if (unlikely(size != 3)) {
if (size > 3) __Pyx_RaiseTooManyValuesError(3);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_4);
__Pyx_INCREF(__pyx_t_5);
#else
- __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_5 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_5);
#endif
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_9 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_9 = PyObject_GetIter(__pyx_t_2); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_9);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_10 = Py_TYPE(__pyx_t_9)->tp_iternext;
__Pyx_GOTREF(__pyx_t_4);
index = 2; __pyx_t_5 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_5)) goto __pyx_L8_unpacking_failed;
__Pyx_GOTREF(__pyx_t_5);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_9), 3) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_9), 3) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__pyx_t_10 = NULL;
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
goto __pyx_L9_unpacking_done;
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
__pyx_t_10 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1652; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1661; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__pyx_L9_unpacking_done:;
}
__Pyx_XDECREF_SET(__pyx_7genexpr__pyx_v_attr, __pyx_t_6);
__Pyx_XDECREF_SET(__pyx_7genexpr__pyx_v_value2, __pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":1651
+ /* "src/lxml/lxml.etree.pyx":1660
* """
* def __get__(self):
* return { attr : (value1 or value2) # <<<<<<<<<<<<<<
* for attr, value1, value2 in _FIND_PI_ATTRIBUTES(u' ' + self.text) }
*
*/
- __pyx_t_11 = __Pyx_PyObject_IsTrue(__pyx_7genexpr__pyx_v_value1); if (unlikely(__pyx_t_11 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1651; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_11 = __Pyx_PyObject_IsTrue(__pyx_7genexpr__pyx_v_value1); if (unlikely(__pyx_t_11 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1660; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
if (!__pyx_t_11) {
} else {
__Pyx_INCREF(__pyx_7genexpr__pyx_v_value1);
__Pyx_INCREF(__pyx_7genexpr__pyx_v_value2);
__pyx_t_2 = __pyx_7genexpr__pyx_v_value2;
__pyx_L10_bool_binop_done:;
- if (unlikely(PyDict_SetItem(__pyx_t_1, (PyObject*)__pyx_7genexpr__pyx_v_attr, (PyObject*)__pyx_t_2))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1651; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ if (unlikely(PyDict_SetItem(__pyx_t_1, (PyObject*)__pyx_7genexpr__pyx_v_attr, (PyObject*)__pyx_t_2))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1660; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":1652
+ /* "src/lxml/lxml.etree.pyx":1661
* def __get__(self):
* return { attr : (value1 or value2)
* for attr, value1, value2 in _FIND_PI_ATTRIBUTES(u' ' + self.text) } # <<<<<<<<<<<<<<
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1650
+ /* "src/lxml/lxml.etree.pyx":1659
* XML node, although this is not guaranteed to stay this way.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1658
+/* "src/lxml/lxml.etree.pyx":1667
* cdef class _Entity(__ContentOnlyElement):
* property tag:
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1659
+ /* "src/lxml/lxml.etree.pyx":1668
* property tag:
* def __get__(self):
* return Entity # <<<<<<<<<<<<<<
* property name:
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Entity); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1659; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Entity); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1658
+ /* "src/lxml/lxml.etree.pyx":1667
* cdef class _Entity(__ContentOnlyElement):
* property tag:
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1663
+/* "src/lxml/lxml.etree.pyx":1672
* property name:
* # not in ElementTree
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1664
+ /* "src/lxml/lxml.etree.pyx":1673
* # not in ElementTree
* def __get__(self):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return funicode(self._c_node.name)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1664; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1673; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1665
+ /* "src/lxml/lxml.etree.pyx":1674
* def __get__(self):
* _assertValidNode(self)
* return funicode(self._c_node.name) # <<<<<<<<<<<<<<
* def __set__(self, value):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->__pyx_base.__pyx_base._c_node->name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1665; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->__pyx_base.__pyx_base._c_node->name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1674; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1663
+ /* "src/lxml/lxml.etree.pyx":1672
* property name:
* # not in ElementTree
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1667
+/* "src/lxml/lxml.etree.pyx":1676
* return funicode(self._c_node.name)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__set__", 0);
- /* "src/lxml/lxml.etree.pyx":1668
+ /* "src/lxml/lxml.etree.pyx":1677
*
* def __set__(self, value):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* value_utf = _utf8(value)
* if b'&' in value_utf or b';' in value_utf:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1677; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1669
+ /* "src/lxml/lxml.etree.pyx":1678
* def __set__(self, value):
* _assertValidNode(self)
* value_utf = _utf8(value) # <<<<<<<<<<<<<<
* if b'&' in value_utf or b';' in value_utf:
* raise ValueError(u"Invalid entity name '%s'" % value)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1678; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_v_value_utf = ((PyObject*)__pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":1670
+ /* "src/lxml/lxml.etree.pyx":1679
* _assertValidNode(self)
* value_utf = _utf8(value)
* if b'&' in value_utf or b';' in value_utf: # <<<<<<<<<<<<<<
* raise ValueError(u"Invalid entity name '%s'" % value)
* tree.xmlNodeSetName(self._c_node, _xcstr(value_utf))
*/
- __pyx_t_4 = (__Pyx_PySequence_Contains(__pyx_kp_b__25, __pyx_v_value_utf, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = (__Pyx_PySequence_Contains(__pyx_kp_b__26, __pyx_v_value_utf, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_5 = (__pyx_t_4 != 0);
if (!__pyx_t_5) {
} else {
__pyx_t_3 = __pyx_t_5;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_5 = (__Pyx_PySequence_Contains(__pyx_kp_b__26, __pyx_v_value_utf, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PySequence_Contains(__pyx_kp_b__27, __pyx_v_value_utf, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_4 = (__pyx_t_5 != 0);
__pyx_t_3 = __pyx_t_4;
__pyx_L4_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1671
+ /* "src/lxml/lxml.etree.pyx":1680
* value_utf = _utf8(value)
* if b'&' in value_utf or b';' in value_utf:
* raise ValueError(u"Invalid entity name '%s'" % value) # <<<<<<<<<<<<<<
* tree.xmlNodeSetName(self._c_node, _xcstr(value_utf))
*
*/
- __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_Invalid_entity_name_s, __pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_Invalid_entity_name_s, __pyx_v_value); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1680; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1680; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_2);
__Pyx_GIVEREF(__pyx_t_2);
__pyx_t_2 = 0;
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1680; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1680; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1672
+ /* "src/lxml/lxml.etree.pyx":1681
* if b'&' in value_utf or b';' in value_utf:
* raise ValueError(u"Invalid entity name '%s'" % value)
* tree.xmlNodeSetName(self._c_node, _xcstr(value_utf)) # <<<<<<<<<<<<<<
*/
xmlNodeSetName(__pyx_v_self->__pyx_base.__pyx_base._c_node, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_value_utf));
- /* "src/lxml/lxml.etree.pyx":1667
+ /* "src/lxml/lxml.etree.pyx":1676
* return funicode(self._c_node.name)
*
* def __set__(self, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1677
+/* "src/lxml/lxml.etree.pyx":1686
* # FIXME: should this be None or '&[VALUE];' or the resolved
* # entity value ?
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1678
+ /* "src/lxml/lxml.etree.pyx":1687
* # entity value ?
* def __get__(self):
* _assertValidNode(self) # <<<<<<<<<<<<<<
* return u'&%s;' % funicode(self._c_node.name)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1678; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1687; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1679
+ /* "src/lxml/lxml.etree.pyx":1688
* def __get__(self):
* _assertValidNode(self)
* return u'&%s;' % funicode(self._c_node.name) # <<<<<<<<<<<<<<
* def __repr__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->__pyx_base.__pyx_base._c_node->name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->__pyx_base.__pyx_base._c_node->name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1688; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s_3, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s_5, __pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1688; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1677
+ /* "src/lxml/lxml.etree.pyx":1686
* # FIXME: should this be None or '&[VALUE];' or the resolved
* # entity value ?
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1681
+/* "src/lxml/lxml.etree.pyx":1690
* return u'&%s;' % funicode(self._c_node.name)
*
* def __repr__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__repr__", 0);
- /* "src/lxml/lxml.etree.pyx":1682
+ /* "src/lxml/lxml.etree.pyx":1691
*
* def __repr__(self):
* return u"&%s;" % self.name # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_name_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_name_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_s_3, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_s_5, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1681
+ /* "src/lxml/lxml.etree.pyx":1690
* return u'&%s;' % funicode(self._c_node.name)
*
* def __repr__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1708
+/* "src/lxml/lxml.etree.pyx":1717
* cdef readonly unicode localname
* cdef readonly unicode namespace
* def __init__(self, text_or_uri_or_element, tag=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1708; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1717; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1708; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1717; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.QName.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("__init__", 0);
__Pyx_INCREF(__pyx_v_text_or_uri_or_element);
- /* "src/lxml/lxml.etree.pyx":1709
+ /* "src/lxml/lxml.etree.pyx":1718
* cdef readonly unicode namespace
* def __init__(self, text_or_uri_or_element, tag=None):
* if not _isString(text_or_uri_or_element): # <<<<<<<<<<<<<<
__pyx_t_1 = ((!(_isString(__pyx_v_text_or_uri_or_element) != 0)) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1710
+ /* "src/lxml/lxml.etree.pyx":1719
* def __init__(self, text_or_uri_or_element, tag=None):
* if not _isString(text_or_uri_or_element):
* if isinstance(text_or_uri_or_element, _Element): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1711
+ /* "src/lxml/lxml.etree.pyx":1720
* if not _isString(text_or_uri_or_element):
* if isinstance(text_or_uri_or_element, _Element):
* text_or_uri_or_element = (<_Element>text_or_uri_or_element).tag # <<<<<<<<<<<<<<
* if not _isString(text_or_uri_or_element):
* raise ValueError, (u"Invalid input tag of type %r" %
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_text_or_uri_or_element, __pyx_n_s_tag); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1711; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_text_or_uri_or_element, __pyx_n_s_tag); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1720; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_text_or_uri_or_element, __pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":1712
+ /* "src/lxml/lxml.etree.pyx":1721
* if isinstance(text_or_uri_or_element, _Element):
* text_or_uri_or_element = (<_Element>text_or_uri_or_element).tag
* if not _isString(text_or_uri_or_element): # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(_isString(__pyx_v_text_or_uri_or_element) != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1713
+ /* "src/lxml/lxml.etree.pyx":1722
* text_or_uri_or_element = (<_Element>text_or_uri_or_element).tag
* if not _isString(text_or_uri_or_element):
* raise ValueError, (u"Invalid input tag of type %r" % # <<<<<<<<<<<<<<
* type(text_or_uri_or_element))
* elif isinstance(text_or_uri_or_element, QName):
*/
- __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_Invalid_input_tag_of_type_r, ((PyObject *)Py_TYPE(__pyx_v_text_or_uri_or_element))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1713; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_Invalid_input_tag_of_type_r, ((PyObject *)Py_TYPE(__pyx_v_text_or_uri_or_element))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1722; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_t_3, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1713; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1722; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L4;
}
- /* "src/lxml/lxml.etree.pyx":1715
+ /* "src/lxml/lxml.etree.pyx":1724
* raise ValueError, (u"Invalid input tag of type %r" %
* type(text_or_uri_or_element))
* elif isinstance(text_or_uri_or_element, QName): # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1716
+ /* "src/lxml/lxml.etree.pyx":1725
* type(text_or_uri_or_element))
* elif isinstance(text_or_uri_or_element, QName):
* text_or_uri_or_element = (<QName>text_or_uri_or_element).text # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1718
+ /* "src/lxml/lxml.etree.pyx":1727
* text_or_uri_or_element = (<QName>text_or_uri_or_element).text
* else:
* text_or_uri_or_element = unicode(text_or_uri_or_element) # <<<<<<<<<<<<<<
*
* ns_utf, tag_utf = _getNsTag(text_or_uri_or_element)
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1718; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(__pyx_v_text_or_uri_or_element);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_text_or_uri_or_element);
__Pyx_GIVEREF(__pyx_v_text_or_uri_or_element);
- __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyUnicode_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1718; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyUnicode_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF_SET(__pyx_v_text_or_uri_or_element, __pyx_t_4);
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1720
+ /* "src/lxml/lxml.etree.pyx":1729
* text_or_uri_or_element = unicode(text_or_uri_or_element)
*
* ns_utf, tag_utf = _getNsTag(text_or_uri_or_element) # <<<<<<<<<<<<<<
* if tag is not None:
* # either ('ns', 'tag') or ('{ns}oldtag', 'newtag')
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_text_or_uri_or_element); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1720; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_text_or_uri_or_element); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
if (likely(__pyx_t_4 != Py_None)) {
PyObject* sequence = __pyx_t_4;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1720; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
__pyx_t_3 = PyTuple_GET_ITEM(sequence, 0);
__Pyx_INCREF(__pyx_t_3);
__Pyx_INCREF(__pyx_t_5);
#else
- __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1720; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_5 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1720; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
#endif
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
} else {
- __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1720; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_v_ns_utf = __pyx_t_3;
__pyx_t_3 = 0;
__pyx_v_tag_utf = __pyx_t_5;
__pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":1721
+ /* "src/lxml/lxml.etree.pyx":1730
*
* ns_utf, tag_utf = _getNsTag(text_or_uri_or_element)
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1723
+ /* "src/lxml/lxml.etree.pyx":1732
* if tag is not None:
* # either ('ns', 'tag') or ('{ns}oldtag', 'newtag')
* if ns_utf is None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1724
+ /* "src/lxml/lxml.etree.pyx":1733
* # either ('ns', 'tag') or ('{ns}oldtag', 'newtag')
* if ns_utf is None:
* ns_utf = tag_utf # case 1: namespace ended up as tag name # <<<<<<<<<<<<<<
}
__pyx_L7:;
- /* "src/lxml/lxml.etree.pyx":1725
+ /* "src/lxml/lxml.etree.pyx":1734
* if ns_utf is None:
* ns_utf = tag_utf # case 1: namespace ended up as tag name
* tag_utf = _utf8(tag) # <<<<<<<<<<<<<<
* _tagValidOrRaise(tag_utf)
* self.localname = (<bytes>tag_utf).decode('utf8')
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_v_tag); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1725; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_v_tag); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_tag_utf, __pyx_t_4);
__pyx_t_4 = 0;
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":1726
+ /* "src/lxml/lxml.etree.pyx":1735
* ns_utf = tag_utf # case 1: namespace ended up as tag name
* tag_utf = _utf8(tag)
* _tagValidOrRaise(tag_utf) # <<<<<<<<<<<<<<
* self.localname = (<bytes>tag_utf).decode('utf8')
* if ns_utf is None:
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree__tagValidOrRaise(__pyx_v_tag_utf); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1726; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__tagValidOrRaise(__pyx_v_tag_utf); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1727
+ /* "src/lxml/lxml.etree.pyx":1736
* tag_utf = _utf8(tag)
* _tagValidOrRaise(tag_utf)
* self.localname = (<bytes>tag_utf).decode('utf8') # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_tag_utf == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "decode");
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_4 = __Pyx_decode_bytes(((PyObject*)__pyx_v_tag_utf), 0, PY_SSIZE_T_MAX, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_decode_bytes(((PyObject*)__pyx_v_tag_utf), 0, PY_SSIZE_T_MAX, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GIVEREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_v_self->localname);
__Pyx_DECREF(__pyx_v_self->localname);
__pyx_v_self->localname = ((PyObject*)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1728
+ /* "src/lxml/lxml.etree.pyx":1737
* _tagValidOrRaise(tag_utf)
* self.localname = (<bytes>tag_utf).decode('utf8')
* if ns_utf is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1729
+ /* "src/lxml/lxml.etree.pyx":1738
* self.localname = (<bytes>tag_utf).decode('utf8')
* if ns_utf is None:
* self.namespace = None # <<<<<<<<<<<<<<
__Pyx_DECREF(__pyx_v_self->namespace);
__pyx_v_self->namespace = ((PyObject*)Py_None);
- /* "src/lxml/lxml.etree.pyx":1730
+ /* "src/lxml/lxml.etree.pyx":1739
* if ns_utf is None:
* self.namespace = None
* self.text = self.localname # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1732
+ /* "src/lxml/lxml.etree.pyx":1741
* self.text = self.localname
* else:
* self.namespace = (<bytes>ns_utf).decode('utf8') # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_ns_utf == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "decode");
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1732; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_4 = __Pyx_decode_bytes(((PyObject*)__pyx_v_ns_utf), 0, PY_SSIZE_T_MAX, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1732; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_decode_bytes(((PyObject*)__pyx_v_ns_utf), 0, PY_SSIZE_T_MAX, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1732; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyUnicode_CheckExact(__pyx_t_4))||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "unicode", Py_TYPE(__pyx_t_4)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GIVEREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_v_self->namespace);
__Pyx_DECREF(__pyx_v_self->namespace);
__pyx_v_self->namespace = ((PyObject*)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1733
+ /* "src/lxml/lxml.etree.pyx":1742
* else:
* self.namespace = (<bytes>ns_utf).decode('utf8')
* self.text = u"{%s}%s" % (self.namespace, self.localname) # <<<<<<<<<<<<<<
* def __str__(self):
* return self.text
*/
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(__pyx_v_self->namespace);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->namespace);
__Pyx_INCREF(__pyx_v_self->localname);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_self->localname);
__Pyx_GIVEREF(__pyx_v_self->localname);
- __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_s_s_2, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_s_s_2, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_GIVEREF(__pyx_t_5);
}
__pyx_L8:;
- /* "src/lxml/lxml.etree.pyx":1708
+ /* "src/lxml/lxml.etree.pyx":1717
* cdef readonly unicode localname
* cdef readonly unicode namespace
* def __init__(self, text_or_uri_or_element, tag=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1734
+/* "src/lxml/lxml.etree.pyx":1743
* self.namespace = (<bytes>ns_utf).decode('utf8')
* self.text = u"{%s}%s" % (self.namespace, self.localname)
* def __str__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__str__", 0);
- /* "src/lxml/lxml.etree.pyx":1735
+ /* "src/lxml/lxml.etree.pyx":1744
* self.text = u"{%s}%s" % (self.namespace, self.localname)
* def __str__(self):
* return self.text # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_self->text;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1734
+ /* "src/lxml/lxml.etree.pyx":1743
* self.namespace = (<bytes>ns_utf).decode('utf8')
* self.text = u"{%s}%s" % (self.namespace, self.localname)
* def __str__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1736
+/* "src/lxml/lxml.etree.pyx":1745
* def __str__(self):
* return self.text
* def __hash__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__hash__", 0);
- /* "src/lxml/lxml.etree.pyx":1737
+ /* "src/lxml/lxml.etree.pyx":1746
* return self.text
* def __hash__(self):
* return hash(self.text) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = __pyx_v_self->text;
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = PyObject_Hash(__pyx_t_1); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_Hash(__pyx_t_1); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_2;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1736
+ /* "src/lxml/lxml.etree.pyx":1745
* def __str__(self):
* return self.text
* def __hash__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1738
+/* "src/lxml/lxml.etree.pyx":1747
* def __hash__(self):
* return hash(self.text)
* def __richcmp__(one, other, int op): # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_v_one);
__Pyx_INCREF(__pyx_v_other);
- /* "src/lxml/lxml.etree.pyx":1739
+ /* "src/lxml/lxml.etree.pyx":1748
* return hash(self.text)
* def __richcmp__(one, other, int op):
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_3);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":1740
+ /* "src/lxml/lxml.etree.pyx":1749
* def __richcmp__(one, other, int op):
* try:
* if type(one) is QName: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1741
+ /* "src/lxml/lxml.etree.pyx":1750
* try:
* if type(one) is QName:
* one = (<QName>one).text # <<<<<<<<<<<<<<
goto __pyx_L11;
}
- /* "src/lxml/lxml.etree.pyx":1742
+ /* "src/lxml/lxml.etree.pyx":1751
* if type(one) is QName:
* one = (<QName>one).text
* elif not isinstance(one, unicode): # <<<<<<<<<<<<<<
__pyx_t_4 = ((!(__pyx_t_5 != 0)) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":1743
+ /* "src/lxml/lxml.etree.pyx":1752
* one = (<QName>one).text
* elif not isinstance(one, unicode):
* one = unicode(one) # <<<<<<<<<<<<<<
* if type(other) is QName:
* other = (<QName>other).text
*/
- __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1743; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1752; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_INCREF(__pyx_v_one);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_v_one);
__Pyx_GIVEREF(__pyx_v_one);
- __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyUnicode_Type))), __pyx_t_6, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1743; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyUnicode_Type))), __pyx_t_6, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1752; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_DECREF_SET(__pyx_v_one, __pyx_t_7);
}
__pyx_L11:;
- /* "src/lxml/lxml.etree.pyx":1744
+ /* "src/lxml/lxml.etree.pyx":1753
* elif not isinstance(one, unicode):
* one = unicode(one)
* if type(other) is QName: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1745
+ /* "src/lxml/lxml.etree.pyx":1754
* one = unicode(one)
* if type(other) is QName:
* other = (<QName>other).text # <<<<<<<<<<<<<<
goto __pyx_L12;
}
- /* "src/lxml/lxml.etree.pyx":1746
+ /* "src/lxml/lxml.etree.pyx":1755
* if type(other) is QName:
* other = (<QName>other).text
* elif not isinstance(other, unicode): # <<<<<<<<<<<<<<
__pyx_t_4 = ((!(__pyx_t_5 != 0)) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":1747
+ /* "src/lxml/lxml.etree.pyx":1756
* other = (<QName>other).text
* elif not isinstance(other, unicode):
* other = unicode(other) # <<<<<<<<<<<<<<
* except (ValueError, UnicodeDecodeError):
* return NotImplemented
*/
- __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1747; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1756; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_INCREF(__pyx_v_other);
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_v_other);
__Pyx_GIVEREF(__pyx_v_other);
- __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyUnicode_Type))), __pyx_t_7, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1747; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyUnicode_Type))), __pyx_t_7, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1756; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF_SET(__pyx_v_other, __pyx_t_6);
__Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":1748
+ /* "src/lxml/lxml.etree.pyx":1757
* elif not isinstance(other, unicode):
* other = unicode(other)
* except (ValueError, UnicodeDecodeError): # <<<<<<<<<<<<<<
__pyx_t_8 = PyErr_ExceptionMatches(__pyx_builtin_ValueError) || PyErr_ExceptionMatches(__pyx_builtin_UnicodeDecodeError);
if (__pyx_t_8) {
__Pyx_AddTraceback("lxml.etree.QName.__richcmp__", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_7, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1748; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_7, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1757; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_7);
__Pyx_GOTREF(__pyx_t_9);
- /* "src/lxml/lxml.etree.pyx":1749
+ /* "src/lxml/lxml.etree.pyx":1758
* other = unicode(other)
* except (ValueError, UnicodeDecodeError):
* return NotImplemented # <<<<<<<<<<<<<<
__pyx_L10_try_end:;
}
- /* "src/lxml/lxml.etree.pyx":1750
+ /* "src/lxml/lxml.etree.pyx":1759
* except (ValueError, UnicodeDecodeError):
* return NotImplemented
* return python.PyObject_RichCompare(one, other, op) # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_9 = PyObject_RichCompare(__pyx_v_one, __pyx_v_other, __pyx_v_op); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1750; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyObject_RichCompare(__pyx_v_one, __pyx_v_other, __pyx_v_op); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1759; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__pyx_r = __pyx_t_9;
__pyx_t_9 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1738
+ /* "src/lxml/lxml.etree.pyx":1747
* def __hash__(self):
* return hash(self.text)
* def __richcmp__(one, other, int op): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1705
+/* "src/lxml/lxml.etree.pyx":1714
* their text content.
* """
* cdef readonly unicode text # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1706
+/* "src/lxml/lxml.etree.pyx":1715
* """
* cdef readonly unicode text
* cdef readonly unicode localname # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1707
+/* "src/lxml/lxml.etree.pyx":1716
* cdef readonly unicode text
* cdef readonly unicode localname
* cdef readonly unicode namespace # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1763
+/* "src/lxml/lxml.etree.pyx":1772
*
* @cython.final
* cdef int _assertHasRoot(self) except -1: # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_assertHasRoot", 0);
- /* "src/lxml/lxml.etree.pyx":1769
+ /* "src/lxml/lxml.etree.pyx":1778
* the caller program.
* """
* assert self._context_node is not None, \ # <<<<<<<<<<<<<<
__pyx_t_1 = (((PyObject *)__pyx_v_self->_context_node) != Py_None);
if (unlikely(!(__pyx_t_1 != 0))) {
PyErr_SetObject(PyExc_AssertionError, __pyx_kp_u_ElementTree_not_initialized_miss);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/lxml.etree.pyx":1771
+ /* "src/lxml/lxml.etree.pyx":1780
* assert self._context_node is not None, \
* u"ElementTree not initialized, missing root"
* return 0 # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1763
+ /* "src/lxml/lxml.etree.pyx":1772
*
* @cython.final
* cdef int _assertHasRoot(self) except -1: # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1773
+/* "src/lxml/lxml.etree.pyx":1782
* return 0
*
* def parse(self, source, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "parse") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1773; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "parse") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("parse", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1773; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("parse", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ElementTree.parse", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1773; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1782; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_12_ElementTree_parse(((struct LxmlElementTree *)__pyx_v_self), __pyx_v_source, __pyx_v_parser, __pyx_v_base_url);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("parse", 0);
- /* "src/lxml/lxml.etree.pyx":1778
+ /* "src/lxml/lxml.etree.pyx":1787
* Updates self with the content of source and returns its root
* """
* cdef _Document doc = None # <<<<<<<<<<<<<<
__Pyx_INCREF(Py_None);
__pyx_v_doc = ((struct LxmlDocument *)Py_None);
- /* "src/lxml/lxml.etree.pyx":1779
+ /* "src/lxml/lxml.etree.pyx":1788
* """
* cdef _Document doc = None
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_3);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":1780
+ /* "src/lxml/lxml.etree.pyx":1789
* cdef _Document doc = None
* try:
* doc = _parseDocument(source, parser, base_url) # <<<<<<<<<<<<<<
* self._context_node = doc.getroot()
* if self._context_node is None:
*/
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocument(__pyx_v_source, __pyx_v_parser, __pyx_v_base_url)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1780; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocument(__pyx_v_source, __pyx_v_parser, __pyx_v_base_url)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1789; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_doc, ((struct LxmlDocument *)__pyx_t_4));
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1781
+ /* "src/lxml/lxml.etree.pyx":1790
* try:
* doc = _parseDocument(source, parser, base_url)
* self._context_node = doc.getroot() # <<<<<<<<<<<<<<
* if self._context_node is None:
* self._doc = doc
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1781; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1790; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1781; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1790; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GIVEREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_v_self->_context_node);
__Pyx_DECREF(((PyObject *)__pyx_v_self->_context_node));
__pyx_v_self->_context_node = ((struct LxmlElement *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1782
+ /* "src/lxml/lxml.etree.pyx":1791
* doc = _parseDocument(source, parser, base_url)
* self._context_node = doc.getroot()
* if self._context_node is None: # <<<<<<<<<<<<<<
__pyx_t_6 = (__pyx_t_5 != 0);
if (__pyx_t_6) {
- /* "src/lxml/lxml.etree.pyx":1783
+ /* "src/lxml/lxml.etree.pyx":1792
* self._context_node = doc.getroot()
* if self._context_node is None:
* self._doc = doc # <<<<<<<<<<<<<<
__pyx_L3_error:;
__Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1784
+ /* "src/lxml/lxml.etree.pyx":1793
* if self._context_node is None:
* self._doc = doc
* except _TargetParserResult as result_container: # <<<<<<<<<<<<<<
* # raises a TypeError if we don't get an _Element
* self._context_node = result_container.result
*/
- __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1784; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1793; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_7 = PyErr_ExceptionMatches(__pyx_t_4);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_7) {
__Pyx_AddTraceback("lxml.etree._ElementTree.parse", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1784; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1793; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_t_8);
__Pyx_GOTREF(__pyx_t_9);
__Pyx_INCREF(__pyx_t_8);
__pyx_v_result_container = __pyx_t_8;
- /* "src/lxml/lxml.etree.pyx":1786
+ /* "src/lxml/lxml.etree.pyx":1795
* except _TargetParserResult as result_container:
* # raises a TypeError if we don't get an _Element
* self._context_node = result_container.result # <<<<<<<<<<<<<<
* return self._context_node
*
*/
- __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1786; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1795; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_10);
- if (!(likely(((__pyx_t_10) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_10, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1786; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ if (!(likely(((__pyx_t_10) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_10, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1795; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GIVEREF(__pyx_t_10);
__Pyx_GOTREF(__pyx_v_self->_context_node);
__Pyx_DECREF(((PyObject *)__pyx_v_self->_context_node));
__pyx_L10_try_end:;
}
- /* "src/lxml/lxml.etree.pyx":1787
+ /* "src/lxml/lxml.etree.pyx":1796
* # raises a TypeError if we don't get an _Element
* self._context_node = result_container.result
* return self._context_node # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self->_context_node);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1773
+ /* "src/lxml/lxml.etree.pyx":1782
* return 0
*
* def parse(self, source, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1789
+/* "src/lxml/lxml.etree.pyx":1798
* return self._context_node
*
* def _setroot(self, _Element root not None): # <<<<<<<<<<<<<<
PyObject *__pyx_r = 0;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("_setroot (wrapper)", 0);
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_root), __pyx_ptype_4lxml_5etree__Element, 0, "root", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_root), __pyx_ptype_4lxml_5etree__Element, 0, "root", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1798; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_12_ElementTree_2_setroot(((struct LxmlElementTree *)__pyx_v_self), ((struct LxmlElement *)__pyx_v_root));
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_setroot", 0);
- /* "src/lxml/lxml.etree.pyx":1794
+ /* "src/lxml/lxml.etree.pyx":1803
* Relocate the ElementTree to a new root node.
* """
* _assertValidNode(root) # <<<<<<<<<<<<<<
* if root._c_node.type != tree.XML_ELEMENT_NODE:
* raise TypeError, u"Only elements can be the root of an ElementTree"
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1803; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1795
+ /* "src/lxml/lxml.etree.pyx":1804
* """
* _assertValidNode(root)
* if root._c_node.type != tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_root->_c_node->type != XML_ELEMENT_NODE) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1796
+ /* "src/lxml/lxml.etree.pyx":1805
* _assertValidNode(root)
* if root._c_node.type != tree.XML_ELEMENT_NODE:
* raise TypeError, u"Only elements can be the root of an ElementTree" # <<<<<<<<<<<<<<
* self._doc = None
*/
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_kp_u_Only_elements_can_be_the_root_of, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1796; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1805; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1797
+ /* "src/lxml/lxml.etree.pyx":1806
* if root._c_node.type != tree.XML_ELEMENT_NODE:
* raise TypeError, u"Only elements can be the root of an ElementTree"
* self._context_node = root # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_context_node));
__pyx_v_self->_context_node = __pyx_v_root;
- /* "src/lxml/lxml.etree.pyx":1798
+ /* "src/lxml/lxml.etree.pyx":1807
* raise TypeError, u"Only elements can be the root of an ElementTree"
* self._context_node = root
* self._doc = None # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_doc));
__pyx_v_self->_doc = ((struct LxmlDocument *)Py_None);
- /* "src/lxml/lxml.etree.pyx":1789
+ /* "src/lxml/lxml.etree.pyx":1798
* return self._context_node
*
* def _setroot(self, _Element root not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1800
+/* "src/lxml/lxml.etree.pyx":1809
* self._doc = None
*
* def getroot(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("getroot", 0);
- /* "src/lxml/lxml.etree.pyx":1805
+ /* "src/lxml/lxml.etree.pyx":1814
* Gets the root element for this tree.
* """
* return self._context_node # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self->_context_node);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1800
+ /* "src/lxml/lxml.etree.pyx":1809
* self._doc = None
*
* def getroot(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1807
+/* "src/lxml/lxml.etree.pyx":1816
* return self._context_node
*
* def __copy__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__copy__", 0);
- /* "src/lxml/lxml.etree.pyx":1808
+ /* "src/lxml/lxml.etree.pyx":1817
*
* def __copy__(self):
* return _elementTreeFactory(self._doc, self._context_node) # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_t_1);
__pyx_t_2 = ((PyObject *)__pyx_v_self->_context_node);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_1), ((struct LxmlElement *)__pyx_t_2))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1808; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_1), ((struct LxmlElement *)__pyx_t_2))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1817; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1807
+ /* "src/lxml/lxml.etree.pyx":1816
* return self._context_node
*
* def __copy__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1810
+/* "src/lxml/lxml.etree.pyx":1819
* return _elementTreeFactory(self._doc, self._context_node)
*
* def __deepcopy__(self, memo): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__deepcopy__", 0);
- /* "src/lxml/lxml.etree.pyx":1814
+ /* "src/lxml/lxml.etree.pyx":1823
* cdef _Document doc
* cdef xmlDoc* c_doc
* if self._context_node is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1815
+ /* "src/lxml/lxml.etree.pyx":1824
* cdef xmlDoc* c_doc
* if self._context_node is not None:
* root = self._context_node.__copy__() # <<<<<<<<<<<<<<
* assert root is not None
* _assertValidNode(root)
*/
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->_context_node), __pyx_n_s_copy_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self->_context_node), __pyx_n_s_copy_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_4))) {
}
}
if (__pyx_t_5) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_root = ((struct LxmlElement *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":1816
+ /* "src/lxml/lxml.etree.pyx":1825
* if self._context_node is not None:
* root = self._context_node.__copy__()
* assert root is not None # <<<<<<<<<<<<<<
__pyx_t_2 = (((PyObject *)__pyx_v_root) != Py_None);
if (unlikely(!(__pyx_t_2 != 0))) {
PyErr_SetNone(PyExc_AssertionError);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1816; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1825; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/lxml.etree.pyx":1817
+ /* "src/lxml/lxml.etree.pyx":1826
* root = self._context_node.__copy__()
* assert root is not None
* _assertValidNode(root) # <<<<<<<<<<<<<<
* _copyNonElementSiblings(self._context_node._c_node, root._c_node)
* doc = root._doc
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1817; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1826; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1818
+ /* "src/lxml/lxml.etree.pyx":1827
* assert root is not None
* _assertValidNode(root)
* _copyNonElementSiblings(self._context_node._c_node, root._c_node) # <<<<<<<<<<<<<<
* doc = root._doc
* c_doc = self._context_node._doc._c_doc
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree__copyNonElementSiblings(__pyx_v_self->_context_node->_c_node, __pyx_v_root->_c_node); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__copyNonElementSiblings(__pyx_v_self->_context_node->_c_node, __pyx_v_root->_c_node); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1827; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1819
+ /* "src/lxml/lxml.etree.pyx":1828
* _assertValidNode(root)
* _copyNonElementSiblings(self._context_node._c_node, root._c_node)
* doc = root._doc # <<<<<<<<<<<<<<
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":1820
+ /* "src/lxml/lxml.etree.pyx":1829
* _copyNonElementSiblings(self._context_node._c_node, root._c_node)
* doc = root._doc
* c_doc = self._context_node._doc._c_doc # <<<<<<<<<<<<<<
__pyx_t_7 = __pyx_v_self->_context_node->_doc->_c_doc;
__pyx_v_c_doc = __pyx_t_7;
- /* "src/lxml/lxml.etree.pyx":1821
+ /* "src/lxml/lxml.etree.pyx":1830
* doc = root._doc
* c_doc = self._context_node._doc._c_doc
* if c_doc.intSubset is not NULL and doc._c_doc.intSubset is NULL: # <<<<<<<<<<<<<<
__pyx_L5_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1822
+ /* "src/lxml/lxml.etree.pyx":1831
* c_doc = self._context_node._doc._c_doc
* if c_doc.intSubset is not NULL and doc._c_doc.intSubset is NULL:
* doc._c_doc.intSubset = _copyDtd(c_doc.intSubset) # <<<<<<<<<<<<<<
* if c_doc.extSubset is not NULL and not doc._c_doc.extSubset is NULL:
* doc._c_doc.extSubset = _copyDtd(c_doc.extSubset)
*/
- __pyx_t_8 = __pyx_f_4lxml_5etree__copyDtd(__pyx_v_c_doc->intSubset); if (unlikely(__pyx_t_8 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __pyx_f_4lxml_5etree__copyDtd(__pyx_v_c_doc->intSubset); if (unlikely(__pyx_t_8 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1831; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_doc->_c_doc->intSubset = __pyx_t_8;
goto __pyx_L4;
}
__pyx_L4:;
- /* "src/lxml/lxml.etree.pyx":1823
+ /* "src/lxml/lxml.etree.pyx":1832
* if c_doc.intSubset is not NULL and doc._c_doc.intSubset is NULL:
* doc._c_doc.intSubset = _copyDtd(c_doc.intSubset)
* if c_doc.extSubset is not NULL and not doc._c_doc.extSubset is NULL: # <<<<<<<<<<<<<<
__pyx_L8_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1824
+ /* "src/lxml/lxml.etree.pyx":1833
* doc._c_doc.intSubset = _copyDtd(c_doc.intSubset)
* if c_doc.extSubset is not NULL and not doc._c_doc.extSubset is NULL:
* doc._c_doc.extSubset = _copyDtd(c_doc.extSubset) # <<<<<<<<<<<<<<
* return _elementTreeFactory(None, root)
* elif self._doc is not None:
*/
- __pyx_t_8 = __pyx_f_4lxml_5etree__copyDtd(__pyx_v_c_doc->extSubset); if (unlikely(__pyx_t_8 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1824; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __pyx_f_4lxml_5etree__copyDtd(__pyx_v_c_doc->extSubset); if (unlikely(__pyx_t_8 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1833; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_doc->_c_doc->extSubset = __pyx_t_8;
goto __pyx_L7;
}
__pyx_L7:;
- /* "src/lxml/lxml.etree.pyx":1825
+ /* "src/lxml/lxml.etree.pyx":1834
* if c_doc.extSubset is not NULL and not doc._c_doc.extSubset is NULL:
* doc._c_doc.extSubset = _copyDtd(c_doc.extSubset)
* return _elementTreeFactory(None, root) # <<<<<<<<<<<<<<
* _assertValidDoc(self._doc)
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)Py_None), __pyx_v_root)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1825; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)Py_None), __pyx_v_root)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1834; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1826
+ /* "src/lxml/lxml.etree.pyx":1835
* doc._c_doc.extSubset = _copyDtd(c_doc.extSubset)
* return _elementTreeFactory(None, root)
* elif self._doc is not None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1827
+ /* "src/lxml/lxml.etree.pyx":1836
* return _elementTreeFactory(None, root)
* elif self._doc is not None:
* _assertValidDoc(self._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_3 = ((PyObject *)__pyx_v_self->_doc);
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_6 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_3)); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1827; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_3)); if (unlikely(__pyx_t_6 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":1828
+ /* "src/lxml/lxml.etree.pyx":1837
* elif self._doc is not None:
* _assertValidDoc(self._doc)
* c_doc = tree.xmlCopyDoc(self._doc._c_doc, 1) # <<<<<<<<<<<<<<
*/
__pyx_v_c_doc = xmlCopyDoc(__pyx_v_self->_doc->_c_doc, 1);
- /* "src/lxml/lxml.etree.pyx":1829
+ /* "src/lxml/lxml.etree.pyx":1838
* _assertValidDoc(self._doc)
* c_doc = tree.xmlCopyDoc(self._doc._c_doc, 1)
* if c_doc is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_doc == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1830
+ /* "src/lxml/lxml.etree.pyx":1839
* c_doc = tree.xmlCopyDoc(self._doc._c_doc, 1)
* if c_doc is NULL:
* raise MemoryError() # <<<<<<<<<<<<<<
* doc = _documentFactory(c_doc, self._doc._parser)
* return _elementTreeFactory(doc, None)
*/
- PyErr_NoMemory(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1830; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyErr_NoMemory(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1831
+ /* "src/lxml/lxml.etree.pyx":1840
* if c_doc is NULL:
* raise MemoryError()
* doc = _documentFactory(c_doc, self._doc._parser) # <<<<<<<<<<<<<<
*/
__pyx_t_3 = ((PyObject *)__pyx_v_self->_doc->_parser);
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_3))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1831; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_3))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1832
+ /* "src/lxml/lxml.etree.pyx":1841
* raise MemoryError()
* doc = _documentFactory(c_doc, self._doc._parser)
* return _elementTreeFactory(doc, None) # <<<<<<<<<<<<<<
* # so what ...
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_doc, ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1832; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_doc, ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1841; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1835
+ /* "src/lxml/lxml.etree.pyx":1844
* else:
* # so what ...
* return self # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1810
+ /* "src/lxml/lxml.etree.pyx":1819
* return _elementTreeFactory(self._doc, self._context_node)
*
* def __deepcopy__(self, memo): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1844
+/* "src/lxml/lxml.etree.pyx":1853
* not for trees that were built manually.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1845
+ /* "src/lxml/lxml.etree.pyx":1854
* """
* def __get__(self):
* self._assertHasRoot() # <<<<<<<<<<<<<<
* return DocInfo(self._context_node._doc)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1845; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1854; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1846
+ /* "src/lxml/lxml.etree.pyx":1855
* def __get__(self):
* self._assertHasRoot()
* return DocInfo(self._context_node._doc) # <<<<<<<<<<<<<<
* # not in ElementTree, read-only
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(((PyObject *)__pyx_v_self->_context_node->_doc));
PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self->_context_node->_doc));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self->_context_node->_doc));
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_DocInfo)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_DocInfo)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1844
+ /* "src/lxml/lxml.etree.pyx":1853
* not for trees that were built manually.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1852
+/* "src/lxml/lxml.etree.pyx":1861
* u"""The parser that was used to parse the document in this ElementTree.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_t_3;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":1853
+ /* "src/lxml/lxml.etree.pyx":1862
* """
* def __get__(self):
* if self._context_node is not None and \ # <<<<<<<<<<<<<<
goto __pyx_L4_bool_binop_done;
}
- /* "src/lxml/lxml.etree.pyx":1854
+ /* "src/lxml/lxml.etree.pyx":1863
* def __get__(self):
* if self._context_node is not None and \
* self._context_node._doc is not None: # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":1855
+ /* "src/lxml/lxml.etree.pyx":1864
* if self._context_node is not None and \
* self._context_node._doc is not None:
* return self._context_node._doc._parser # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1856
+ /* "src/lxml/lxml.etree.pyx":1865
* self._context_node._doc is not None:
* return self._context_node._doc._parser
* if self._doc is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1857
+ /* "src/lxml/lxml.etree.pyx":1866
* return self._context_node._doc._parser
* if self._doc is not None:
* return self._doc._parser # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1858
+ /* "src/lxml/lxml.etree.pyx":1867
* if self._doc is not None:
* return self._doc._parser
* return None # <<<<<<<<<<<<<<
__pyx_r = Py_None;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1852
+ /* "src/lxml/lxml.etree.pyx":1861
* u"""The parser that was used to parse the document in this ElementTree.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1860
+/* "src/lxml/lxml.etree.pyx":1869
* return None
*
* def write(self, file, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
values[1] = ((PyObject *)Py_None);
values[2] = ((PyObject *)__pyx_n_u_xml);
- /* "src/lxml/lxml.etree.pyx":1861
+ /* "src/lxml/lxml.etree.pyx":1870
*
* def write(self, file, *, encoding=None, method=u"xml",
* pretty_print=False, xml_declaration=None, with_tail=True, # <<<<<<<<<<<<<<
values[4] = ((PyObject *)Py_None);
values[5] = ((PyObject *)Py_True);
- /* "src/lxml/lxml.etree.pyx":1862
+ /* "src/lxml/lxml.etree.pyx":1871
* def write(self, file, *, encoding=None, method=u"xml",
* pretty_print=False, xml_declaration=None, with_tail=True,
* standalone=None, docstring=None, compression=0, # <<<<<<<<<<<<<<
values[7] = ((PyObject *)Py_None);
values[8] = ((PyObject *)__pyx_int_0);
- /* "src/lxml/lxml.etree.pyx":1863
+ /* "src/lxml/lxml.etree.pyx":1872
* pretty_print=False, xml_declaration=None, with_tail=True,
* standalone=None, docstring=None, compression=0,
* exclusive=False, with_comments=True, inclusive_ns_prefixes=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "write") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1860; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "write") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1869; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("write", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1860; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("write", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1869; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ElementTree.write", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__pyx_L4_argument_unpacking_done:;
__pyx_r = __pyx_pf_4lxml_5etree_12_ElementTree_10write(((struct LxmlElementTree *)__pyx_v_self), __pyx_v_file, __pyx_v_encoding, __pyx_v_method, __pyx_v_pretty_print, __pyx_v_xml_declaration, __pyx_v_with_tail, __pyx_v_standalone, __pyx_v_docstring, __pyx_v_compression, __pyx_v_exclusive, __pyx_v_with_comments, __pyx_v_inclusive_ns_prefixes);
- /* "src/lxml/lxml.etree.pyx":1860
+ /* "src/lxml/lxml.etree.pyx":1869
* return None
*
* def write(self, file, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_v_encoding);
__Pyx_INCREF(__pyx_v_compression);
- /* "src/lxml/lxml.etree.pyx":1899
+ /* "src/lxml/lxml.etree.pyx":1908
* cdef int is_standalone
*
* self._assertHasRoot() # <<<<<<<<<<<<<<
* _assertValidNode(self._context_node)
* if compression is None or compression < 0:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1908; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1900
+ /* "src/lxml/lxml.etree.pyx":1909
*
* self._assertHasRoot()
* _assertValidNode(self._context_node) # <<<<<<<<<<<<<<
*/
__pyx_t_2 = ((PyObject *)__pyx_v_self->_context_node);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_2)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_2)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":1901
+ /* "src/lxml/lxml.etree.pyx":1910
* self._assertHasRoot()
* _assertValidNode(self._context_node)
* if compression is None or compression < 0: # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_t_5;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_2 = PyObject_RichCompare(__pyx_v_compression, __pyx_int_0, Py_LT); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_RichCompare(__pyx_v_compression, __pyx_int_0, Py_LT); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_3 = __pyx_t_5;
__pyx_L4_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1902
+ /* "src/lxml/lxml.etree.pyx":1911
* _assertValidNode(self._context_node)
* if compression is None or compression < 0:
* compression = 0 # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1905
+ /* "src/lxml/lxml.etree.pyx":1914
*
* # C14N serialisation
* if method == 'c14n': # <<<<<<<<<<<<<<
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N")
*/
- __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_method, __pyx_n_s_c14n, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1905; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_method, __pyx_n_s_c14n, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1906
+ /* "src/lxml/lxml.etree.pyx":1915
* # C14N serialisation
* if method == 'c14n':
* if encoding is not None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_3 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1907
+ /* "src/lxml/lxml.etree.pyx":1916
* if method == 'c14n':
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N") # <<<<<<<<<<<<<<
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N")
*/
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__27, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__28, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1916; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1916; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1908
+ /* "src/lxml/lxml.etree.pyx":1917
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N")
* if xml_declaration: # <<<<<<<<<<<<<<
* raise ValueError("Cannot enable XML declaration in C14N")
*
*/
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1908; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1909
+ /* "src/lxml/lxml.etree.pyx":1918
* raise ValueError("Cannot specify encoding with C14N")
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N") # <<<<<<<<<<<<<<
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments,
*/
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__28, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__29, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1911
+ /* "src/lxml/lxml.etree.pyx":1920
* raise ValueError("Cannot enable XML declaration in C14N")
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments, # <<<<<<<<<<<<<<
*/
__pyx_t_2 = ((PyObject *)__pyx_v_self->_context_node);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_exclusive); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1911; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_with_comments); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1911; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_exclusive); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1920; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_with_comments); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1920; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1912
+ /* "src/lxml/lxml.etree.pyx":1921
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments,
* compression, inclusive_ns_prefixes) # <<<<<<<<<<<<<<
* return
* if not with_comments:
*/
- __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1912; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1921; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1911
+ /* "src/lxml/lxml.etree.pyx":1920
* raise ValueError("Cannot enable XML declaration in C14N")
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments, # <<<<<<<<<<<<<<
* compression, inclusive_ns_prefixes)
* return
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree__tofilelikeC14N(__pyx_v_file, ((struct LxmlElement *)__pyx_t_2), __pyx_t_5, __pyx_t_3, __pyx_t_1, __pyx_v_inclusive_ns_prefixes); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1911; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__tofilelikeC14N(__pyx_v_file, ((struct LxmlElement *)__pyx_t_2), __pyx_t_5, __pyx_t_3, __pyx_t_1, __pyx_v_inclusive_ns_prefixes); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1920; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":1913
+ /* "src/lxml/lxml.etree.pyx":1922
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments,
* compression, inclusive_ns_prefixes)
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":1914
+ /* "src/lxml/lxml.etree.pyx":1923
* compression, inclusive_ns_prefixes)
* return
* if not with_comments: # <<<<<<<<<<<<<<
* raise ValueError("Can only discard comments in C14N serialisation")
* # suppress decl. in default case (purely for ElementTree compatibility)
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_with_comments); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_with_comments); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_5 = ((!__pyx_t_3) != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1915
+ /* "src/lxml/lxml.etree.pyx":1924
* return
* if not with_comments:
* raise ValueError("Can only discard comments in C14N serialisation") # <<<<<<<<<<<<<<
* # suppress decl. in default case (purely for ElementTree compatibility)
* if xml_declaration is not None:
*/
- __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__29, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__30, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_Raise(__pyx_t_6, 0, 0, 0);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1917
+ /* "src/lxml/lxml.etree.pyx":1926
* raise ValueError("Can only discard comments in C14N serialisation")
* # suppress decl. in default case (purely for ElementTree compatibility)
* if xml_declaration is not None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_5 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1918
+ /* "src/lxml/lxml.etree.pyx":1927
* # suppress decl. in default case (purely for ElementTree compatibility)
* if xml_declaration is not None:
* write_declaration = xml_declaration # <<<<<<<<<<<<<<
* if encoding is None:
* encoding = u'ASCII'
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_write_declaration = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":1919
+ /* "src/lxml/lxml.etree.pyx":1928
* if xml_declaration is not None:
* write_declaration = xml_declaration
* if encoding is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_3 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1920
+ /* "src/lxml/lxml.etree.pyx":1929
* write_declaration = xml_declaration
* if encoding is None:
* encoding = u'ASCII' # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1922
+ /* "src/lxml/lxml.etree.pyx":1931
* encoding = u'ASCII'
* else:
* encoding = encoding.upper() # <<<<<<<<<<<<<<
* elif encoding is None:
* encoding = u'ASCII'
*/
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1922; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1931; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_7 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
}
}
if (__pyx_t_7) {
- __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_7); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1922; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_7); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1931; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
} else {
- __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1922; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1931; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
goto __pyx_L10;
}
- /* "src/lxml/lxml.etree.pyx":1923
+ /* "src/lxml/lxml.etree.pyx":1932
* else:
* encoding = encoding.upper()
* elif encoding is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_5 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1924
+ /* "src/lxml/lxml.etree.pyx":1933
* encoding = encoding.upper()
* elif encoding is None:
* encoding = u'ASCII' # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_n_u_ASCII);
__Pyx_DECREF_SET(__pyx_v_encoding, __pyx_n_u_ASCII);
- /* "src/lxml/lxml.etree.pyx":1925
+ /* "src/lxml/lxml.etree.pyx":1934
* elif encoding is None:
* encoding = u'ASCII'
* write_declaration = 0 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1927
+ /* "src/lxml/lxml.etree.pyx":1936
* write_declaration = 0
* else:
* encoding = encoding.upper() # <<<<<<<<<<<<<<
* write_declaration = encoding not in \
* (u'US-ASCII', u'ASCII', u'UTF8', u'UTF-8')
*/
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1936; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_7 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
}
}
if (__pyx_t_7) {
- __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_7); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_7); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1936; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
} else {
- __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1936; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF_SET(__pyx_v_encoding, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":1928
+ /* "src/lxml/lxml.etree.pyx":1937
* else:
* encoding = encoding.upper()
* write_declaration = encoding not in \ # <<<<<<<<<<<<<<
*/
__Pyx_INCREF(__pyx_v_encoding);
__pyx_t_6 = __pyx_v_encoding;
- __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_kp_u_US_ASCII, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_kp_u_US_ASCII, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_5) {
} else {
__pyx_t_3 = __pyx_t_5;
goto __pyx_L12_bool_binop_done;
}
- __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_n_u_ASCII, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_n_u_ASCII, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_5) {
} else {
__pyx_t_3 = __pyx_t_5;
goto __pyx_L12_bool_binop_done;
}
- __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_n_u_UTF8, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_n_u_UTF8, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_5) {
} else {
__pyx_t_3 = __pyx_t_5;
goto __pyx_L12_bool_binop_done;
}
- __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_kp_u_UTF_8, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyUnicode_Equals(__pyx_t_6, __pyx_kp_u_UTF_8, Py_NE)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = __pyx_t_5;
__pyx_L12_bool_binop_done:;
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
__pyx_L10:;
- /* "src/lxml/lxml.etree.pyx":1930
+ /* "src/lxml/lxml.etree.pyx":1939
* write_declaration = encoding not in \
* (u'US-ASCII', u'ASCII', u'UTF8', u'UTF-8')
* if standalone is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_3 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1931
+ /* "src/lxml/lxml.etree.pyx":1940
* (u'US-ASCII', u'ASCII', u'UTF8', u'UTF-8')
* if standalone is None:
* is_standalone = -1 # <<<<<<<<<<<<<<
goto __pyx_L16;
}
- /* "src/lxml/lxml.etree.pyx":1932
+ /* "src/lxml/lxml.etree.pyx":1941
* if standalone is None:
* is_standalone = -1
* elif standalone: # <<<<<<<<<<<<<<
* write_declaration = 1
* is_standalone = 1
*/
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_standalone); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1932; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_standalone); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1941; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":1933
+ /* "src/lxml/lxml.etree.pyx":1942
* is_standalone = -1
* elif standalone:
* write_declaration = 1 # <<<<<<<<<<<<<<
*/
__pyx_v_write_declaration = 1;
- /* "src/lxml/lxml.etree.pyx":1934
+ /* "src/lxml/lxml.etree.pyx":1943
* elif standalone:
* write_declaration = 1
* is_standalone = 1 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1936
+ /* "src/lxml/lxml.etree.pyx":1945
* is_standalone = 1
* else:
* write_declaration = 1 # <<<<<<<<<<<<<<
*/
__pyx_v_write_declaration = 1;
- /* "src/lxml/lxml.etree.pyx":1937
+ /* "src/lxml/lxml.etree.pyx":1946
* else:
* write_declaration = 1
* is_standalone = 0 # <<<<<<<<<<<<<<
}
__pyx_L16:;
- /* "src/lxml/lxml.etree.pyx":1938
+ /* "src/lxml/lxml.etree.pyx":1947
* write_declaration = 1
* is_standalone = 0
* _tofilelike(file, self._context_node, encoding, docstring, method, # <<<<<<<<<<<<<<
__pyx_t_6 = ((PyObject *)__pyx_v_self->_context_node);
__Pyx_INCREF(__pyx_t_6);
- /* "src/lxml/lxml.etree.pyx":1939
+ /* "src/lxml/lxml.etree.pyx":1948
* is_standalone = 0
* _tofilelike(file, self._context_node, encoding, docstring, method,
* write_declaration, 1, pretty_print, with_tail, # <<<<<<<<<<<<<<
* is_standalone, compression)
*
*/
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_pretty_print); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1939; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_with_tail); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1939; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_pretty_print); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1948; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_with_tail); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1948; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1940
+ /* "src/lxml/lxml.etree.pyx":1949
* _tofilelike(file, self._context_node, encoding, docstring, method,
* write_declaration, 1, pretty_print, with_tail,
* is_standalone, compression) # <<<<<<<<<<<<<<
*
* def getpath(self, _Element element not None):
*/
- __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1940; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1949; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1938
+ /* "src/lxml/lxml.etree.pyx":1947
* write_declaration = 1
* is_standalone = 0
* _tofilelike(file, self._context_node, encoding, docstring, method, # <<<<<<<<<<<<<<
* write_declaration, 1, pretty_print, with_tail,
* is_standalone, compression)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__tofilelike(__pyx_v_file, ((struct LxmlElement *)__pyx_t_6), __pyx_v_encoding, __pyx_v_docstring, __pyx_v_method, __pyx_v_write_declaration, 1, __pyx_t_5, __pyx_t_3, __pyx_v_is_standalone, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__tofilelike(__pyx_v_file, ((struct LxmlElement *)__pyx_t_6), __pyx_v_encoding, __pyx_v_docstring, __pyx_v_method, __pyx_v_write_declaration, 1, __pyx_t_5, __pyx_t_3, __pyx_v_is_standalone, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1947; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":1860
+ /* "src/lxml/lxml.etree.pyx":1869
* return None
*
* def write(self, file, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1942
+/* "src/lxml/lxml.etree.pyx":1951
* is_standalone, compression)
*
* def getpath(self, _Element element not None): # <<<<<<<<<<<<<<
PyObject *__pyx_r = 0;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("getpath (wrapper)", 0);
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1942; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1951; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_12_ElementTree_12getpath(((struct LxmlElementTree *)__pyx_v_self), ((struct LxmlElement *)__pyx_v_element));
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("getpath", 0);
- /* "src/lxml/lxml.etree.pyx":1957
+ /* "src/lxml/lxml.etree.pyx":1966
* cdef _Element root
* cdef xmlDoc* c_doc
* _assertValidNode(element) # <<<<<<<<<<<<<<
* if self._context_node is not None:
* root = self._context_node
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1957; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1966; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1958
+ /* "src/lxml/lxml.etree.pyx":1967
* cdef xmlDoc* c_doc
* _assertValidNode(element)
* if self._context_node is not None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1959
+ /* "src/lxml/lxml.etree.pyx":1968
* _assertValidNode(element)
* if self._context_node is not None:
* root = self._context_node # <<<<<<<<<<<<<<
__pyx_v_root = ((struct LxmlElement *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1960
+ /* "src/lxml/lxml.etree.pyx":1969
* if self._context_node is not None:
* root = self._context_node
* doc = root._doc # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":1961
+ /* "src/lxml/lxml.etree.pyx":1970
* root = self._context_node
* doc = root._doc
* elif self._doc is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1962
+ /* "src/lxml/lxml.etree.pyx":1971
* doc = root._doc
* elif self._doc is not None:
* doc = self._doc # <<<<<<<<<<<<<<
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1963
+ /* "src/lxml/lxml.etree.pyx":1972
* elif self._doc is not None:
* doc = self._doc
* root = doc.getroot() # <<<<<<<<<<<<<<
* else:
* raise ValueError, u"Element is not in this tree."
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1963; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1972; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1963; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1972; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_root = ((struct LxmlElement *)__pyx_t_4);
__pyx_t_4 = 0;
goto __pyx_L3;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":1965
+ /* "src/lxml/lxml.etree.pyx":1974
* root = doc.getroot()
* else:
* raise ValueError, u"Element is not in this tree." # <<<<<<<<<<<<<<
* _assertValidNode(root)
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_in_this_tree, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1974; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":1966
+ /* "src/lxml/lxml.etree.pyx":1975
* else:
* raise ValueError, u"Element is not in this tree."
* _assertValidDoc(doc) # <<<<<<<<<<<<<<
* _assertValidNode(root)
* if element._doc is not doc:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidDoc(__pyx_v_doc); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1966; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidDoc(__pyx_v_doc); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1975; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1967
+ /* "src/lxml/lxml.etree.pyx":1976
* raise ValueError, u"Element is not in this tree."
* _assertValidDoc(doc)
* _assertValidNode(root) # <<<<<<<<<<<<<<
* if element._doc is not doc:
* raise ValueError, u"Element is not in this tree."
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1967; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1976; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1968
+ /* "src/lxml/lxml.etree.pyx":1977
* _assertValidDoc(doc)
* _assertValidNode(root)
* if element._doc is not doc: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1969
+ /* "src/lxml/lxml.etree.pyx":1978
* _assertValidNode(root)
* if element._doc is not doc:
* raise ValueError, u"Element is not in this tree." # <<<<<<<<<<<<<<
* c_doc = _fakeRootDoc(doc._c_doc, root._c_node)
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_in_this_tree, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1969; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1978; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1971
+ /* "src/lxml/lxml.etree.pyx":1980
* raise ValueError, u"Element is not in this tree."
*
* c_doc = _fakeRootDoc(doc._c_doc, root._c_node) # <<<<<<<<<<<<<<
* c_path = tree.xmlGetNodePath(element._c_node)
* _destroyFakeDoc(doc._c_doc, c_doc)
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__fakeRootDoc(__pyx_v_doc->_c_doc, __pyx_v_root->_c_node); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1971; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__fakeRootDoc(__pyx_v_doc->_c_doc, __pyx_v_root->_c_node); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1980; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_5;
- /* "src/lxml/lxml.etree.pyx":1972
+ /* "src/lxml/lxml.etree.pyx":1981
*
* c_doc = _fakeRootDoc(doc._c_doc, root._c_node)
* c_path = tree.xmlGetNodePath(element._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_path = xmlGetNodePath(__pyx_v_element->_c_node);
- /* "src/lxml/lxml.etree.pyx":1973
+ /* "src/lxml/lxml.etree.pyx":1982
* c_doc = _fakeRootDoc(doc._c_doc, root._c_node)
* c_path = tree.xmlGetNodePath(element._c_node)
* _destroyFakeDoc(doc._c_doc, c_doc) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__destroyFakeDoc(__pyx_v_doc->_c_doc, __pyx_v_c_doc);
- /* "src/lxml/lxml.etree.pyx":1974
+ /* "src/lxml/lxml.etree.pyx":1983
* c_path = tree.xmlGetNodePath(element._c_node)
* _destroyFakeDoc(doc._c_doc, c_doc)
* if c_path is NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_path == NULL) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1975
+ /* "src/lxml/lxml.etree.pyx":1984
* _destroyFakeDoc(doc._c_doc, c_doc)
* if c_path is NULL:
* raise MemoryError() # <<<<<<<<<<<<<<
* path = funicode(c_path)
* tree.xmlFree(c_path)
*/
- PyErr_NoMemory(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1975; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyErr_NoMemory(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1976
+ /* "src/lxml/lxml.etree.pyx":1985
* if c_path is NULL:
* raise MemoryError()
* path = funicode(c_path) # <<<<<<<<<<<<<<
* tree.xmlFree(c_path)
* return path
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree_funicode(__pyx_v_c_path); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1976; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_funicode(__pyx_v_c_path); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1985; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_path = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":1977
+ /* "src/lxml/lxml.etree.pyx":1986
* raise MemoryError()
* path = funicode(c_path)
* tree.xmlFree(c_path) # <<<<<<<<<<<<<<
*/
xmlFree(__pyx_v_c_path);
- /* "src/lxml/lxml.etree.pyx":1978
+ /* "src/lxml/lxml.etree.pyx":1987
* path = funicode(c_path)
* tree.xmlFree(c_path)
* return path # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_path;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1942
+ /* "src/lxml/lxml.etree.pyx":1951
* is_standalone, compression)
*
* def getpath(self, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":1980
+/* "src/lxml/lxml.etree.pyx":1989
* return path
*
* def getelementpath(self, _Element element not None): # <<<<<<<<<<<<<<
PyObject *__pyx_r = 0;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("getelementpath (wrapper)", 0);
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1980; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1989; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_12_ElementTree_14getelementpath(((struct LxmlElementTree *)__pyx_v_self), ((struct LxmlElement *)__pyx_v_element));
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("getelementpath", 0);
- /* "src/lxml/lxml.etree.pyx":1994
+ /* "src/lxml/lxml.etree.pyx":2003
* cdef _Element root
* cdef Py_ssize_t count
* _assertValidNode(element) # <<<<<<<<<<<<<<
* if element._c_node.type != tree.XML_ELEMENT_NODE:
* raise ValueError, u"input is not an Element"
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1994; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2003; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":1995
+ /* "src/lxml/lxml.etree.pyx":2004
* cdef Py_ssize_t count
* _assertValidNode(element)
* if element._c_node.type != tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_element->_c_node->type != XML_ELEMENT_NODE) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":1996
+ /* "src/lxml/lxml.etree.pyx":2005
* _assertValidNode(element)
* if element._c_node.type != tree.XML_ELEMENT_NODE:
* raise ValueError, u"input is not an Element" # <<<<<<<<<<<<<<
* root = self._context_node
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_input_is_not_an_Element, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1996; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2005; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":1997
+ /* "src/lxml/lxml.etree.pyx":2006
* if element._c_node.type != tree.XML_ELEMENT_NODE:
* raise ValueError, u"input is not an Element"
* if self._context_node is not None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":1998
+ /* "src/lxml/lxml.etree.pyx":2007
* raise ValueError, u"input is not an Element"
* if self._context_node is not None:
* root = self._context_node # <<<<<<<<<<<<<<
goto __pyx_L4;
}
- /* "src/lxml/lxml.etree.pyx":1999
+ /* "src/lxml/lxml.etree.pyx":2008
* if self._context_node is not None:
* root = self._context_node
* elif self._doc is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2000
+ /* "src/lxml/lxml.etree.pyx":2009
* root = self._context_node
* elif self._doc is not None:
* root = self._doc.getroot() # <<<<<<<<<<<<<<
* else:
* raise ValueError, u"Element is not in this tree"
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_self->_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2000; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_self->_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2009; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2000; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2009; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_root = ((struct LxmlElement *)__pyx_t_4);
__pyx_t_4 = 0;
goto __pyx_L4;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2002
+ /* "src/lxml/lxml.etree.pyx":2011
* root = self._doc.getroot()
* else:
* raise ValueError, u"Element is not in this tree" # <<<<<<<<<<<<<<
* if element._doc is not root._doc:
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_in_this_tree_2, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2002; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2011; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L4:;
- /* "src/lxml/lxml.etree.pyx":2003
+ /* "src/lxml/lxml.etree.pyx":2012
* else:
* raise ValueError, u"Element is not in this tree"
* _assertValidNode(root) # <<<<<<<<<<<<<<
* if element._doc is not root._doc:
* raise ValueError, u"Element is not in this tree"
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2003; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_root); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2012; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2004
+ /* "src/lxml/lxml.etree.pyx":2013
* raise ValueError, u"Element is not in this tree"
* _assertValidNode(root)
* if element._doc is not root._doc: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2005
+ /* "src/lxml/lxml.etree.pyx":2014
* _assertValidNode(root)
* if element._doc is not root._doc:
* raise ValueError, u"Element is not in this tree" # <<<<<<<<<<<<<<
* path = []
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_in_this_tree_2, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2005; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2014; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2007
+ /* "src/lxml/lxml.etree.pyx":2016
* raise ValueError, u"Element is not in this tree"
*
* path = [] # <<<<<<<<<<<<<<
* c_element = element._c_node
* while c_element is not root._c_node:
*/
- __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2007; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2016; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_path = ((PyObject*)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2008
+ /* "src/lxml/lxml.etree.pyx":2017
*
* path = []
* c_element = element._c_node # <<<<<<<<<<<<<<
__pyx_t_5 = __pyx_v_element->_c_node;
__pyx_v_c_element = __pyx_t_5;
- /* "src/lxml/lxml.etree.pyx":2009
+ /* "src/lxml/lxml.etree.pyx":2018
* path = []
* c_element = element._c_node
* while c_element is not root._c_node: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_element != __pyx_v_root->_c_node) != 0);
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":2010
+ /* "src/lxml/lxml.etree.pyx":2019
* c_element = element._c_node
* while c_element is not root._c_node:
* c_name = c_element.name # <<<<<<<<<<<<<<
__pyx_t_6 = __pyx_v_c_element->name;
__pyx_v_c_name = __pyx_t_6;
- /* "src/lxml/lxml.etree.pyx":2011
+ /* "src/lxml/lxml.etree.pyx":2020
* while c_element is not root._c_node:
* c_name = c_element.name
* c_href = _getNs(c_element) # <<<<<<<<<<<<<<
*/
__pyx_v_c_href = _getNs(__pyx_v_c_element);
- /* "src/lxml/lxml.etree.pyx":2012
+ /* "src/lxml/lxml.etree.pyx":2021
* c_name = c_element.name
* c_href = _getNs(c_element)
* tag = _namespacedNameFromNsName(c_href, c_name) # <<<<<<<<<<<<<<
* if c_href is NULL:
* c_href = <const_xmlChar*>b'' # no namespace (NULL is wildcard)
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedNameFromNsName(__pyx_v_c_href, __pyx_v_c_name); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2012; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedNameFromNsName(__pyx_v_c_href, __pyx_v_c_name); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2021; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_XDECREF_SET(__pyx_v_tag, __pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2013
+ /* "src/lxml/lxml.etree.pyx":2022
* c_href = _getNs(c_element)
* tag = _namespacedNameFromNsName(c_href, c_name)
* if c_href is NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_href == NULL) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2014
+ /* "src/lxml/lxml.etree.pyx":2023
* tag = _namespacedNameFromNsName(c_href, c_name)
* if c_href is NULL:
* c_href = <const_xmlChar*>b'' # no namespace (NULL is wildcard) # <<<<<<<<<<<<<<
}
__pyx_L8:;
- /* "src/lxml/lxml.etree.pyx":2016
+ /* "src/lxml/lxml.etree.pyx":2025
* c_href = <const_xmlChar*>b'' # no namespace (NULL is wildcard)
* # use tag[N] if there are preceding siblings with the same tag
* count = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_count = 0;
- /* "src/lxml/lxml.etree.pyx":2017
+ /* "src/lxml/lxml.etree.pyx":2026
* # use tag[N] if there are preceding siblings with the same tag
* count = 0
* c_node = c_element.prev # <<<<<<<<<<<<<<
__pyx_t_5 = __pyx_v_c_element->prev;
__pyx_v_c_node = __pyx_t_5;
- /* "src/lxml/lxml.etree.pyx":2018
+ /* "src/lxml/lxml.etree.pyx":2027
* count = 0
* c_node = c_element.prev
* while c_node is not NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node != NULL) != 0);
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":2019
+ /* "src/lxml/lxml.etree.pyx":2028
* c_node = c_element.prev
* while c_node is not NULL:
* if c_node.type == tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node->type == XML_ELEMENT_NODE) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2020
+ /* "src/lxml/lxml.etree.pyx":2029
* while c_node is not NULL:
* if c_node.type == tree.XML_ELEMENT_NODE:
* if _tagMatches(c_node, c_href, c_name): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_f_4lxml_5etree__tagMatches(__pyx_v_c_node, __pyx_v_c_href, __pyx_v_c_name) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2021
+ /* "src/lxml/lxml.etree.pyx":2030
* if c_node.type == tree.XML_ELEMENT_NODE:
* if _tagMatches(c_node, c_href, c_name):
* count += 1 # <<<<<<<<<<<<<<
}
__pyx_L11:;
- /* "src/lxml/lxml.etree.pyx":2022
+ /* "src/lxml/lxml.etree.pyx":2031
* if _tagMatches(c_node, c_href, c_name):
* count += 1
* c_node = c_node.prev # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_t_5;
}
- /* "src/lxml/lxml.etree.pyx":2023
+ /* "src/lxml/lxml.etree.pyx":2032
* count += 1
* c_node = c_node.prev
* if count: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_v_count != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2024
+ /* "src/lxml/lxml.etree.pyx":2033
* c_node = c_node.prev
* if count:
* tag = '%s[%d]' % (tag, count+1) # <<<<<<<<<<<<<<
* else:
* # use tag[1] if there are following siblings with the same tag
*/
- __pyx_t_4 = PyInt_FromSsize_t((__pyx_v_count + 1)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyInt_FromSsize_t((__pyx_v_count + 1)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_t_4);
__Pyx_GIVEREF(__pyx_t_4);
__pyx_t_4 = 0;
- __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_s_d, __pyx_t_7); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_s_d, __pyx_t_7); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF_SET(__pyx_v_tag, __pyx_t_4);
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2027
+ /* "src/lxml/lxml.etree.pyx":2036
* else:
* # use tag[1] if there are following siblings with the same tag
* c_node = c_element.next # <<<<<<<<<<<<<<
__pyx_t_5 = __pyx_v_c_element->next;
__pyx_v_c_node = __pyx_t_5;
- /* "src/lxml/lxml.etree.pyx":2028
+ /* "src/lxml/lxml.etree.pyx":2037
* # use tag[1] if there are following siblings with the same tag
* c_node = c_element.next
* while c_node is not NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node != NULL) != 0);
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":2029
+ /* "src/lxml/lxml.etree.pyx":2038
* c_node = c_element.next
* while c_node is not NULL:
* if c_node.type == tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node->type == XML_ELEMENT_NODE) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2030
+ /* "src/lxml/lxml.etree.pyx":2039
* while c_node is not NULL:
* if c_node.type == tree.XML_ELEMENT_NODE:
* if _tagMatches(c_node, c_href, c_name): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_f_4lxml_5etree__tagMatches(__pyx_v_c_node, __pyx_v_c_href, __pyx_v_c_name) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2031
+ /* "src/lxml/lxml.etree.pyx":2040
* if c_node.type == tree.XML_ELEMENT_NODE:
* if _tagMatches(c_node, c_href, c_name):
* tag += '[1]' # <<<<<<<<<<<<<<
* break
* c_node = c_node.next
*/
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tag, __pyx_kp_s_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2031; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_tag, __pyx_kp_s_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2040; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_tag, __pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2032
+ /* "src/lxml/lxml.etree.pyx":2041
* if _tagMatches(c_node, c_href, c_name):
* tag += '[1]'
* break # <<<<<<<<<<<<<<
}
__pyx_L16:;
- /* "src/lxml/lxml.etree.pyx":2033
+ /* "src/lxml/lxml.etree.pyx":2042
* tag += '[1]'
* break
* c_node = c_node.next # <<<<<<<<<<<<<<
}
__pyx_L13:;
- /* "src/lxml/lxml.etree.pyx":2035
+ /* "src/lxml/lxml.etree.pyx":2044
* c_node = c_node.next
*
* path.append(tag) # <<<<<<<<<<<<<<
* c_element = c_element.parent
* if c_element is NULL or c_element.type != tree.XML_ELEMENT_NODE:
*/
- __pyx_t_8 = __Pyx_PyList_Append(__pyx_v_path, __pyx_v_tag); if (unlikely(__pyx_t_8 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2035; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyList_Append(__pyx_v_path, __pyx_v_tag); if (unlikely(__pyx_t_8 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2044; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2036
+ /* "src/lxml/lxml.etree.pyx":2045
*
* path.append(tag)
* c_element = c_element.parent # <<<<<<<<<<<<<<
__pyx_t_5 = __pyx_v_c_element->parent;
__pyx_v_c_element = __pyx_t_5;
- /* "src/lxml/lxml.etree.pyx":2037
+ /* "src/lxml/lxml.etree.pyx":2046
* path.append(tag)
* c_element = c_element.parent
* if c_element is NULL or c_element.type != tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_L19_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2038
+ /* "src/lxml/lxml.etree.pyx":2047
* c_element = c_element.parent
* if c_element is NULL or c_element.type != tree.XML_ELEMENT_NODE:
* raise ValueError, u"Element is not in this tree." # <<<<<<<<<<<<<<
* return '.'
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Element_is_not_in_this_tree, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2038; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2047; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
- /* "src/lxml/lxml.etree.pyx":2039
+ /* "src/lxml/lxml.etree.pyx":2048
* if c_element is NULL or c_element.type != tree.XML_ELEMENT_NODE:
* raise ValueError, u"Element is not in this tree."
* if not path: # <<<<<<<<<<<<<<
__pyx_t_2 = ((!__pyx_t_3) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2040
+ /* "src/lxml/lxml.etree.pyx":2049
* raise ValueError, u"Element is not in this tree."
* if not path:
* return '.' # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2041
+ /* "src/lxml/lxml.etree.pyx":2050
* if not path:
* return '.'
* path.reverse() # <<<<<<<<<<<<<<
* return '/'.join(path)
*
*/
- __pyx_t_8 = PyList_Reverse(__pyx_v_path); if (unlikely(__pyx_t_8 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2041; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PyList_Reverse(__pyx_v_path); if (unlikely(__pyx_t_8 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2050; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2042
+ /* "src/lxml/lxml.etree.pyx":2051
* return '.'
* path.reverse()
* return '/'.join(path) # <<<<<<<<<<<<<<
* def getiterator(self, tag=None, *tags):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __Pyx_PyString_Join(__pyx_kp_s__30, __pyx_v_path); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2042; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyString_Join(__pyx_kp_s__31, __pyx_v_path); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2051; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":1980
+ /* "src/lxml/lxml.etree.pyx":1989
* return path
*
* def getelementpath(self, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2044
+/* "src/lxml/lxml.etree.pyx":2053
* return '/'.join(path)
*
* def getiterator(self, tag=None, *tags): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "getiterator") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2044; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "getiterator") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2053; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("getiterator", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":2061
+ /* "src/lxml/lxml.etree.pyx":2070
* with older versions of lxml or ElementTree.
* """
* root = self.getroot() # <<<<<<<<<<<<<<
* if root is None:
* return ITER_EMPTY
*/
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2061; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2070; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_3 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
}
}
if (__pyx_t_3) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2061; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2070; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
} else {
- __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2061; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2070; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_v_root = __pyx_t_1;
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2062
+ /* "src/lxml/lxml.etree.pyx":2071
* """
* root = self.getroot()
* if root is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2063
+ /* "src/lxml/lxml.etree.pyx":2072
* root = self.getroot()
* if root is None:
* return ITER_EMPTY # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2064
+ /* "src/lxml/lxml.etree.pyx":2073
* if root is None:
* return ITER_EMPTY
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_4 = (__pyx_t_5 != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2065
+ /* "src/lxml/lxml.etree.pyx":2074
* return ITER_EMPTY
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return root.getiterator(*tags)
*
*/
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2065; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2074; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2065; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2074; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_2));
}
__pyx_L4:;
- /* "src/lxml/lxml.etree.pyx":2066
+ /* "src/lxml/lxml.etree.pyx":2075
* if tag is not None:
* tags += (tag,)
* return root.getiterator(*tags) # <<<<<<<<<<<<<<
* def iter(self, tag=None, *tags):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_getiterator); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2066; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_getiterator); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2075; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_1 = PySequence_Tuple(__pyx_v_tags); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2066; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PySequence_Tuple(__pyx_v_tags); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2075; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2066; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2075; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2044
+ /* "src/lxml/lxml.etree.pyx":2053
* return '/'.join(path)
*
* def getiterator(self, tag=None, *tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2068
+/* "src/lxml/lxml.etree.pyx":2077
* return root.getiterator(*tags)
*
* def iter(self, tag=None, *tags): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iter") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2068; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "iter") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2077; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__Pyx_RefNannySetupContext("iter", 0);
__Pyx_INCREF(__pyx_v_tags);
- /* "src/lxml/lxml.etree.pyx":2079
+ /* "src/lxml/lxml.etree.pyx":2088
* see `_Element.iter`.
* """
* root = self.getroot() # <<<<<<<<<<<<<<
* if root is None:
* return ITER_EMPTY
*/
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_3 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
}
}
if (__pyx_t_3) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
} else {
- __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_v_root = __pyx_t_1;
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2080
+ /* "src/lxml/lxml.etree.pyx":2089
* """
* root = self.getroot()
* if root is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2081
+ /* "src/lxml/lxml.etree.pyx":2090
* root = self.getroot()
* if root is None:
* return ITER_EMPTY # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2082
+ /* "src/lxml/lxml.etree.pyx":2091
* if root is None:
* return ITER_EMPTY
* if tag is not None: # <<<<<<<<<<<<<<
__pyx_t_4 = (__pyx_t_5 != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2083
+ /* "src/lxml/lxml.etree.pyx":2092
* return ITER_EMPTY
* if tag is not None:
* tags += (tag,) # <<<<<<<<<<<<<<
* return root.iter(*tags)
*
*/
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2083; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2092; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2083; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyNumber_InPlaceAdd(__pyx_v_tags, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2092; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_2));
}
__pyx_L4:;
- /* "src/lxml/lxml.etree.pyx":2084
+ /* "src/lxml/lxml.etree.pyx":2093
* if tag is not None:
* tags += (tag,)
* return root.iter(*tags) # <<<<<<<<<<<<<<
* def find(self, path, namespaces=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_iter); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2084; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_iter); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2093; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_1 = PySequence_Tuple(__pyx_v_tags); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2084; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PySequence_Tuple(__pyx_v_tags); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2093; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2084; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2093; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2068
+ /* "src/lxml/lxml.etree.pyx":2077
* return root.getiterator(*tags)
*
* def iter(self, tag=None, *tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2086
+/* "src/lxml/lxml.etree.pyx":2095
* return root.iter(*tags)
*
* def find(self, path, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "find") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2086; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "find") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2095; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("find", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2086; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("find", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2095; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ElementTree.find", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("find", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":2096
+ /* "src/lxml/lxml.etree.pyx":2105
* prefixes in the path expression.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* root = self.getroot()
* if _isString(path):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2096; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2105; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2097
+ /* "src/lxml/lxml.etree.pyx":2106
* """
* self._assertHasRoot()
* root = self.getroot() # <<<<<<<<<<<<<<
* if _isString(path):
* if path[:1] == "/":
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2097; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_4) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2097; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
} else {
- __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2097; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_root = __pyx_t_2;
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2098
+ /* "src/lxml/lxml.etree.pyx":2107
* self._assertHasRoot()
* root = self.getroot()
* if _isString(path): # <<<<<<<<<<<<<<
__pyx_t_5 = (_isString(__pyx_v_path) != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2099
+ /* "src/lxml/lxml.etree.pyx":2108
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.find(path, namespaces)
*/
- __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__31, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__32, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__30, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__31, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2100
+ /* "src/lxml/lxml.etree.pyx":2109
* if _isString(path):
* if path[:1] == "/":
* path = "." + path # <<<<<<<<<<<<<<
* return root.find(path, namespaces)
*
*/
- __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2100; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF_SET(__pyx_v_path, __pyx_t_2);
__pyx_t_2 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2101
+ /* "src/lxml/lxml.etree.pyx":2110
* if path[:1] == "/":
* path = "." + path
* return root.find(path, namespaces) # <<<<<<<<<<<<<<
* def findtext(self, path, default=None, namespaces=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_find); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2101; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_find); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2101; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_4) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __pyx_t_4 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2101; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2086
+ /* "src/lxml/lxml.etree.pyx":2095
* return root.iter(*tags)
*
* def find(self, path, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2103
+/* "src/lxml/lxml.etree.pyx":2112
* return root.find(path, namespaces)
*
* def findtext(self, path, default=None, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findtext") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2103; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findtext") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2112; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("findtext", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2103; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("findtext", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2112; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ElementTree.findtext", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("findtext", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":2113
+ /* "src/lxml/lxml.etree.pyx":2122
* prefixes in the path expression.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* root = self.getroot()
* if _isString(path):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2113; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2122; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2114
+ /* "src/lxml/lxml.etree.pyx":2123
* """
* self._assertHasRoot()
* root = self.getroot() # <<<<<<<<<<<<<<
* if _isString(path):
* if path[:1] == "/":
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2123; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_4) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2123; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
} else {
- __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2123; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_root = __pyx_t_2;
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2115
+ /* "src/lxml/lxml.etree.pyx":2124
* self._assertHasRoot()
* root = self.getroot()
* if _isString(path): # <<<<<<<<<<<<<<
__pyx_t_5 = (_isString(__pyx_v_path) != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2116
+ /* "src/lxml/lxml.etree.pyx":2125
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.findtext(path, default, namespaces)
*/
- __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__32, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__33, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2125; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__30, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__31, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2125; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2117
+ /* "src/lxml/lxml.etree.pyx":2126
* if _isString(path):
* if path[:1] == "/":
* path = "." + path # <<<<<<<<<<<<<<
* return root.findtext(path, default, namespaces)
*
*/
- __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF_SET(__pyx_v_path, __pyx_t_2);
__pyx_t_2 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2118
+ /* "src/lxml/lxml.etree.pyx":2127
* if path[:1] == "/":
* path = "." + path
* return root.findtext(path, default, namespaces) # <<<<<<<<<<<<<<
* def findall(self, path, namespaces=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_findtext); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_findtext); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_4) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __pyx_t_4 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2127; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2103
+ /* "src/lxml/lxml.etree.pyx":2112
* return root.find(path, namespaces)
*
* def findtext(self, path, default=None, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2120
+/* "src/lxml/lxml.etree.pyx":2129
* return root.findtext(path, default, namespaces)
*
* def findall(self, path, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findall") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2120; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "findall") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2129; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("findall", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2120; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("findall", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2129; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ElementTree.findall", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("findall", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":2130
+ /* "src/lxml/lxml.etree.pyx":2139
* prefixes in the path expression.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* root = self.getroot()
* if _isString(path):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2130; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2139; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2131
+ /* "src/lxml/lxml.etree.pyx":2140
* """
* self._assertHasRoot()
* root = self.getroot() # <<<<<<<<<<<<<<
* if _isString(path):
* if path[:1] == "/":
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2131; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2140; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_4) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2131; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2140; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
} else {
- __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2131; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2140; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_root = __pyx_t_2;
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2132
+ /* "src/lxml/lxml.etree.pyx":2141
* self._assertHasRoot()
* root = self.getroot()
* if _isString(path): # <<<<<<<<<<<<<<
__pyx_t_5 = (_isString(__pyx_v_path) != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2133
+ /* "src/lxml/lxml.etree.pyx":2142
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.findall(path, namespaces)
*/
- __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__33, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__34, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__30, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__31, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2134
+ /* "src/lxml/lxml.etree.pyx":2143
* if _isString(path):
* if path[:1] == "/":
* path = "." + path # <<<<<<<<<<<<<<
* return root.findall(path, namespaces)
*
*/
- __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2134; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF_SET(__pyx_v_path, __pyx_t_2);
__pyx_t_2 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2135
+ /* "src/lxml/lxml.etree.pyx":2144
* if path[:1] == "/":
* path = "." + path
* return root.findall(path, namespaces) # <<<<<<<<<<<<<<
* def iterfind(self, path, namespaces=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_findall); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_findall); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_4) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __pyx_t_4 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2120
+ /* "src/lxml/lxml.etree.pyx":2129
* return root.findtext(path, default, namespaces)
*
* def findall(self, path, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2137
+/* "src/lxml/lxml.etree.pyx":2146
* return root.findall(path, namespaces)
*
* def iterfind(self, path, namespaces=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "iterfind") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "iterfind") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2146; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("iterfind", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("iterfind", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2146; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ElementTree.iterfind", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("iterfind", 0);
__Pyx_INCREF(__pyx_v_path);
- /* "src/lxml/lxml.etree.pyx":2147
+ /* "src/lxml/lxml.etree.pyx":2156
* prefixes in the path expression.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* root = self.getroot()
* if _isString(path):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2156; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2148
+ /* "src/lxml/lxml.etree.pyx":2157
* """
* self._assertHasRoot()
* root = self.getroot() # <<<<<<<<<<<<<<
* if _isString(path):
* if path[:1] == "/":
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2148; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_getroot); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2157; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_4) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2148; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2157; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
} else {
- __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2148; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2157; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_root = __pyx_t_2;
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2149
+ /* "src/lxml/lxml.etree.pyx":2158
* self._assertHasRoot()
* root = self.getroot()
* if _isString(path): # <<<<<<<<<<<<<<
__pyx_t_5 = (_isString(__pyx_v_path) != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2150
+ /* "src/lxml/lxml.etree.pyx":2159
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.iterfind(path, namespaces)
*/
- __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__34, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2150; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_v_path, 0, 1, NULL, NULL, &__pyx_slice__35, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__30, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2150; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_t_2, __pyx_kp_s__31, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2151
+ /* "src/lxml/lxml.etree.pyx":2160
* if _isString(path):
* if path[:1] == "/":
* path = "." + path # <<<<<<<<<<<<<<
* return root.iterfind(path, namespaces)
*
*/
- __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2151; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyNumber_Add(__pyx_kp_s__4, __pyx_v_path); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2160; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF_SET(__pyx_v_path, __pyx_t_2);
__pyx_t_2 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2152
+ /* "src/lxml/lxml.etree.pyx":2161
* if path[:1] == "/":
* path = "." + path
* return root.iterfind(path, namespaces) # <<<<<<<<<<<<<<
* def xpath(self, _path, *, namespaces=None, extensions=None,
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_iterfind); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2152; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_root, __pyx_n_s_iterfind); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
__pyx_t_6 = 0;
__pyx_t_6 = 1;
}
}
- __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2152; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
if (__pyx_t_4) {
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __pyx_t_4 = NULL;
__Pyx_INCREF(__pyx_v_namespaces);
PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_v_namespaces);
__Pyx_GIVEREF(__pyx_v_namespaces);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2152; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2137
+ /* "src/lxml/lxml.etree.pyx":2146
* return root.findall(path, namespaces)
*
* def iterfind(self, path, namespaces=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2154
+/* "src/lxml/lxml.etree.pyx":2163
* return root.iterfind(path, namespaces)
*
* def xpath(self, _path, *, namespaces=None, extensions=None, # <<<<<<<<<<<<<<
values[1] = ((PyObject *)Py_None);
values[2] = ((PyObject *)Py_None);
- /* "src/lxml/lxml.etree.pyx":2155
+ /* "src/lxml/lxml.etree.pyx":2164
*
* def xpath(self, _path, *, namespaces=None, extensions=None,
* smart_strings=True, **_variables): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__variables, values, pos_args, "xpath") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2154; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__variables, values, pos_args, "xpath") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2163; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("xpath", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2154; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("xpath", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2163; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v__variables); __pyx_v__variables = 0;
__Pyx_AddTraceback("lxml.etree._ElementTree.xpath", __pyx_clineno, __pyx_lineno, __pyx_filename);
__pyx_L4_argument_unpacking_done:;
__pyx_r = __pyx_pf_4lxml_5etree_12_ElementTree_28xpath(((struct LxmlElementTree *)__pyx_v_self), __pyx_v__path, __pyx_v_namespaces, __pyx_v_extensions, __pyx_v_smart_strings, __pyx_v__variables);
- /* "src/lxml/lxml.etree.pyx":2154
+ /* "src/lxml/lxml.etree.pyx":2163
* return root.iterfind(path, namespaces)
*
* def xpath(self, _path, *, namespaces=None, extensions=None, # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("xpath", 0);
- /* "src/lxml/lxml.etree.pyx":2173
+ /* "src/lxml/lxml.etree.pyx":2182
* XPathEvaluator directly.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* evaluator = XPathDocumentEvaluator(self, namespaces=namespaces,
* extensions=extensions,
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2174
+ /* "src/lxml/lxml.etree.pyx":2183
* """
* self._assertHasRoot()
* evaluator = XPathDocumentEvaluator(self, namespaces=namespaces, # <<<<<<<<<<<<<<
* extensions=extensions,
* smart_strings=smart_strings)
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2183; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2183; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_namespaces, __pyx_v_namespaces) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_namespaces, __pyx_v_namespaces) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2183; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2175
+ /* "src/lxml/lxml.etree.pyx":2184
* self._assertHasRoot()
* evaluator = XPathDocumentEvaluator(self, namespaces=namespaces,
* extensions=extensions, # <<<<<<<<<<<<<<
* smart_strings=smart_strings)
* return evaluator(_path, **_variables)
*/
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_extensions, __pyx_v_extensions) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_extensions, __pyx_v_extensions) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2183; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2176
+ /* "src/lxml/lxml.etree.pyx":2185
* evaluator = XPathDocumentEvaluator(self, namespaces=namespaces,
* extensions=extensions,
* smart_strings=smart_strings) # <<<<<<<<<<<<<<
* return evaluator(_path, **_variables)
*
*/
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_smart_strings, __pyx_v_smart_strings) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_smart_strings, __pyx_v_smart_strings) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2183; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2174
+ /* "src/lxml/lxml.etree.pyx":2183
* """
* self._assertHasRoot()
* evaluator = XPathDocumentEvaluator(self, namespaces=namespaces, # <<<<<<<<<<<<<<
* extensions=extensions,
* smart_strings=smart_strings)
*/
- __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPathDocumentEvaluator)), __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPathDocumentEvaluator)), __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2183; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_evaluator = ((struct __pyx_obj_4lxml_5etree_XPathDocumentEvaluator *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2177
+ /* "src/lxml/lxml.etree.pyx":2186
* extensions=extensions,
* smart_strings=smart_strings)
* return evaluator(_path, **_variables) # <<<<<<<<<<<<<<
* def xslt(self, _xslt, extensions=None, access_control=None, **_kw):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2177; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2186; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(__pyx_v__path);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__path);
__Pyx_GIVEREF(__pyx_v__path);
__pyx_t_3 = __pyx_v__variables;
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_evaluator), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2177; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_evaluator), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2186; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2154
+ /* "src/lxml/lxml.etree.pyx":2163
* return root.iterfind(path, namespaces)
*
* def xpath(self, _path, *, namespaces=None, extensions=None, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2179
+/* "src/lxml/lxml.etree.pyx":2188
* return evaluator(_path, **_variables)
*
* def xslt(self, _xslt, extensions=None, access_control=None, **_kw): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__kw, values, pos_args, "xslt") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2179; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__kw, values, pos_args, "xslt") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2188; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("xslt", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2179; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("xslt", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2188; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v__kw); __pyx_v__kw = 0;
__Pyx_AddTraceback("lxml.etree._ElementTree.xslt", __pyx_clineno, __pyx_lineno, __pyx_filename);
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("xslt", 0);
- /* "src/lxml/lxml.etree.pyx":2193
+ /* "src/lxml/lxml.etree.pyx":2202
* class directly.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* style = XSLT(_xslt, extensions=extensions,
* access_control=access_control)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2193; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2194
+ /* "src/lxml/lxml.etree.pyx":2203
* """
* self._assertHasRoot()
* style = XSLT(_xslt, extensions=extensions, # <<<<<<<<<<<<<<
* access_control=access_control)
* return style(self, **_kw)
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(__pyx_v__xslt);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v__xslt);
__Pyx_GIVEREF(__pyx_v__xslt);
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_extensions, __pyx_v_extensions) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_extensions, __pyx_v_extensions) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2195
+ /* "src/lxml/lxml.etree.pyx":2204
* self._assertHasRoot()
* style = XSLT(_xslt, extensions=extensions,
* access_control=access_control) # <<<<<<<<<<<<<<
* return style(self, **_kw)
*
*/
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_access_control, __pyx_v_access_control) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_access_control, __pyx_v_access_control) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2194
+ /* "src/lxml/lxml.etree.pyx":2203
* """
* self._assertHasRoot()
* style = XSLT(_xslt, extensions=extensions, # <<<<<<<<<<<<<<
* access_control=access_control)
* return style(self, **_kw)
*/
- __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XSLT)), __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XSLT)), __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_style = ((struct __pyx_obj_4lxml_5etree_XSLT *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2196
+ /* "src/lxml/lxml.etree.pyx":2205
* style = XSLT(_xslt, extensions=extensions,
* access_control=access_control)
* return style(self, **_kw) # <<<<<<<<<<<<<<
* def relaxng(self, relaxng):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2196; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2205; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
__pyx_t_3 = __pyx_v__kw;
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_style), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2196; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_style), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2205; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2179
+ /* "src/lxml/lxml.etree.pyx":2188
* return evaluator(_path, **_variables)
*
* def xslt(self, _xslt, extensions=None, access_control=None, **_kw): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2198
+/* "src/lxml/lxml.etree.pyx":2207
* return style(self, **_kw)
*
* def relaxng(self, relaxng): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("relaxng", 0);
- /* "src/lxml/lxml.etree.pyx":2212
+ /* "src/lxml/lxml.etree.pyx":2221
* class directly.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* schema = RelaxNG(relaxng)
* return schema.validate(self)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2213
+ /* "src/lxml/lxml.etree.pyx":2222
* """
* self._assertHasRoot()
* schema = RelaxNG(relaxng) # <<<<<<<<<<<<<<
* return schema.validate(self)
*
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2213; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2222; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(__pyx_v_relaxng);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_relaxng);
__Pyx_GIVEREF(__pyx_v_relaxng);
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_RelaxNG)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2213; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_RelaxNG)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2222; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_v_schema = ((struct __pyx_obj_4lxml_5etree_RelaxNG *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2214
+ /* "src/lxml/lxml.etree.pyx":2223
* self._assertHasRoot()
* schema = RelaxNG(relaxng)
* return schema.validate(self) # <<<<<<<<<<<<<<
* def xmlschema(self, xmlschema):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_schema), __pyx_n_s_validate); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_schema), __pyx_n_s_validate); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
}
}
if (!__pyx_t_4) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
} else {
- __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __pyx_t_4 = NULL;
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_5, 0+1, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2214; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2198
+ /* "src/lxml/lxml.etree.pyx":2207
* return style(self, **_kw)
*
* def relaxng(self, relaxng): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2216
+/* "src/lxml/lxml.etree.pyx":2225
* return schema.validate(self)
*
* def xmlschema(self, xmlschema): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("xmlschema", 0);
- /* "src/lxml/lxml.etree.pyx":2230
+ /* "src/lxml/lxml.etree.pyx":2239
* class directly.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* schema = XMLSchema(xmlschema)
* return schema.validate(self)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2231
+ /* "src/lxml/lxml.etree.pyx":2240
* """
* self._assertHasRoot()
* schema = XMLSchema(xmlschema) # <<<<<<<<<<<<<<
* return schema.validate(self)
*
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2231; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2240; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(__pyx_v_xmlschema);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_xmlschema);
__Pyx_GIVEREF(__pyx_v_xmlschema);
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XMLSchema)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2231; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XMLSchema)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2240; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_v_schema = ((struct __pyx_obj_4lxml_5etree_XMLSchema *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2232
+ /* "src/lxml/lxml.etree.pyx":2241
* self._assertHasRoot()
* schema = XMLSchema(xmlschema)
* return schema.validate(self) # <<<<<<<<<<<<<<
* def xinclude(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_schema), __pyx_n_s_validate); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_schema), __pyx_n_s_validate); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_2))) {
}
}
if (!__pyx_t_4) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
} else {
- __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __pyx_t_4 = NULL;
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_5, 0+1, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2216
+ /* "src/lxml/lxml.etree.pyx":2225
* return schema.validate(self)
*
* def xmlschema(self, xmlschema): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2234
+/* "src/lxml/lxml.etree.pyx":2243
* return schema.validate(self)
*
* def xinclude(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("xinclude", 0);
- /* "src/lxml/lxml.etree.pyx":2246
+ /* "src/lxml/lxml.etree.pyx":2255
* due to restrictions of libxml2 <= 2.6.29.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* XInclude()(self._context_node)
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2246; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2255; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2247
+ /* "src/lxml/lxml.etree.pyx":2256
* """
* self._assertHasRoot()
* XInclude()(self._context_node) # <<<<<<<<<<<<<<
*
* def write_c14n(self, file, *, exclusive=False, with_comments=True,
*/
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XInclude)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XInclude)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_3))) {
}
}
if (!__pyx_t_4) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_v_self->_context_node)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_v_self->_context_node)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
} else {
- __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __pyx_t_4 = NULL;
__Pyx_INCREF(((PyObject *)__pyx_v_self->_context_node));
PyTuple_SET_ITEM(__pyx_t_5, 0+1, ((PyObject *)__pyx_v_self->_context_node));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self->_context_node));
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2234
+ /* "src/lxml/lxml.etree.pyx":2243
* return schema.validate(self)
*
* def xinclude(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2249
+/* "src/lxml/lxml.etree.pyx":2258
* XInclude()(self._context_node)
*
* def write_c14n(self, file, *, exclusive=False, with_comments=True, # <<<<<<<<<<<<<<
values[2] = ((PyObject *)Py_True);
values[3] = ((PyObject *)__pyx_int_0);
- /* "src/lxml/lxml.etree.pyx":2250
+ /* "src/lxml/lxml.etree.pyx":2259
*
* def write_c14n(self, file, *, exclusive=False, with_comments=True,
* compression=0, inclusive_ns_prefixes=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "write_c14n") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2249; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "write_c14n") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2258; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("write_c14n", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2249; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("write_c14n", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2258; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._ElementTree.write_c14n", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__pyx_L4_argument_unpacking_done:;
__pyx_r = __pyx_pf_4lxml_5etree_12_ElementTree_38write_c14n(((struct LxmlElementTree *)__pyx_v_self), __pyx_v_file, __pyx_v_exclusive, __pyx_v_with_comments, __pyx_v_compression, __pyx_v_inclusive_ns_prefixes);
- /* "src/lxml/lxml.etree.pyx":2249
+ /* "src/lxml/lxml.etree.pyx":2258
* XInclude()(self._context_node)
*
* def write_c14n(self, file, *, exclusive=False, with_comments=True, # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("write_c14n", 0);
__Pyx_INCREF(__pyx_v_compression);
- /* "src/lxml/lxml.etree.pyx":2268
+ /* "src/lxml/lxml.etree.pyx":2277
* of the namespace node's parent element.
* """
* self._assertHasRoot() # <<<<<<<<<<<<<<
* _assertValidNode(self._context_node)
* if compression is None or compression < 0:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2268; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot(__pyx_v_self); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2277; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2269
+ /* "src/lxml/lxml.etree.pyx":2278
* """
* self._assertHasRoot()
* _assertValidNode(self._context_node) # <<<<<<<<<<<<<<
*/
__pyx_t_2 = ((PyObject *)__pyx_v_self->_context_node);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_2)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2269; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_2)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2278; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2270
+ /* "src/lxml/lxml.etree.pyx":2279
* self._assertHasRoot()
* _assertValidNode(self._context_node)
* if compression is None or compression < 0: # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_t_5;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_2 = PyObject_RichCompare(__pyx_v_compression, __pyx_int_0, Py_LT); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2270; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2270; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_RichCompare(__pyx_v_compression, __pyx_int_0, Py_LT); __Pyx_XGOTREF(__pyx_t_2); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2279; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2279; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_t_3 = __pyx_t_5;
__pyx_L4_bool_binop_done:;
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2271
+ /* "src/lxml/lxml.etree.pyx":2280
* _assertValidNode(self._context_node)
* if compression is None or compression < 0:
* compression = 0 # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2273
+ /* "src/lxml/lxml.etree.pyx":2282
* compression = 0
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments, # <<<<<<<<<<<<<<
*/
__pyx_t_2 = ((PyObject *)__pyx_v_self->_context_node);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_exclusive); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2273; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_with_comments); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2273; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_exclusive); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_with_comments); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2274
+ /* "src/lxml/lxml.etree.pyx":2283
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments,
* compression, inclusive_ns_prefixes) # <<<<<<<<<<<<<<
*
* cdef _ElementTree _elementTreeFactory(_Document doc, _Element context_node):
*/
- __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2274; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2283; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2273
+ /* "src/lxml/lxml.etree.pyx":2282
* compression = 0
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments, # <<<<<<<<<<<<<<
* compression, inclusive_ns_prefixes)
*
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree__tofilelikeC14N(__pyx_v_file, ((struct LxmlElement *)__pyx_t_2), __pyx_t_3, __pyx_t_5, __pyx_t_1, __pyx_v_inclusive_ns_prefixes); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2273; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__tofilelikeC14N(__pyx_v_file, ((struct LxmlElement *)__pyx_t_2), __pyx_t_3, __pyx_t_5, __pyx_t_1, __pyx_v_inclusive_ns_prefixes); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":2249
+ /* "src/lxml/lxml.etree.pyx":2258
* XInclude()(self._context_node)
*
* def write_c14n(self, file, *, exclusive=False, with_comments=True, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2276
+/* "src/lxml/lxml.etree.pyx":2285
* compression, inclusive_ns_prefixes)
*
* cdef _ElementTree _elementTreeFactory(_Document doc, _Element context_node): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_elementTreeFactory", 0);
- /* "src/lxml/lxml.etree.pyx":2277
+ /* "src/lxml/lxml.etree.pyx":2286
*
* cdef _ElementTree _elementTreeFactory(_Document doc, _Element context_node):
* return _newElementTree(doc, context_node, _ElementTree) # <<<<<<<<<<<<<<
* cdef _ElementTree _newElementTree(_Document doc, _Element context_node,
*/
__Pyx_XDECREF(((PyObject *)__pyx_r));
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__newElementTree(__pyx_v_doc, __pyx_v_context_node, ((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ElementTree)))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2277; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__newElementTree(__pyx_v_doc, __pyx_v_context_node, ((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ElementTree)))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2286; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = ((struct LxmlElementTree *)__pyx_t_1);
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2276
+ /* "src/lxml/lxml.etree.pyx":2285
* compression, inclusive_ns_prefixes)
*
* cdef _ElementTree _elementTreeFactory(_Document doc, _Element context_node): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2279
+/* "src/lxml/lxml.etree.pyx":2288
* return _newElementTree(doc, context_node, _ElementTree)
*
* cdef _ElementTree _newElementTree(_Document doc, _Element context_node, # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("_newElementTree", 0);
__Pyx_INCREF((PyObject *)__pyx_v_context_node);
- /* "src/lxml/lxml.etree.pyx":2282
+ /* "src/lxml/lxml.etree.pyx":2291
* object baseclass):
* cdef _ElementTree result
* result = baseclass() # <<<<<<<<<<<<<<
}
}
if (__pyx_t_3) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2291; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
} else {
- __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2291; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__ElementTree))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2282; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__ElementTree))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2291; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_result = ((struct LxmlElementTree *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2283
+ /* "src/lxml/lxml.etree.pyx":2292
* cdef _ElementTree result
* result = baseclass()
* if context_node is None and doc is not None: # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2284
+ /* "src/lxml/lxml.etree.pyx":2293
* result = baseclass()
* if context_node is None and doc is not None:
* context_node = doc.getroot() # <<<<<<<<<<<<<<
* if context_node is None:
* _assertValidDoc(doc)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2284; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2293; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2284; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2293; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF_SET(__pyx_v_context_node, ((struct LxmlElement *)__pyx_t_1));
__pyx_t_1 = 0;
goto __pyx_L3;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2285
+ /* "src/lxml/lxml.etree.pyx":2294
* if context_node is None and doc is not None:
* context_node = doc.getroot()
* if context_node is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2286
+ /* "src/lxml/lxml.etree.pyx":2295
* context_node = doc.getroot()
* if context_node is None:
* _assertValidDoc(doc) # <<<<<<<<<<<<<<
* result._doc = doc
* else:
*/
- __pyx_t_7 = __pyx_f_4lxml_5etree__assertValidDoc(__pyx_v_doc); if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2286; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __pyx_f_4lxml_5etree__assertValidDoc(__pyx_v_doc); if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2295; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2287
+ /* "src/lxml/lxml.etree.pyx":2296
* if context_node is None:
* _assertValidDoc(doc)
* result._doc = doc # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2289
+ /* "src/lxml/lxml.etree.pyx":2298
* result._doc = doc
* else:
* _assertValidNode(context_node) # <<<<<<<<<<<<<<
* result._context_node = context_node
* return result
*/
- __pyx_t_7 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_context_node); if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2289; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_context_node); if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2298; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":2290
+ /* "src/lxml/lxml.etree.pyx":2299
* else:
* _assertValidNode(context_node)
* result._context_node = context_node # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_result->_context_node));
__pyx_v_result->_context_node = __pyx_v_context_node;
- /* "src/lxml/lxml.etree.pyx":2291
+ /* "src/lxml/lxml.etree.pyx":2300
* _assertValidNode(context_node)
* result._context_node = context_node
* return result # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_result;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2279
+ /* "src/lxml/lxml.etree.pyx":2288
* return _newElementTree(doc, context_node, _ElementTree)
*
* cdef _ElementTree _newElementTree(_Document doc, _Element context_node, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2300
+/* "src/lxml/lxml.etree.pyx":2309
* """
* cdef _Element _element
* def __cinit__(self, _Element element not None): # <<<<<<<<<<<<<<
else goto __pyx_L5_argtuple_error;
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2300; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2309; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2300; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2309; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Attrib.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2300; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2309; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_7_Attrib___cinit__(((struct __pyx_obj_4lxml_5etree__Attrib *)__pyx_v_self), __pyx_v_element);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2301
+ /* "src/lxml/lxml.etree.pyx":2310
* cdef _Element _element
* def __cinit__(self, _Element element not None):
* _assertValidNode(element) # <<<<<<<<<<<<<<
* self._element = element
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2301; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2310; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2302
+ /* "src/lxml/lxml.etree.pyx":2311
* def __cinit__(self, _Element element not None):
* _assertValidNode(element)
* self._element = element # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_element));
__pyx_v_self->_element = __pyx_v_element;
- /* "src/lxml/lxml.etree.pyx":2300
+ /* "src/lxml/lxml.etree.pyx":2309
* """
* cdef _Element _element
* def __cinit__(self, _Element element not None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2305
+/* "src/lxml/lxml.etree.pyx":2314
*
* # MANIPULATORS
* def __setitem__(self, key, value): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__setitem__", 0);
- /* "src/lxml/lxml.etree.pyx":2306
+ /* "src/lxml/lxml.etree.pyx":2315
* # MANIPULATORS
* def __setitem__(self, key, value):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2315; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2307
+ /* "src/lxml/lxml.etree.pyx":2316
* def __setitem__(self, key, value):
* _assertValidNode(self._element)
* _setAttributeValue(self._element, key, value) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__setAttributeValue(((struct LxmlElement *)__pyx_t_1), __pyx_v_key, __pyx_v_value); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__setAttributeValue(((struct LxmlElement *)__pyx_t_1), __pyx_v_key, __pyx_v_value); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2305
+ /* "src/lxml/lxml.etree.pyx":2314
*
* # MANIPULATORS
* def __setitem__(self, key, value): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2309
+/* "src/lxml/lxml.etree.pyx":2318
* _setAttributeValue(self._element, key, value)
*
* def __delitem__(self, key): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__delitem__", 0);
- /* "src/lxml/lxml.etree.pyx":2310
+ /* "src/lxml/lxml.etree.pyx":2319
*
* def __delitem__(self, key):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2310; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2319; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2311
+ /* "src/lxml/lxml.etree.pyx":2320
* def __delitem__(self, key):
* _assertValidNode(self._element)
* _delAttribute(self._element, key) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__delAttribute(((struct LxmlElement *)__pyx_t_1), __pyx_v_key); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2311; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__delAttribute(((struct LxmlElement *)__pyx_t_1), __pyx_v_key); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2320; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2309
+ /* "src/lxml/lxml.etree.pyx":2318
* _setAttributeValue(self._element, key, value)
*
* def __delitem__(self, key): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2313
+/* "src/lxml/lxml.etree.pyx":2322
* _delAttribute(self._element, key)
*
* def update(self, sequence_or_dict): # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("update", 0);
__Pyx_INCREF(__pyx_v_sequence_or_dict);
- /* "src/lxml/lxml.etree.pyx":2314
+ /* "src/lxml/lxml.etree.pyx":2323
*
* def update(self, sequence_or_dict):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2314; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2323; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2315
+ /* "src/lxml/lxml.etree.pyx":2324
* def update(self, sequence_or_dict):
* _assertValidNode(self._element)
* if isinstance(sequence_or_dict, (dict, _Attrib)): # <<<<<<<<<<<<<<
__pyx_t_4 = (__pyx_t_3 != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2316
+ /* "src/lxml/lxml.etree.pyx":2325
* _assertValidNode(self._element)
* if isinstance(sequence_or_dict, (dict, _Attrib)):
* sequence_or_dict = sequence_or_dict.items() # <<<<<<<<<<<<<<
* for key, value in sequence_or_dict:
* _setAttributeValue(self._element, key, value)
*/
- __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_sequence_or_dict, __pyx_n_s_items); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_sequence_or_dict, __pyx_n_s_items); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_t_7 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_6))) {
}
}
if (__pyx_t_7) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
} else {
- __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_6); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2316; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_6); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2317
+ /* "src/lxml/lxml.etree.pyx":2326
* if isinstance(sequence_or_dict, (dict, _Attrib)):
* sequence_or_dict = sequence_or_dict.items()
* for key, value in sequence_or_dict: # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_sequence_or_dict; __Pyx_INCREF(__pyx_t_1); __pyx_t_8 = 0;
__pyx_t_9 = NULL;
} else {
- __pyx_t_8 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_sequence_or_dict); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_sequence_or_dict); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_9 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
for (;;) {
if (likely(!__pyx_t_9)) {
if (likely(PyList_CheckExact(__pyx_t_1))) {
if (__pyx_t_8 >= PyList_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_6); __pyx_t_8++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_6); __pyx_t_8++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
} else {
if (__pyx_t_8 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_6 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_6); __pyx_t_8++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_8); __Pyx_INCREF(__pyx_t_6); __pyx_t_8++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_8); __pyx_t_8++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
}
} else {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
break;
}
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_7);
__Pyx_INCREF(__pyx_t_10);
#else
- __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
- __pyx_t_10 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_10);
#endif
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_11 = PyObject_GetIter(__pyx_t_6); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_11 = PyObject_GetIter(__pyx_t_6); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_11);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_t_12 = Py_TYPE(__pyx_t_11)->tp_iternext;
__Pyx_GOTREF(__pyx_t_7);
index = 1; __pyx_t_10 = __pyx_t_12(__pyx_t_11); if (unlikely(!__pyx_t_10)) goto __pyx_L8_unpacking_failed;
__Pyx_GOTREF(__pyx_t_10);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_12(__pyx_t_11), 2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_12(__pyx_t_11), 2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_12 = NULL;
__Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
goto __pyx_L9_unpacking_done;
__Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
__pyx_t_12 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2317; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2326; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L9_unpacking_done:;
}
__Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_7);
__Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_10);
__pyx_t_10 = 0;
- /* "src/lxml/lxml.etree.pyx":2318
+ /* "src/lxml/lxml.etree.pyx":2327
* sequence_or_dict = sequence_or_dict.items()
* for key, value in sequence_or_dict:
* _setAttributeValue(self._element, key, value) # <<<<<<<<<<<<<<
*/
__pyx_t_6 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_6);
- __pyx_t_2 = __pyx_f_4lxml_5etree__setAttributeValue(((struct LxmlElement *)__pyx_t_6), __pyx_v_key, __pyx_v_value); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2318; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__setAttributeValue(((struct LxmlElement *)__pyx_t_6), __pyx_v_key, __pyx_v_value); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2327; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":2317
+ /* "src/lxml/lxml.etree.pyx":2326
* if isinstance(sequence_or_dict, (dict, _Attrib)):
* sequence_or_dict = sequence_or_dict.items()
* for key, value in sequence_or_dict: # <<<<<<<<<<<<<<
}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2313
+ /* "src/lxml/lxml.etree.pyx":2322
* _delAttribute(self._element, key)
*
* def update(self, sequence_or_dict): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2320
+/* "src/lxml/lxml.etree.pyx":2329
* _setAttributeValue(self._element, key, value)
*
* def pop(self, key, *default): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "pop") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2320; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, used_pos_args, "pop") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2329; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) < 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("pop", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2320; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("pop", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2329; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v_default); __pyx_v_default = 0;
__Pyx_AddTraceback("lxml.etree._Attrib.pop", __pyx_clineno, __pyx_lineno, __pyx_filename);
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("pop", 0);
- /* "src/lxml/lxml.etree.pyx":2321
+ /* "src/lxml/lxml.etree.pyx":2330
*
* def pop(self, key, *default):
* if len(default) > 1: # <<<<<<<<<<<<<<
* raise TypeError, u"pop expected at most 2 arguments, got %d" % (
* len(default)+1)
*/
- __pyx_t_1 = PyTuple_GET_SIZE(__pyx_v_default); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2321; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_GET_SIZE(__pyx_v_default); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2330; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = ((__pyx_t_1 > 1) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2323
+ /* "src/lxml/lxml.etree.pyx":2332
* if len(default) > 1:
* raise TypeError, u"pop expected at most 2 arguments, got %d" % (
* len(default)+1) # <<<<<<<<<<<<<<
* _assertValidNode(self._element)
* result = _getAttributeValue(self._element, key, None)
*/
- __pyx_t_1 = PyTuple_GET_SIZE(__pyx_v_default); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2323; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = PyInt_FromSsize_t((__pyx_t_1 + 1)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2323; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_GET_SIZE(__pyx_v_default); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2332; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyInt_FromSsize_t((__pyx_t_1 + 1)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2332; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- /* "src/lxml/lxml.etree.pyx":2322
+ /* "src/lxml/lxml.etree.pyx":2331
* def pop(self, key, *default):
* if len(default) > 1:
* raise TypeError, u"pop expected at most 2 arguments, got %d" % ( # <<<<<<<<<<<<<<
* len(default)+1)
* _assertValidNode(self._element)
*/
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_pop_expected_at_most_2_arguments, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2322; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_pop_expected_at_most_2_arguments, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2331; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_t_4, 0, 0);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2322; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2331; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2324
+ /* "src/lxml/lxml.etree.pyx":2333
* raise TypeError, u"pop expected at most 2 arguments, got %d" % (
* len(default)+1)
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_4 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_4);
- __pyx_t_5 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_4)); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2324; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_4)); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2333; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2325
+ /* "src/lxml/lxml.etree.pyx":2334
* len(default)+1)
* _assertValidNode(self._element)
* result = _getAttributeValue(self._element, key, None) # <<<<<<<<<<<<<<
*/
__pyx_t_4 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_4);
- __pyx_t_3 = __pyx_f_4lxml_5etree__getAttributeValue(((struct LxmlElement *)__pyx_t_4), __pyx_v_key, Py_None); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2325; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__getAttributeValue(((struct LxmlElement *)__pyx_t_4), __pyx_v_key, Py_None); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2334; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_v_result = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2326
+ /* "src/lxml/lxml.etree.pyx":2335
* _assertValidNode(self._element)
* result = _getAttributeValue(self._element, key, None)
* if result is None: # <<<<<<<<<<<<<<
__pyx_t_6 = (__pyx_t_2 != 0);
if (__pyx_t_6) {
- /* "src/lxml/lxml.etree.pyx":2327
+ /* "src/lxml/lxml.etree.pyx":2336
* result = _getAttributeValue(self._element, key, None)
* if result is None:
* if not default: # <<<<<<<<<<<<<<
__pyx_t_2 = ((!__pyx_t_6) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2328
+ /* "src/lxml/lxml.etree.pyx":2337
* if result is None:
* if not default:
* raise KeyError, key # <<<<<<<<<<<<<<
* else:
*/
__Pyx_Raise(__pyx_builtin_KeyError, __pyx_v_key, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2328; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2337; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2329
+ /* "src/lxml/lxml.etree.pyx":2338
* if not default:
* raise KeyError, key
* result = default[0] # <<<<<<<<<<<<<<
* else:
* _delAttribute(self._element, key)
*/
- __pyx_t_3 = __Pyx_GetItemInt_Tuple(__pyx_v_default, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2329; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_3 = __Pyx_GetItemInt_Tuple(__pyx_v_default, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2338; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_result, __pyx_t_3);
__pyx_t_3 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2331
+ /* "src/lxml/lxml.etree.pyx":2340
* result = default[0]
* else:
* _delAttribute(self._element, key) # <<<<<<<<<<<<<<
*/
__pyx_t_3 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_5 = __pyx_f_4lxml_5etree__delAttribute(((struct LxmlElement *)__pyx_t_3), __pyx_v_key); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2331; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__delAttribute(((struct LxmlElement *)__pyx_t_3), __pyx_v_key); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2340; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
}
__pyx_L4:;
- /* "src/lxml/lxml.etree.pyx":2332
+ /* "src/lxml/lxml.etree.pyx":2341
* else:
* _delAttribute(self._element, key)
* return result # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_result;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2320
+ /* "src/lxml/lxml.etree.pyx":2329
* _setAttributeValue(self._element, key, value)
*
* def pop(self, key, *default): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2334
+/* "src/lxml/lxml.etree.pyx":2343
* return result
*
* def clear(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("clear", 0);
- /* "src/lxml/lxml.etree.pyx":2335
+ /* "src/lxml/lxml.etree.pyx":2344
*
* def clear(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2335; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2344; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2336
+ /* "src/lxml/lxml.etree.pyx":2345
* def clear(self):
* _assertValidNode(self._element)
* cdef xmlNode* c_node = self._element._c_node # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_self->_element->_c_node;
__pyx_v_c_node = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2337
+ /* "src/lxml/lxml.etree.pyx":2346
* _assertValidNode(self._element)
* cdef xmlNode* c_node = self._element._c_node
* while c_node.properties is not NULL: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_node->properties != NULL) != 0);
if (!__pyx_t_4) break;
- /* "src/lxml/lxml.etree.pyx":2338
+ /* "src/lxml/lxml.etree.pyx":2347
* cdef xmlNode* c_node = self._element._c_node
* while c_node.properties is not NULL:
* tree.xmlRemoveProp(c_node.properties) # <<<<<<<<<<<<<<
xmlRemoveProp(__pyx_v_c_node->properties);
}
- /* "src/lxml/lxml.etree.pyx":2334
+ /* "src/lxml/lxml.etree.pyx":2343
* return result
*
* def clear(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2341
+/* "src/lxml/lxml.etree.pyx":2350
*
* # ACCESSORS
* def __repr__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__repr__", 0);
- /* "src/lxml/lxml.etree.pyx":2342
+ /* "src/lxml/lxml.etree.pyx":2351
* # ACCESSORS
* def __repr__(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2342; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2351; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2343
+ /* "src/lxml/lxml.etree.pyx":2352
* def __repr__(self):
* _assertValidNode(self._element)
* return repr(dict( _collectAttributes(self._element._c_node, 3) )) # <<<<<<<<<<<<<<
* def __copy__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2343; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2352; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2343; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2352; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__pyx_t_1 = 0;
- __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2343; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2352; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = PyObject_Repr(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2343; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_Repr(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2352; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2341
+ /* "src/lxml/lxml.etree.pyx":2350
*
* # ACCESSORS
* def __repr__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2345
+/* "src/lxml/lxml.etree.pyx":2354
* return repr(dict( _collectAttributes(self._element._c_node, 3) ))
*
* def __copy__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__copy__", 0);
- /* "src/lxml/lxml.etree.pyx":2346
+ /* "src/lxml/lxml.etree.pyx":2355
*
* def __copy__(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2346; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2355; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2347
+ /* "src/lxml/lxml.etree.pyx":2356
* def __copy__(self):
* _assertValidNode(self._element)
* return dict(_collectAttributes(self._element._c_node, 3)) # <<<<<<<<<<<<<<
* def __deepcopy__(self, memo):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2347; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2356; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2347; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2356; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__pyx_t_1 = 0;
- __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2347; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2356; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2345
+ /* "src/lxml/lxml.etree.pyx":2354
* return repr(dict( _collectAttributes(self._element._c_node, 3) ))
*
* def __copy__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2349
+/* "src/lxml/lxml.etree.pyx":2358
* return dict(_collectAttributes(self._element._c_node, 3))
*
* def __deepcopy__(self, memo): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__deepcopy__", 0);
- /* "src/lxml/lxml.etree.pyx":2350
+ /* "src/lxml/lxml.etree.pyx":2359
*
* def __deepcopy__(self, memo):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2350; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2359; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2351
+ /* "src/lxml/lxml.etree.pyx":2360
* def __deepcopy__(self, memo):
* _assertValidNode(self._element)
* return dict(_collectAttributes(self._element._c_node, 3)) # <<<<<<<<<<<<<<
* def __getitem__(self, key):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2351; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2360; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2351; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2360; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__pyx_t_1 = 0;
- __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2351; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_3, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2360; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2349
+ /* "src/lxml/lxml.etree.pyx":2358
* return dict(_collectAttributes(self._element._c_node, 3))
*
* def __deepcopy__(self, memo): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2353
+/* "src/lxml/lxml.etree.pyx":2362
* return dict(_collectAttributes(self._element._c_node, 3))
*
* def __getitem__(self, key): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__getitem__", 0);
- /* "src/lxml/lxml.etree.pyx":2354
+ /* "src/lxml/lxml.etree.pyx":2363
*
* def __getitem__(self, key):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2354; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2363; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2355
+ /* "src/lxml/lxml.etree.pyx":2364
* def __getitem__(self, key):
* _assertValidNode(self._element)
* result = _getAttributeValue(self._element, key, None) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_3 = __pyx_f_4lxml_5etree__getAttributeValue(((struct LxmlElement *)__pyx_t_1), __pyx_v_key, Py_None); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2355; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__getAttributeValue(((struct LxmlElement *)__pyx_t_1), __pyx_v_key, Py_None); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_v_result = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2356
+ /* "src/lxml/lxml.etree.pyx":2365
* _assertValidNode(self._element)
* result = _getAttributeValue(self._element, key, None)
* if result is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2357
+ /* "src/lxml/lxml.etree.pyx":2366
* result = _getAttributeValue(self._element, key, None)
* if result is None:
* raise KeyError, key # <<<<<<<<<<<<<<
*
*/
__Pyx_Raise(__pyx_builtin_KeyError, __pyx_v_key, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2357; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2366; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2358
+ /* "src/lxml/lxml.etree.pyx":2367
* if result is None:
* raise KeyError, key
* return result # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_result;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2353
+ /* "src/lxml/lxml.etree.pyx":2362
* return dict(_collectAttributes(self._element._c_node, 3))
*
* def __getitem__(self, key): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2360
+/* "src/lxml/lxml.etree.pyx":2369
* return result
*
* def __bool__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__bool__", 0);
- /* "src/lxml/lxml.etree.pyx":2361
+ /* "src/lxml/lxml.etree.pyx":2370
*
* def __bool__(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2361; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2370; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2362
+ /* "src/lxml/lxml.etree.pyx":2371
* def __bool__(self):
* _assertValidNode(self._element)
* cdef xmlAttr* c_attr = self._element._c_node.properties # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_self->_element->_c_node->properties;
__pyx_v_c_attr = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2363
+ /* "src/lxml/lxml.etree.pyx":2372
* _assertValidNode(self._element)
* cdef xmlAttr* c_attr = self._element._c_node.properties
* while c_attr is not NULL: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_attr != NULL) != 0);
if (!__pyx_t_4) break;
- /* "src/lxml/lxml.etree.pyx":2364
+ /* "src/lxml/lxml.etree.pyx":2373
* cdef xmlAttr* c_attr = self._element._c_node.properties
* while c_attr is not NULL:
* if c_attr.type == tree.XML_ATTRIBUTE_NODE: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_attr->type == XML_ATTRIBUTE_NODE) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2365
+ /* "src/lxml/lxml.etree.pyx":2374
* while c_attr is not NULL:
* if c_attr.type == tree.XML_ATTRIBUTE_NODE:
* return 1 # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2366
+ /* "src/lxml/lxml.etree.pyx":2375
* if c_attr.type == tree.XML_ATTRIBUTE_NODE:
* return 1
* c_attr = c_attr.next # <<<<<<<<<<<<<<
__pyx_v_c_attr = __pyx_t_3;
}
- /* "src/lxml/lxml.etree.pyx":2367
+ /* "src/lxml/lxml.etree.pyx":2376
* return 1
* c_attr = c_attr.next
* return 0 # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2360
+ /* "src/lxml/lxml.etree.pyx":2369
* return result
*
* def __bool__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2369
+/* "src/lxml/lxml.etree.pyx":2378
* return 0
*
* def __len__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__len__", 0);
- /* "src/lxml/lxml.etree.pyx":2370
+ /* "src/lxml/lxml.etree.pyx":2379
*
* def __len__(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2370; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2379; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2371
+ /* "src/lxml/lxml.etree.pyx":2380
* def __len__(self):
* _assertValidNode(self._element)
* cdef xmlAttr* c_attr = self._element._c_node.properties # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_self->_element->_c_node->properties;
__pyx_v_c_attr = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2372
+ /* "src/lxml/lxml.etree.pyx":2381
* _assertValidNode(self._element)
* cdef xmlAttr* c_attr = self._element._c_node.properties
* cdef Py_ssize_t c = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_c = 0;
- /* "src/lxml/lxml.etree.pyx":2373
+ /* "src/lxml/lxml.etree.pyx":2382
* cdef xmlAttr* c_attr = self._element._c_node.properties
* cdef Py_ssize_t c = 0
* while c_attr is not NULL: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_attr != NULL) != 0);
if (!__pyx_t_4) break;
- /* "src/lxml/lxml.etree.pyx":2374
+ /* "src/lxml/lxml.etree.pyx":2383
* cdef Py_ssize_t c = 0
* while c_attr is not NULL:
* if c_attr.type == tree.XML_ATTRIBUTE_NODE: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_c_attr->type == XML_ATTRIBUTE_NODE) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2375
+ /* "src/lxml/lxml.etree.pyx":2384
* while c_attr is not NULL:
* if c_attr.type == tree.XML_ATTRIBUTE_NODE:
* c += 1 # <<<<<<<<<<<<<<
}
__pyx_L5:;
- /* "src/lxml/lxml.etree.pyx":2376
+ /* "src/lxml/lxml.etree.pyx":2385
* if c_attr.type == tree.XML_ATTRIBUTE_NODE:
* c += 1
* c_attr = c_attr.next # <<<<<<<<<<<<<<
__pyx_v_c_attr = __pyx_t_3;
}
- /* "src/lxml/lxml.etree.pyx":2377
+ /* "src/lxml/lxml.etree.pyx":2386
* c += 1
* c_attr = c_attr.next
* return c # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_c;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2369
+ /* "src/lxml/lxml.etree.pyx":2378
* return 0
*
* def __len__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2379
+/* "src/lxml/lxml.etree.pyx":2388
* return c
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2379; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "get") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2388; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2379; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("get", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2388; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Attrib.get", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("get", 0);
- /* "src/lxml/lxml.etree.pyx":2380
+ /* "src/lxml/lxml.etree.pyx":2389
*
* def get(self, key, default=None):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2380; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2389; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2381
+ /* "src/lxml/lxml.etree.pyx":2390
* def get(self, key, default=None):
* _assertValidNode(self._element)
* return _getAttributeValue(self._element, key, default) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_3 = __pyx_f_4lxml_5etree__getAttributeValue(((struct LxmlElement *)__pyx_t_1), __pyx_v_key, __pyx_v_default); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__getAttributeValue(((struct LxmlElement *)__pyx_t_1), __pyx_v_key, __pyx_v_default); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2390; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2379
+ /* "src/lxml/lxml.etree.pyx":2388
* return c
*
* def get(self, key, default=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2383
+/* "src/lxml/lxml.etree.pyx":2392
* return _getAttributeValue(self._element, key, default)
*
* def keys(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("keys", 0);
- /* "src/lxml/lxml.etree.pyx":2384
+ /* "src/lxml/lxml.etree.pyx":2393
*
* def keys(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2384; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2393; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2385
+ /* "src/lxml/lxml.etree.pyx":2394
* def keys(self):
* _assertValidNode(self._element)
* return _collectAttributes(self._element._c_node, 1) # <<<<<<<<<<<<<<
* def __iter__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2385; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2394; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2383
+ /* "src/lxml/lxml.etree.pyx":2392
* return _getAttributeValue(self._element, key, default)
*
* def keys(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2387
+/* "src/lxml/lxml.etree.pyx":2396
* return _collectAttributes(self._element._c_node, 1)
*
* def __iter__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__iter__", 0);
- /* "src/lxml/lxml.etree.pyx":2388
+ /* "src/lxml/lxml.etree.pyx":2397
*
* def __iter__(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2397; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2389
+ /* "src/lxml/lxml.etree.pyx":2398
* def __iter__(self):
* _assertValidNode(self._element)
* return iter(_collectAttributes(self._element._c_node, 1)) # <<<<<<<<<<<<<<
* def iterkeys(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2389; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2389; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2387
+ /* "src/lxml/lxml.etree.pyx":2396
* return _collectAttributes(self._element._c_node, 1)
*
* def __iter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2391
+/* "src/lxml/lxml.etree.pyx":2400
* return iter(_collectAttributes(self._element._c_node, 1))
*
* def iterkeys(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("iterkeys", 0);
- /* "src/lxml/lxml.etree.pyx":2392
+ /* "src/lxml/lxml.etree.pyx":2401
*
* def iterkeys(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2392; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2401; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2393
+ /* "src/lxml/lxml.etree.pyx":2402
* def iterkeys(self):
* _assertValidNode(self._element)
* return iter(_collectAttributes(self._element._c_node, 1)) # <<<<<<<<<<<<<<
* def values(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2393; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2402; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2393; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2402; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2391
+ /* "src/lxml/lxml.etree.pyx":2400
* return iter(_collectAttributes(self._element._c_node, 1))
*
* def iterkeys(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2395
+/* "src/lxml/lxml.etree.pyx":2404
* return iter(_collectAttributes(self._element._c_node, 1))
*
* def values(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("values", 0);
- /* "src/lxml/lxml.etree.pyx":2396
+ /* "src/lxml/lxml.etree.pyx":2405
*
* def values(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2396; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2405; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2397
+ /* "src/lxml/lxml.etree.pyx":2406
* def values(self):
* _assertValidNode(self._element)
* return _collectAttributes(self._element._c_node, 2) # <<<<<<<<<<<<<<
* def itervalues(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2397; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2406; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2395
+ /* "src/lxml/lxml.etree.pyx":2404
* return iter(_collectAttributes(self._element._c_node, 1))
*
* def values(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2399
+/* "src/lxml/lxml.etree.pyx":2408
* return _collectAttributes(self._element._c_node, 2)
*
* def itervalues(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("itervalues", 0);
- /* "src/lxml/lxml.etree.pyx":2400
+ /* "src/lxml/lxml.etree.pyx":2409
*
* def itervalues(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2400; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2409; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2401
+ /* "src/lxml/lxml.etree.pyx":2410
* def itervalues(self):
* _assertValidNode(self._element)
* return iter(_collectAttributes(self._element._c_node, 2)) # <<<<<<<<<<<<<<
* def items(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2401; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2410; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2401; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2410; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2399
+ /* "src/lxml/lxml.etree.pyx":2408
* return _collectAttributes(self._element._c_node, 2)
*
* def itervalues(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2403
+/* "src/lxml/lxml.etree.pyx":2412
* return iter(_collectAttributes(self._element._c_node, 2))
*
* def items(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("items", 0);
- /* "src/lxml/lxml.etree.pyx":2404
+ /* "src/lxml/lxml.etree.pyx":2413
*
* def items(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2413; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2405
+ /* "src/lxml/lxml.etree.pyx":2414
* def items(self):
* _assertValidNode(self._element)
* return _collectAttributes(self._element._c_node, 3) # <<<<<<<<<<<<<<
* def iteritems(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2405; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2414; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2403
+ /* "src/lxml/lxml.etree.pyx":2412
* return iter(_collectAttributes(self._element._c_node, 2))
*
* def items(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2407
+/* "src/lxml/lxml.etree.pyx":2416
* return _collectAttributes(self._element._c_node, 3)
*
* def iteritems(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("iteritems", 0);
- /* "src/lxml/lxml.etree.pyx":2408
+ /* "src/lxml/lxml.etree.pyx":2417
*
* def iteritems(self):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2408; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2417; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2409
+ /* "src/lxml/lxml.etree.pyx":2418
* def iteritems(self):
* _assertValidNode(self._element)
* return iter(_collectAttributes(self._element._c_node, 3)) # <<<<<<<<<<<<<<
* def has_key(self, key):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2409; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__collectAttributes(__pyx_v_self->_element->_c_node, 3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2418; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2409; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2418; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2407
+ /* "src/lxml/lxml.etree.pyx":2416
* return _collectAttributes(self._element._c_node, 3)
*
* def iteritems(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2411
+/* "src/lxml/lxml.etree.pyx":2420
* return iter(_collectAttributes(self._element._c_node, 3))
*
* def has_key(self, key): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("has_key", 0);
- /* "src/lxml/lxml.etree.pyx":2412
+ /* "src/lxml/lxml.etree.pyx":2421
*
* def has_key(self, key):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2412; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2421; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2413
+ /* "src/lxml/lxml.etree.pyx":2422
* def has_key(self, key):
* _assertValidNode(self._element)
* return key in self # <<<<<<<<<<<<<<
* def __contains__(self, key):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_v_key, ((PyObject *)__pyx_v_self), Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2413; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2413; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_v_key, ((PyObject *)__pyx_v_self), Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2422; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_t_3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2422; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2411
+ /* "src/lxml/lxml.etree.pyx":2420
* return iter(_collectAttributes(self._element._c_node, 3))
*
* def has_key(self, key): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2415
+/* "src/lxml/lxml.etree.pyx":2424
* return key in self
*
* def __contains__(self, key): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__contains__", 0);
- /* "src/lxml/lxml.etree.pyx":2416
+ /* "src/lxml/lxml.etree.pyx":2425
*
* def __contains__(self, key):
* _assertValidNode(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_self->_element);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2416; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_t_1)); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2425; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2418
+ /* "src/lxml/lxml.etree.pyx":2427
* _assertValidNode(self._element)
* cdef xmlNode* c_node
* ns, tag = _getNsTag(key) # <<<<<<<<<<<<<<
* c_node = self._element._c_node
* c_href = <const_xmlChar*>NULL if ns is None else _xcstr(ns)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_key); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2418; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_key); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2427; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
if (likely(__pyx_t_1 != Py_None)) {
PyObject* sequence = __pyx_t_1;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2418; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2427; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
__pyx_t_3 = PyTuple_GET_ITEM(sequence, 0);
__Pyx_INCREF(__pyx_t_3);
__Pyx_INCREF(__pyx_t_4);
#else
- __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2418; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2427; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2418; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2427; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
#endif
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
} else {
- __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2418; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2427; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_v_ns = __pyx_t_3;
__pyx_t_3 = 0;
__pyx_v_tag = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2419
+ /* "src/lxml/lxml.etree.pyx":2428
* cdef xmlNode* c_node
* ns, tag = _getNsTag(key)
* c_node = self._element._c_node # <<<<<<<<<<<<<<
__pyx_t_5 = __pyx_v_self->_element->_c_node;
__pyx_v_c_node = __pyx_t_5;
- /* "src/lxml/lxml.etree.pyx":2420
+ /* "src/lxml/lxml.etree.pyx":2429
* ns, tag = _getNsTag(key)
* c_node = self._element._c_node
* c_href = <const_xmlChar*>NULL if ns is None else _xcstr(ns) # <<<<<<<<<<<<<<
}
__pyx_v_c_href = __pyx_t_6;
- /* "src/lxml/lxml.etree.pyx":2421
+ /* "src/lxml/lxml.etree.pyx":2430
* c_node = self._element._c_node
* c_href = <const_xmlChar*>NULL if ns is None else _xcstr(ns)
* return 1 if tree.xmlHasNsProp(c_node, _xcstr(tag), c_href) else 0 # <<<<<<<<<<<<<<
__pyx_r = __pyx_t_2;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2415
+ /* "src/lxml/lxml.etree.pyx":2424
* return key in self
*
* def __contains__(self, key): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2423
+/* "src/lxml/lxml.etree.pyx":2432
* return 1 if tree.xmlHasNsProp(c_node, _xcstr(tag), c_href) else 0
*
* def __richcmp__(one, other, int op): # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_v_one);
__Pyx_INCREF(__pyx_v_other);
- /* "src/lxml/lxml.etree.pyx":2424
+ /* "src/lxml/lxml.etree.pyx":2433
*
* def __richcmp__(one, other, int op):
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_3);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":2425
+ /* "src/lxml/lxml.etree.pyx":2434
* def __richcmp__(one, other, int op):
* try:
* if not isinstance(one, dict): # <<<<<<<<<<<<<<
__pyx_t_5 = ((!(__pyx_t_4 != 0)) != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":2426
+ /* "src/lxml/lxml.etree.pyx":2435
* try:
* if not isinstance(one, dict):
* one = dict(one) # <<<<<<<<<<<<<<
* if not isinstance(other, dict):
* other = dict(other)
*/
- __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2426; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2435; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_INCREF(__pyx_v_one);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_v_one);
__Pyx_GIVEREF(__pyx_v_one);
- __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_6, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2426; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_6, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2435; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_DECREF_SET(__pyx_v_one, __pyx_t_7);
}
__pyx_L11:;
- /* "src/lxml/lxml.etree.pyx":2427
+ /* "src/lxml/lxml.etree.pyx":2436
* if not isinstance(one, dict):
* one = dict(one)
* if not isinstance(other, dict): # <<<<<<<<<<<<<<
__pyx_t_4 = ((!(__pyx_t_5 != 0)) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2428
+ /* "src/lxml/lxml.etree.pyx":2437
* one = dict(one)
* if not isinstance(other, dict):
* other = dict(other) # <<<<<<<<<<<<<<
* except (TypeError, ValueError):
* return NotImplemented
*/
- __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2428; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2437; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_INCREF(__pyx_v_other);
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_v_other);
__Pyx_GIVEREF(__pyx_v_other);
- __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_7, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2428; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)(&PyDict_Type))), __pyx_t_7, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2437; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF_SET(__pyx_v_other, __pyx_t_6);
__Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":2429
+ /* "src/lxml/lxml.etree.pyx":2438
* if not isinstance(other, dict):
* other = dict(other)
* except (TypeError, ValueError): # <<<<<<<<<<<<<<
__pyx_t_8 = PyErr_ExceptionMatches(__pyx_builtin_TypeError) || PyErr_ExceptionMatches(__pyx_builtin_ValueError);
if (__pyx_t_8) {
__Pyx_AddTraceback("lxml.etree._Attrib.__richcmp__", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_7, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2429; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_7, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2438; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_7);
__Pyx_GOTREF(__pyx_t_9);
- /* "src/lxml/lxml.etree.pyx":2430
+ /* "src/lxml/lxml.etree.pyx":2439
* other = dict(other)
* except (TypeError, ValueError):
* return NotImplemented # <<<<<<<<<<<<<<
__pyx_L10_try_end:;
}
- /* "src/lxml/lxml.etree.pyx":2431
+ /* "src/lxml/lxml.etree.pyx":2440
* except (TypeError, ValueError):
* return NotImplemented
* return python.PyObject_RichCompare(one, other, op) # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_9 = PyObject_RichCompare(__pyx_v_one, __pyx_v_other, __pyx_v_op); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2431; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyObject_RichCompare(__pyx_v_one, __pyx_v_other, __pyx_v_op); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2440; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__pyx_r = __pyx_t_9;
__pyx_t_9 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2423
+ /* "src/lxml/lxml.etree.pyx":2432
* return 1 if tree.xmlHasNsProp(c_node, _xcstr(tag), c_href) else 0
*
* def __richcmp__(one, other, int op): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2443
+/* "src/lxml/lxml.etree.pyx":2452
* cdef xmlAttr* _c_attr
* cdef int _keysvalues # 1 - keys, 2 - values, 3 - items (key, value)
* def __iter__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__iter__", 0);
- /* "src/lxml/lxml.etree.pyx":2444
+ /* "src/lxml/lxml.etree.pyx":2453
* cdef int _keysvalues # 1 - keys, 2 - values, 3 - items (key, value)
* def __iter__(self):
* return self # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2443
+ /* "src/lxml/lxml.etree.pyx":2452
* cdef xmlAttr* _c_attr
* cdef int _keysvalues # 1 - keys, 2 - values, 3 - items (key, value)
* def __iter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2446
+/* "src/lxml/lxml.etree.pyx":2455
* return self
*
* def __next__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__next__", 0);
- /* "src/lxml/lxml.etree.pyx":2448
+ /* "src/lxml/lxml.etree.pyx":2457
* def __next__(self):
* cdef xmlAttr* c_attr
* if self._node is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2449
+ /* "src/lxml/lxml.etree.pyx":2458
* cdef xmlAttr* c_attr
* if self._node is None:
* raise StopIteration # <<<<<<<<<<<<<<
* while c_attr is not NULL and c_attr.type != tree.XML_ATTRIBUTE_NODE:
*/
__Pyx_Raise(__pyx_builtin_StopIteration, 0, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2458; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2450
+ /* "src/lxml/lxml.etree.pyx":2459
* if self._node is None:
* raise StopIteration
* c_attr = self._c_attr # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_self->_c_attr;
__pyx_v_c_attr = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2451
+ /* "src/lxml/lxml.etree.pyx":2460
* raise StopIteration
* c_attr = self._c_attr
* while c_attr is not NULL and c_attr.type != tree.XML_ATTRIBUTE_NODE: # <<<<<<<<<<<<<<
__pyx_L6_bool_binop_done:;
if (!__pyx_t_2) break;
- /* "src/lxml/lxml.etree.pyx":2452
+ /* "src/lxml/lxml.etree.pyx":2461
* c_attr = self._c_attr
* while c_attr is not NULL and c_attr.type != tree.XML_ATTRIBUTE_NODE:
* c_attr = c_attr.next # <<<<<<<<<<<<<<
__pyx_v_c_attr = __pyx_t_3;
}
- /* "src/lxml/lxml.etree.pyx":2453
+ /* "src/lxml/lxml.etree.pyx":2462
* while c_attr is not NULL and c_attr.type != tree.XML_ATTRIBUTE_NODE:
* c_attr = c_attr.next
* if c_attr is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_attr == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2454
+ /* "src/lxml/lxml.etree.pyx":2463
* c_attr = c_attr.next
* if c_attr is NULL:
* self._node = None # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_node));
__pyx_v_self->_node = ((struct LxmlElement *)Py_None);
- /* "src/lxml/lxml.etree.pyx":2455
+ /* "src/lxml/lxml.etree.pyx":2464
* if c_attr is NULL:
* self._node = None
* raise StopIteration # <<<<<<<<<<<<<<
* self._c_attr = c_attr.next
*/
__Pyx_Raise(__pyx_builtin_StopIteration, 0, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2455; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2457
+ /* "src/lxml/lxml.etree.pyx":2466
* raise StopIteration
*
* self._c_attr = c_attr.next # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_c_attr->next;
__pyx_v_self->_c_attr = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2460
+ /* "src/lxml/lxml.etree.pyx":2469
* if self._keysvalues == 1:
* return _namespacedName(<xmlNode*>c_attr)
* elif self._keysvalues == 2: # <<<<<<<<<<<<<<
*/
switch (__pyx_v_self->_keysvalues) {
- /* "src/lxml/lxml.etree.pyx":2458
+ /* "src/lxml/lxml.etree.pyx":2467
*
* self._c_attr = c_attr.next
* if self._keysvalues == 1: # <<<<<<<<<<<<<<
*/
case 1:
- /* "src/lxml/lxml.etree.pyx":2459
+ /* "src/lxml/lxml.etree.pyx":2468
* self._c_attr = c_attr.next
* if self._keysvalues == 1:
* return _namespacedName(<xmlNode*>c_attr) # <<<<<<<<<<<<<<
* return _attributeValue(self._node._c_node, c_attr)
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedName(((xmlNode *)__pyx_v_c_attr)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2459; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedName(((xmlNode *)__pyx_v_c_attr)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
goto __pyx_L0;
break;
- /* "src/lxml/lxml.etree.pyx":2460
+ /* "src/lxml/lxml.etree.pyx":2469
* if self._keysvalues == 1:
* return _namespacedName(<xmlNode*>c_attr)
* elif self._keysvalues == 2: # <<<<<<<<<<<<<<
*/
case 2:
- /* "src/lxml/lxml.etree.pyx":2461
+ /* "src/lxml/lxml.etree.pyx":2470
* return _namespacedName(<xmlNode*>c_attr)
* elif self._keysvalues == 2:
* return _attributeValue(self._node._c_node, c_attr) # <<<<<<<<<<<<<<
* return (_namespacedName(<xmlNode*>c_attr),
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __pyx_f_4lxml_5etree__attributeValue(__pyx_v_self->_node->_c_node, __pyx_v_c_attr); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2461; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__attributeValue(__pyx_v_self->_node->_c_node, __pyx_v_c_attr); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2470; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
break;
default:
- /* "src/lxml/lxml.etree.pyx":2463
+ /* "src/lxml/lxml.etree.pyx":2472
* return _attributeValue(self._node._c_node, c_attr)
* else:
* return (_namespacedName(<xmlNode*>c_attr), # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedName(((xmlNode *)__pyx_v_c_attr)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2463; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__namespacedName(((xmlNode *)__pyx_v_c_attr)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2472; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- /* "src/lxml/lxml.etree.pyx":2464
+ /* "src/lxml/lxml.etree.pyx":2473
* else:
* return (_namespacedName(<xmlNode*>c_attr),
* _attributeValue(self._node._c_node, c_attr)) # <<<<<<<<<<<<<<
*
* cdef object _attributeIteratorFactory(_Element element, int keysvalues):
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__attributeValue(__pyx_v_self->_node->_c_node, __pyx_v_c_attr); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__attributeValue(__pyx_v_self->_node->_c_node, __pyx_v_c_attr); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- /* "src/lxml/lxml.etree.pyx":2463
+ /* "src/lxml/lxml.etree.pyx":2472
* return _attributeValue(self._node._c_node, c_attr)
* else:
* return (_namespacedName(<xmlNode*>c_attr), # <<<<<<<<<<<<<<
* _attributeValue(self._node._c_node, c_attr))
*
*/
- __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2463; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2472; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_4);
__Pyx_GIVEREF(__pyx_t_4);
break;
}
- /* "src/lxml/lxml.etree.pyx":2446
+ /* "src/lxml/lxml.etree.pyx":2455
* return self
*
* def __next__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2466
+/* "src/lxml/lxml.etree.pyx":2475
* _attributeValue(self._node._c_node, c_attr))
*
* cdef object _attributeIteratorFactory(_Element element, int keysvalues): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_attributeIteratorFactory", 0);
- /* "src/lxml/lxml.etree.pyx":2468
+ /* "src/lxml/lxml.etree.pyx":2477
* cdef object _attributeIteratorFactory(_Element element, int keysvalues):
* cdef _AttribIterator attribs
* if element._c_node.properties is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_element->_c_node->properties == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2469
+ /* "src/lxml/lxml.etree.pyx":2478
* cdef _AttribIterator attribs
* if element._c_node.properties is NULL:
* return ITER_EMPTY # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2470
+ /* "src/lxml/lxml.etree.pyx":2479
* if element._c_node.properties is NULL:
* return ITER_EMPTY
* attribs = _AttribIterator() # <<<<<<<<<<<<<<
* attribs._node = element
* attribs._c_attr = element._c_node.properties
*/
- __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__AttribIterator)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2470; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__AttribIterator)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2479; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_v_attribs = ((struct __pyx_obj_4lxml_5etree__AttribIterator *)__pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2471
+ /* "src/lxml/lxml.etree.pyx":2480
* return ITER_EMPTY
* attribs = _AttribIterator()
* attribs._node = element # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_attribs->_node));
__pyx_v_attribs->_node = __pyx_v_element;
- /* "src/lxml/lxml.etree.pyx":2472
+ /* "src/lxml/lxml.etree.pyx":2481
* attribs = _AttribIterator()
* attribs._node = element
* attribs._c_attr = element._c_node.properties # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_element->_c_node->properties;
__pyx_v_attribs->_c_attr = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2473
+ /* "src/lxml/lxml.etree.pyx":2482
* attribs._node = element
* attribs._c_attr = element._c_node.properties
* attribs._keysvalues = keysvalues # <<<<<<<<<<<<<<
*/
__pyx_v_attribs->_keysvalues = __pyx_v_keysvalues;
- /* "src/lxml/lxml.etree.pyx":2474
+ /* "src/lxml/lxml.etree.pyx":2483
* attribs._c_attr = element._c_node.properties
* attribs._keysvalues = keysvalues
* return attribs # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_attribs);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2466
+ /* "src/lxml/lxml.etree.pyx":2475
* _attributeValue(self._node._c_node, c_attr))
*
* cdef object _attributeIteratorFactory(_Element element, int keysvalues): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2486
+/* "src/lxml/lxml.etree.pyx":2495
* cdef char* _href
* cdef char* _name
* cdef _initTagMatch(self, tag): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_initTagMatch", 0);
- /* "src/lxml/lxml.etree.pyx":2487
+ /* "src/lxml/lxml.etree.pyx":2496
* cdef char* _name
* cdef _initTagMatch(self, tag):
* self._href = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_self->_href = NULL;
- /* "src/lxml/lxml.etree.pyx":2488
+ /* "src/lxml/lxml.etree.pyx":2497
* cdef _initTagMatch(self, tag):
* self._href = NULL
* self._name = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_self->_name = NULL;
- /* "src/lxml/lxml.etree.pyx":2489
+ /* "src/lxml/lxml.etree.pyx":2498
* self._href = NULL
* self._name = NULL
* if tag is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2490
+ /* "src/lxml/lxml.etree.pyx":2499
* self._name = NULL
* if tag is None:
* self._node_type = 0 # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2491
+ /* "src/lxml/lxml.etree.pyx":2500
* if tag is None:
* self._node_type = 0
* elif tag is Comment: # <<<<<<<<<<<<<<
* self._node_type = tree.XML_COMMENT_NODE
* elif tag is ProcessingInstruction:
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_Comment); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2491; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_Comment); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2500; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_2 = (__pyx_v_tag == __pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2492
+ /* "src/lxml/lxml.etree.pyx":2501
* self._node_type = 0
* elif tag is Comment:
* self._node_type = tree.XML_COMMENT_NODE # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2493
+ /* "src/lxml/lxml.etree.pyx":2502
* elif tag is Comment:
* self._node_type = tree.XML_COMMENT_NODE
* elif tag is ProcessingInstruction: # <<<<<<<<<<<<<<
* self._node_type = tree.XML_PI_NODE
* elif tag is Entity:
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2502; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_1 = (__pyx_v_tag == __pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2494
+ /* "src/lxml/lxml.etree.pyx":2503
* self._node_type = tree.XML_COMMENT_NODE
* elif tag is ProcessingInstruction:
* self._node_type = tree.XML_PI_NODE # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2495
+ /* "src/lxml/lxml.etree.pyx":2504
* elif tag is ProcessingInstruction:
* self._node_type = tree.XML_PI_NODE
* elif tag is Entity: # <<<<<<<<<<<<<<
* self._node_type = tree.XML_ENTITY_REF_NODE
* elif tag is Element:
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_Entity); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_Entity); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_2 = (__pyx_v_tag == __pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2496
+ /* "src/lxml/lxml.etree.pyx":2505
* self._node_type = tree.XML_PI_NODE
* elif tag is Entity:
* self._node_type = tree.XML_ENTITY_REF_NODE # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2497
+ /* "src/lxml/lxml.etree.pyx":2506
* elif tag is Entity:
* self._node_type = tree.XML_ENTITY_REF_NODE
* elif tag is Element: # <<<<<<<<<<<<<<
* self._node_type = tree.XML_ELEMENT_NODE
* else:
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_Element); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2497; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_Element); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2506; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_1 = (__pyx_v_tag == __pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2498
+ /* "src/lxml/lxml.etree.pyx":2507
* self._node_type = tree.XML_ENTITY_REF_NODE
* elif tag is Element:
* self._node_type = tree.XML_ELEMENT_NODE # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2500
+ /* "src/lxml/lxml.etree.pyx":2509
* self._node_type = tree.XML_ELEMENT_NODE
* else:
* self._node_type = tree.XML_ELEMENT_NODE # <<<<<<<<<<<<<<
*/
__pyx_v_self->_node_type = XML_ELEMENT_NODE;
- /* "src/lxml/lxml.etree.pyx":2501
+ /* "src/lxml/lxml.etree.pyx":2510
* else:
* self._node_type = tree.XML_ELEMENT_NODE
* self._pystrings = _getNsTag(tag) # <<<<<<<<<<<<<<
* if self._pystrings[0] is not None:
* self._href = _cstr(self._pystrings[0])
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_tag); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2501; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_tag); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2510; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_GIVEREF(__pyx_t_3);
__Pyx_GOTREF(__pyx_v_self->_pystrings);
__pyx_v_self->_pystrings = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2502
+ /* "src/lxml/lxml.etree.pyx":2511
* self._node_type = tree.XML_ELEMENT_NODE
* self._pystrings = _getNsTag(tag)
* if self._pystrings[0] is not None: # <<<<<<<<<<<<<<
* self._href = _cstr(self._pystrings[0])
* self._name = _cstr(self._pystrings[1])
*/
- __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_self->_pystrings, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2502; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_self->_pystrings, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2511; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_2 = (__pyx_t_3 != Py_None);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2503
+ /* "src/lxml/lxml.etree.pyx":2512
* self._pystrings = _getNsTag(tag)
* if self._pystrings[0] is not None:
* self._href = _cstr(self._pystrings[0]) # <<<<<<<<<<<<<<
* self._name = _cstr(self._pystrings[1])
* if self._name[0] == c'*' and self._name[1] == c'\0':
*/
- __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_self->_pystrings, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2503; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_self->_pystrings, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2512; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_self->_href = PyBytes_AS_STRING(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
}
__pyx_L4:;
- /* "src/lxml/lxml.etree.pyx":2504
+ /* "src/lxml/lxml.etree.pyx":2513
* if self._pystrings[0] is not None:
* self._href = _cstr(self._pystrings[0])
* self._name = _cstr(self._pystrings[1]) # <<<<<<<<<<<<<<
* if self._name[0] == c'*' and self._name[1] == c'\0':
* self._name = NULL
*/
- __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_self->_pystrings, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2504; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_self->_pystrings, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2513; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_self->_name = PyBytes_AS_STRING(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2505
+ /* "src/lxml/lxml.etree.pyx":2514
* self._href = _cstr(self._pystrings[0])
* self._name = _cstr(self._pystrings[1])
* if self._name[0] == c'*' and self._name[1] == c'\0': # <<<<<<<<<<<<<<
__pyx_L6_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2506
+ /* "src/lxml/lxml.etree.pyx":2515
* self._name = _cstr(self._pystrings[1])
* if self._name[0] == c'*' and self._name[1] == c'\0':
* self._name = NULL # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2486
+ /* "src/lxml/lxml.etree.pyx":2495
* cdef char* _href
* cdef char* _name
* cdef _initTagMatch(self, tag): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2516
+/* "src/lxml/lxml.etree.pyx":2525
* cdef _Element _node
* cdef _node_to_node_function _next_element
* def __iter__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__iter__", 0);
- /* "src/lxml/lxml.etree.pyx":2517
+ /* "src/lxml/lxml.etree.pyx":2526
* cdef _node_to_node_function _next_element
* def __iter__(self):
* return self # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2516
+ /* "src/lxml/lxml.etree.pyx":2525
* cdef _Element _node
* cdef _node_to_node_function _next_element
* def __iter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2519
+/* "src/lxml/lxml.etree.pyx":2528
* return self
*
* cdef void _storeNext(self, _Element node): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_storeNext", 0);
- /* "src/lxml/lxml.etree.pyx":2521
+ /* "src/lxml/lxml.etree.pyx":2530
* cdef void _storeNext(self, _Element node):
* cdef xmlNode* c_node
* c_node = self._next_element(node._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_v_self->_next_element(__pyx_v_node->_c_node);
- /* "src/lxml/lxml.etree.pyx":2522
+ /* "src/lxml/lxml.etree.pyx":2531
* cdef xmlNode* c_node
* c_node = self._next_element(node._c_node)
* while c_node is not NULL and \ # <<<<<<<<<<<<<<
goto __pyx_L5_bool_binop_done;
}
- /* "src/lxml/lxml.etree.pyx":2523
+ /* "src/lxml/lxml.etree.pyx":2532
* c_node = self._next_element(node._c_node)
* while c_node is not NULL and \
* self._node_type != 0 and \ # <<<<<<<<<<<<<<
goto __pyx_L5_bool_binop_done;
}
- /* "src/lxml/lxml.etree.pyx":2524
+ /* "src/lxml/lxml.etree.pyx":2533
* while c_node is not NULL and \
* self._node_type != 0 and \
* (<tree.xmlElementType>self._node_type != c_node.type or # <<<<<<<<<<<<<<
goto __pyx_L5_bool_binop_done;
}
- /* "src/lxml/lxml.etree.pyx":2525
+ /* "src/lxml/lxml.etree.pyx":2534
* self._node_type != 0 and \
* (<tree.xmlElementType>self._node_type != c_node.type or
* not _tagMatches(c_node, <const_xmlChar*>self._href, <const_xmlChar*>self._name)): # <<<<<<<<<<<<<<
__pyx_L5_bool_binop_done:;
if (!__pyx_t_1) break;
- /* "src/lxml/lxml.etree.pyx":2526
+ /* "src/lxml/lxml.etree.pyx":2535
* (<tree.xmlElementType>self._node_type != c_node.type or
* not _tagMatches(c_node, <const_xmlChar*>self._href, <const_xmlChar*>self._name)):
* c_node = self._next_element(c_node) # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_v_self->_next_element(__pyx_v_c_node);
}
- /* "src/lxml/lxml.etree.pyx":2527
+ /* "src/lxml/lxml.etree.pyx":2536
* not _tagMatches(c_node, <const_xmlChar*>self._href, <const_xmlChar*>self._name)):
* c_node = self._next_element(c_node)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2528
+ /* "src/lxml/lxml.etree.pyx":2537
* c_node = self._next_element(c_node)
* if c_node is NULL:
* self._node = None # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2531
+ /* "src/lxml/lxml.etree.pyx":2540
* else:
* # Python ref:
* self._node = _elementFactory(node._doc, c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_3 = ((PyObject *)__pyx_v_node->_doc);
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_3), __pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_3), __pyx_v_c_node)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_GIVEREF(__pyx_t_4);
}
__pyx_L9:;
- /* "src/lxml/lxml.etree.pyx":2519
+ /* "src/lxml/lxml.etree.pyx":2528
* return self
*
* cdef void _storeNext(self, _Element node): # <<<<<<<<<<<<<<
__Pyx_RefNannyFinishContext();
}
-/* "src/lxml/lxml.etree.pyx":2533
+/* "src/lxml/lxml.etree.pyx":2542
* self._node = _elementFactory(node._doc, c_node)
*
* def __next__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__next__", 0);
- /* "src/lxml/lxml.etree.pyx":2536
+ /* "src/lxml/lxml.etree.pyx":2545
* cdef xmlNode* c_node
* cdef _Element current_node
* if self._node is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2537
+ /* "src/lxml/lxml.etree.pyx":2546
* cdef _Element current_node
* if self._node is None:
* raise StopIteration # <<<<<<<<<<<<<<
* current_node = self._node
*/
__Pyx_Raise(__pyx_builtin_StopIteration, 0, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2537; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2546; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2539
+ /* "src/lxml/lxml.etree.pyx":2548
* raise StopIteration
* # Python ref:
* current_node = self._node # <<<<<<<<<<<<<<
__pyx_v_current_node = ((struct LxmlElement *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2540
+ /* "src/lxml/lxml.etree.pyx":2549
* # Python ref:
* current_node = self._node
* self._storeNext(current_node) # <<<<<<<<<<<<<<
*/
((struct __pyx_vtabstruct_4lxml_5etree__ElementIterator *)__pyx_v_self->__pyx_base.__pyx_vtab)->_storeNext(__pyx_v_self, __pyx_v_current_node);
- /* "src/lxml/lxml.etree.pyx":2541
+ /* "src/lxml/lxml.etree.pyx":2550
* current_node = self._node
* self._storeNext(current_node)
* return current_node # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_current_node);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2533
+ /* "src/lxml/lxml.etree.pyx":2542
* self._node = _elementFactory(node._doc, c_node)
*
* def __next__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2556
+/* "src/lxml/lxml.etree.pyx":2565
* cdef int _node_types
*
* def __cinit__(self, tags): # <<<<<<<<<<<<<<
else goto __pyx_L5_argtuple_error;
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2556; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2565; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2556; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2565; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._MultiTagMatcher.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2557
+ /* "src/lxml/lxml.etree.pyx":2566
*
* def __cinit__(self, tags):
* self._cached_tags = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_self->_cached_tags = NULL;
- /* "src/lxml/lxml.etree.pyx":2558
+ /* "src/lxml/lxml.etree.pyx":2567
* def __cinit__(self, tags):
* self._cached_tags = NULL
* self._cached_size = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_cached_size = 0;
- /* "src/lxml/lxml.etree.pyx":2559
+ /* "src/lxml/lxml.etree.pyx":2568
* self._cached_tags = NULL
* self._cached_size = 0
* self._tag_count = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_tag_count = 0;
- /* "src/lxml/lxml.etree.pyx":2560
+ /* "src/lxml/lxml.etree.pyx":2569
* self._cached_size = 0
* self._tag_count = 0
* self._node_types = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_node_types = 0;
- /* "src/lxml/lxml.etree.pyx":2561
+ /* "src/lxml/lxml.etree.pyx":2570
* self._tag_count = 0
* self._node_types = 0
* self._py_tags = [] # <<<<<<<<<<<<<<
* self.initTagMatch(tags)
*
*/
- __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2561; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2570; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_self->_py_tags);
__pyx_v_self->_py_tags = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2562
+ /* "src/lxml/lxml.etree.pyx":2571
* self._node_types = 0
* self._py_tags = []
* self.initTagMatch(tags) # <<<<<<<<<<<<<<
*
* def __dealloc__(self):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_initTagMatch(__pyx_v_self, __pyx_v_tags); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2562; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_initTagMatch(__pyx_v_self, __pyx_v_tags); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2571; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2556
+ /* "src/lxml/lxml.etree.pyx":2565
* cdef int _node_types
*
* def __cinit__(self, tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2564
+/* "src/lxml/lxml.etree.pyx":2573
* self.initTagMatch(tags)
*
* def __dealloc__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__dealloc__", 0);
- /* "src/lxml/lxml.etree.pyx":2565
+ /* "src/lxml/lxml.etree.pyx":2574
*
* def __dealloc__(self):
* self._clear() # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree_16_MultiTagMatcher__clear(__pyx_v_self);
- /* "src/lxml/lxml.etree.pyx":2564
+ /* "src/lxml/lxml.etree.pyx":2573
* self.initTagMatch(tags)
*
* def __dealloc__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyFinishContext();
}
-/* "src/lxml/lxml.etree.pyx":2567
+/* "src/lxml/lxml.etree.pyx":2576
* self._clear()
*
* cdef bint rejectsAll(self): # <<<<<<<<<<<<<<
int __pyx_t_2;
__Pyx_RefNannySetupContext("rejectsAll", 0);
- /* "src/lxml/lxml.etree.pyx":2568
+ /* "src/lxml/lxml.etree.pyx":2577
*
* cdef bint rejectsAll(self):
* return not self._tag_count and not self._node_types # <<<<<<<<<<<<<<
__pyx_r = __pyx_t_1;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2567
+ /* "src/lxml/lxml.etree.pyx":2576
* self._clear()
*
* cdef bint rejectsAll(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2570
+/* "src/lxml/lxml.etree.pyx":2579
* return not self._tag_count and not self._node_types
*
* cdef bint rejectsAllAttributes(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("rejectsAllAttributes", 0);
- /* "src/lxml/lxml.etree.pyx":2571
+ /* "src/lxml/lxml.etree.pyx":2580
*
* cdef bint rejectsAllAttributes(self):
* return not self._tag_count # <<<<<<<<<<<<<<
__pyx_r = (!(__pyx_v_self->_tag_count != 0));
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2570
+ /* "src/lxml/lxml.etree.pyx":2579
* return not self._tag_count and not self._node_types
*
* cdef bint rejectsAllAttributes(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2573
+/* "src/lxml/lxml.etree.pyx":2582
* return not self._tag_count
*
* cdef bint matchesType(self, int node_type): # <<<<<<<<<<<<<<
int __pyx_t_2;
__Pyx_RefNannySetupContext("matchesType", 0);
- /* "src/lxml/lxml.etree.pyx":2574
+ /* "src/lxml/lxml.etree.pyx":2583
*
* cdef bint matchesType(self, int node_type):
* if node_type == tree.XML_ELEMENT_NODE and self._tag_count: # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2575
+ /* "src/lxml/lxml.etree.pyx":2584
* cdef bint matchesType(self, int node_type):
* if node_type == tree.XML_ELEMENT_NODE and self._tag_count:
* return True # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2576
+ /* "src/lxml/lxml.etree.pyx":2585
* if node_type == tree.XML_ELEMENT_NODE and self._tag_count:
* return True
* return self._node_types & (1 << node_type) # <<<<<<<<<<<<<<
__pyx_r = (__pyx_v_self->_node_types & (1 << __pyx_v_node_type));
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2573
+ /* "src/lxml/lxml.etree.pyx":2582
* return not self._tag_count
*
* cdef bint matchesType(self, int node_type): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2578
+/* "src/lxml/lxml.etree.pyx":2587
* return self._node_types & (1 << node_type)
*
* cdef void _clear(self): # <<<<<<<<<<<<<<
size_t __pyx_t_3;
__Pyx_RefNannySetupContext("_clear", 0);
- /* "src/lxml/lxml.etree.pyx":2580
+ /* "src/lxml/lxml.etree.pyx":2589
* cdef void _clear(self):
* cdef size_t i, count
* count = self._tag_count # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_self->_tag_count;
__pyx_v_count = __pyx_t_1;
- /* "src/lxml/lxml.etree.pyx":2581
+ /* "src/lxml/lxml.etree.pyx":2590
* cdef size_t i, count
* count = self._tag_count
* self._tag_count = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_tag_count = 0;
- /* "src/lxml/lxml.etree.pyx":2582
+ /* "src/lxml/lxml.etree.pyx":2591
* count = self._tag_count
* self._tag_count = 0
* if self._cached_tags: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_v_self->_cached_tags != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2583
+ /* "src/lxml/lxml.etree.pyx":2592
* self._tag_count = 0
* if self._cached_tags:
* for i in xrange(count): # <<<<<<<<<<<<<<
for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_1; __pyx_t_3+=1) {
__pyx_v_i = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2584
+ /* "src/lxml/lxml.etree.pyx":2593
* if self._cached_tags:
* for i in xrange(count):
* cpython.ref.Py_XDECREF(self._cached_tags[i].href) # <<<<<<<<<<<<<<
Py_XDECREF((__pyx_v_self->_cached_tags[__pyx_v_i]).href);
}
- /* "src/lxml/lxml.etree.pyx":2585
+ /* "src/lxml/lxml.etree.pyx":2594
* for i in xrange(count):
* cpython.ref.Py_XDECREF(self._cached_tags[i].href)
* cpython.mem.PyMem_Free(self._cached_tags) # <<<<<<<<<<<<<<
*/
PyMem_Free(__pyx_v_self->_cached_tags);
- /* "src/lxml/lxml.etree.pyx":2586
+ /* "src/lxml/lxml.etree.pyx":2595
* cpython.ref.Py_XDECREF(self._cached_tags[i].href)
* cpython.mem.PyMem_Free(self._cached_tags)
* self._cached_tags = NULL # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2578
+ /* "src/lxml/lxml.etree.pyx":2587
* return self._node_types & (1 << node_type)
*
* cdef void _clear(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyFinishContext();
}
-/* "src/lxml/lxml.etree.pyx":2588
+/* "src/lxml/lxml.etree.pyx":2597
* self._cached_tags = NULL
*
* cdef initTagMatch(self, tags): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("initTagMatch", 0);
- /* "src/lxml/lxml.etree.pyx":2589
+ /* "src/lxml/lxml.etree.pyx":2598
*
* cdef initTagMatch(self, tags):
* self._cached_doc = None # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_cached_doc));
__pyx_v_self->_cached_doc = ((struct LxmlDocument *)Py_None);
- /* "src/lxml/lxml.etree.pyx":2590
+ /* "src/lxml/lxml.etree.pyx":2599
* cdef initTagMatch(self, tags):
* self._cached_doc = None
* del self._py_tags[:] # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_self->_py_tags == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2590; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2599; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- if (__Pyx_PyObject_DelSlice(__pyx_v_self->_py_tags, 0, 0, NULL, NULL, NULL, 0, 0, 1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2590; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_PyObject_DelSlice(__pyx_v_self->_py_tags, 0, 0, NULL, NULL, NULL, 0, 0, 1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2599; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2591
+ /* "src/lxml/lxml.etree.pyx":2600
* self._cached_doc = None
* del self._py_tags[:]
* self._clear() # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree_16_MultiTagMatcher__clear(__pyx_v_self);
- /* "src/lxml/lxml.etree.pyx":2592
+ /* "src/lxml/lxml.etree.pyx":2601
* del self._py_tags[:]
* self._clear()
* if tags is None or tags == (): # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_t_3;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_tags, __pyx_empty_tuple, Py_EQ); __Pyx_XGOTREF(__pyx_t_4); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2592; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_tags, __pyx_empty_tuple, Py_EQ); __Pyx_XGOTREF(__pyx_t_4); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_t_1 = __pyx_t_3;
__pyx_L4_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2594
+ /* "src/lxml/lxml.etree.pyx":2603
* if tags is None or tags == ():
* # no selection in tags argument => match anything
* self._node_types = ( # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2600
+ /* "src/lxml/lxml.etree.pyx":2609
* 1 << tree.XML_ELEMENT_NODE)
* else:
* self._node_types = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_node_types = 0;
- /* "src/lxml/lxml.etree.pyx":2601
+ /* "src/lxml/lxml.etree.pyx":2610
* else:
* self._node_types = 0
* self._storeTags(tags, set()) # <<<<<<<<<<<<<<
*
* cdef _storeTags(self, tag, set seen):
*/
- __pyx_t_4 = PySet_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PySet_New(0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = __pyx_f_4lxml_5etree_16_MultiTagMatcher__storeTags(__pyx_v_self, __pyx_v_tags, ((PyObject*)__pyx_t_4)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_16_MultiTagMatcher__storeTags(__pyx_v_self, __pyx_v_tags, ((PyObject*)__pyx_t_4)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2588
+ /* "src/lxml/lxml.etree.pyx":2597
* self._cached_tags = NULL
*
* cdef initTagMatch(self, tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2603
+/* "src/lxml/lxml.etree.pyx":2612
* self._storeTags(tags, set())
*
* cdef _storeTags(self, tag, set seen): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_storeTags", 0);
- /* "src/lxml/lxml.etree.pyx":2604
+ /* "src/lxml/lxml.etree.pyx":2613
*
* cdef _storeTags(self, tag, set seen):
* if tag is Comment: # <<<<<<<<<<<<<<
* self._node_types |= 1 << tree.XML_COMMENT_NODE
* elif tag is ProcessingInstruction:
*/
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Comment); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2604; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Comment); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2613; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_t_2 = (__pyx_v_tag == __pyx_t_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2605
+ /* "src/lxml/lxml.etree.pyx":2614
* cdef _storeTags(self, tag, set seen):
* if tag is Comment:
* self._node_types |= 1 << tree.XML_COMMENT_NODE # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2606
+ /* "src/lxml/lxml.etree.pyx":2615
* if tag is Comment:
* self._node_types |= 1 << tree.XML_COMMENT_NODE
* elif tag is ProcessingInstruction: # <<<<<<<<<<<<<<
* self._node_types |= 1 << tree.XML_PI_NODE
* elif tag is Entity:
*/
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2606; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_t_3 = (__pyx_v_tag == __pyx_t_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2607
+ /* "src/lxml/lxml.etree.pyx":2616
* self._node_types |= 1 << tree.XML_COMMENT_NODE
* elif tag is ProcessingInstruction:
* self._node_types |= 1 << tree.XML_PI_NODE # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2608
+ /* "src/lxml/lxml.etree.pyx":2617
* elif tag is ProcessingInstruction:
* self._node_types |= 1 << tree.XML_PI_NODE
* elif tag is Entity: # <<<<<<<<<<<<<<
* self._node_types |= 1 << tree.XML_ENTITY_REF_NODE
* elif tag is Element:
*/
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Entity); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2608; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Entity); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2617; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_t_2 = (__pyx_v_tag == __pyx_t_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2609
+ /* "src/lxml/lxml.etree.pyx":2618
* self._node_types |= 1 << tree.XML_PI_NODE
* elif tag is Entity:
* self._node_types |= 1 << tree.XML_ENTITY_REF_NODE # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2610
+ /* "src/lxml/lxml.etree.pyx":2619
* elif tag is Entity:
* self._node_types |= 1 << tree.XML_ENTITY_REF_NODE
* elif tag is Element: # <<<<<<<<<<<<<<
* self._node_types |= 1 << tree.XML_ELEMENT_NODE
* elif python._isString(tag):
*/
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Element); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Element); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_t_3 = (__pyx_v_tag == __pyx_t_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2611
+ /* "src/lxml/lxml.etree.pyx":2620
* self._node_types |= 1 << tree.XML_ENTITY_REF_NODE
* elif tag is Element:
* self._node_types |= 1 << tree.XML_ELEMENT_NODE # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2612
+ /* "src/lxml/lxml.etree.pyx":2621
* elif tag is Element:
* self._node_types |= 1 << tree.XML_ELEMENT_NODE
* elif python._isString(tag): # <<<<<<<<<<<<<<
__pyx_t_2 = (_isString(__pyx_v_tag) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2613
+ /* "src/lxml/lxml.etree.pyx":2622
* self._node_types |= 1 << tree.XML_ELEMENT_NODE
* elif python._isString(tag):
* if tag in seen: # <<<<<<<<<<<<<<
* return
* seen.add(tag)
*/
- __pyx_t_2 = (__Pyx_PySequence_Contains(__pyx_v_tag, __pyx_v_seen, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2613; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PySequence_Contains(__pyx_v_tag, __pyx_v_seen, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2622; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2614
+ /* "src/lxml/lxml.etree.pyx":2623
* elif python._isString(tag):
* if tag in seen:
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2615
+ /* "src/lxml/lxml.etree.pyx":2624
* if tag in seen:
* return
* seen.add(tag) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_seen == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "add");
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2624; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_4 = PySet_Add(__pyx_v_seen, __pyx_v_tag); if (unlikely(__pyx_t_4 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PySet_Add(__pyx_v_seen, __pyx_v_tag); if (unlikely(__pyx_t_4 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2624; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2616
+ /* "src/lxml/lxml.etree.pyx":2625
* return
* seen.add(tag)
* if tag in ('*', '{*}*'): # <<<<<<<<<<<<<<
*/
__Pyx_INCREF(__pyx_v_tag);
__pyx_t_1 = __pyx_v_tag;
- __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_t_1, __pyx_kp_s__35, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_t_1, __pyx_kp_s__36, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2625; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (!__pyx_t_2) {
} else {
__pyx_t_3 = __pyx_t_2;
goto __pyx_L6_bool_binop_done;
}
- __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_t_1, __pyx_kp_s__36, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_t_1, __pyx_kp_s__37, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2625; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = __pyx_t_2;
__pyx_L6_bool_binop_done:;
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2617
+ /* "src/lxml/lxml.etree.pyx":2626
* seen.add(tag)
* if tag in ('*', '{*}*'):
* self._node_types |= 1 << tree.XML_ELEMENT_NODE # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2619
+ /* "src/lxml/lxml.etree.pyx":2628
* self._node_types |= 1 << tree.XML_ELEMENT_NODE
* else:
* href, name = _getNsTag(tag) # <<<<<<<<<<<<<<
* if name == b'*':
* name = None
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_tag); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_tag); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
if (likely(__pyx_t_1 != Py_None)) {
PyObject* sequence = __pyx_t_1;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
__pyx_t_5 = PyTuple_GET_ITEM(sequence, 0);
__Pyx_INCREF(__pyx_t_5);
__Pyx_INCREF(__pyx_t_6);
#else
- __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
#endif
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
} else {
- __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2619; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2628; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_v_href = __pyx_t_5;
__pyx_t_5 = 0;
__pyx_v_name = __pyx_t_6;
__pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":2620
+ /* "src/lxml/lxml.etree.pyx":2629
* else:
* href, name = _getNsTag(tag)
* if name == b'*': # <<<<<<<<<<<<<<
* name = None
* if href is None:
*/
- __pyx_t_2 = (__Pyx_PyBytes_Equals(__pyx_v_name, __pyx_kp_b__35, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2620; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyBytes_Equals(__pyx_v_name, __pyx_kp_b__36, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2621
+ /* "src/lxml/lxml.etree.pyx":2630
* href, name = _getNsTag(tag)
* if name == b'*':
* name = None # <<<<<<<<<<<<<<
}
__pyx_L8:;
- /* "src/lxml/lxml.etree.pyx":2622
+ /* "src/lxml/lxml.etree.pyx":2631
* if name == b'*':
* name = None
* if href is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2623
+ /* "src/lxml/lxml.etree.pyx":2632
* name = None
* if href is None:
* href = b'' # no namespace # <<<<<<<<<<<<<<
goto __pyx_L9;
}
- /* "src/lxml/lxml.etree.pyx":2624
+ /* "src/lxml/lxml.etree.pyx":2633
* if href is None:
* href = b'' # no namespace
* elif href == b'*': # <<<<<<<<<<<<<<
* href = None # wildcard: any namespace, including none
* self._py_tags.append((href, name))
*/
- __pyx_t_3 = (__Pyx_PyBytes_Equals(__pyx_v_href, __pyx_kp_b__35, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2624; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = (__Pyx_PyBytes_Equals(__pyx_v_href, __pyx_kp_b__36, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2625
+ /* "src/lxml/lxml.etree.pyx":2634
* href = b'' # no namespace
* elif href == b'*':
* href = None # wildcard: any namespace, including none # <<<<<<<<<<<<<<
}
__pyx_L9:;
- /* "src/lxml/lxml.etree.pyx":2626
+ /* "src/lxml/lxml.etree.pyx":2635
* elif href == b'*':
* href = None # wildcard: any namespace, including none
* self._py_tags.append((href, name)) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_self->_py_tags == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "append");
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2626; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2626; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(__pyx_v_href);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_href);
__Pyx_INCREF(__pyx_v_name);
PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_name);
__Pyx_GIVEREF(__pyx_v_name);
- __pyx_t_4 = __Pyx_PyList_Append(__pyx_v_self->_py_tags, __pyx_t_1); if (unlikely(__pyx_t_4 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2626; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyList_Append(__pyx_v_self->_py_tags, __pyx_t_1); if (unlikely(__pyx_t_4 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2635; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
}
__pyx_L5:;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2629
+ /* "src/lxml/lxml.etree.pyx":2638
* else:
* # support a sequence of tags
* for item in tag: # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_tag; __Pyx_INCREF(__pyx_t_1); __pyx_t_7 = 0;
__pyx_t_8 = NULL;
} else {
- __pyx_t_7 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_tag); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_tag); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2638; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_8 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2638; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
for (;;) {
if (likely(!__pyx_t_8)) {
if (likely(PyList_CheckExact(__pyx_t_1))) {
if (__pyx_t_7 >= PyList_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_6); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_6); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2638; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2638; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
} else {
if (__pyx_t_7 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_6 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_6); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_6); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2638; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2638; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
}
} else {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2629; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2638; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
break;
}
__Pyx_XDECREF_SET(__pyx_v_item, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":2630
+ /* "src/lxml/lxml.etree.pyx":2639
* # support a sequence of tags
* for item in tag:
* self._storeTags(item, seen) # <<<<<<<<<<<<<<
*
* cdef inline int cacheTags(self, _Document doc, bint force_into_dict=False) except -1:
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree_16_MultiTagMatcher__storeTags(__pyx_v_self, __pyx_v_item, __pyx_v_seen); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2630; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree_16_MultiTagMatcher__storeTags(__pyx_v_self, __pyx_v_item, __pyx_v_seen); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2639; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/lxml.etree.pyx":2629
+ /* "src/lxml/lxml.etree.pyx":2638
* else:
* # support a sequence of tags
* for item in tag: # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2603
+ /* "src/lxml/lxml.etree.pyx":2612
* self._storeTags(tags, set())
*
* cdef _storeTags(self, tag, set seen): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2632
+/* "src/lxml/lxml.etree.pyx":2641
* self._storeTags(item, seen)
*
* cdef inline int cacheTags(self, _Document doc, bint force_into_dict=False) except -1: # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/lxml.etree.pyx":2636
+ /* "src/lxml/lxml.etree.pyx":2645
* Look up the tag names in the doc dict to enable string pointer comparisons.
* """
* cdef size_t dict_size = tree.xmlDictSize(doc._c_doc.dict) # <<<<<<<<<<<<<<
*/
__pyx_v_dict_size = xmlDictSize(__pyx_v_doc->_c_doc->dict);
- /* "src/lxml/lxml.etree.pyx":2637
+ /* "src/lxml/lxml.etree.pyx":2646
* """
* cdef size_t dict_size = tree.xmlDictSize(doc._c_doc.dict)
* if doc is self._cached_doc and dict_size == self._cached_size: # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2639
+ /* "src/lxml/lxml.etree.pyx":2648
* if doc is self._cached_doc and dict_size == self._cached_size:
* # doc and dict didn't change => names already cached
* return 0 # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2640
+ /* "src/lxml/lxml.etree.pyx":2649
* # doc and dict didn't change => names already cached
* return 0
* self._tag_count = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_tag_count = 0;
- /* "src/lxml/lxml.etree.pyx":2641
+ /* "src/lxml/lxml.etree.pyx":2650
* return 0
* self._tag_count = 0
* if not self._py_tags: # <<<<<<<<<<<<<<
__pyx_t_3 = ((!__pyx_t_1) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2642
+ /* "src/lxml/lxml.etree.pyx":2651
* self._tag_count = 0
* if not self._py_tags:
* self._cached_doc = doc # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_cached_doc));
__pyx_v_self->_cached_doc = __pyx_v_doc;
- /* "src/lxml/lxml.etree.pyx":2643
+ /* "src/lxml/lxml.etree.pyx":2652
* if not self._py_tags:
* self._cached_doc = doc
* self._cached_size = dict_size # <<<<<<<<<<<<<<
*/
__pyx_v_self->_cached_size = __pyx_v_dict_size;
- /* "src/lxml/lxml.etree.pyx":2644
+ /* "src/lxml/lxml.etree.pyx":2653
* self._cached_doc = doc
* self._cached_size = dict_size
* return 0 # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2645
+ /* "src/lxml/lxml.etree.pyx":2654
* self._cached_size = dict_size
* return 0
* if not self._cached_tags: # <<<<<<<<<<<<<<
__pyx_t_3 = ((!(__pyx_v_self->_cached_tags != 0)) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2646
+ /* "src/lxml/lxml.etree.pyx":2655
* return 0
* if not self._cached_tags:
* self._cached_tags = <qname*>cpython.mem.PyMem_Malloc(len(self._py_tags) * sizeof(qname)) # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_t_4);
if (unlikely(__pyx_t_4 == Py_None)) {
PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2646; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_5 = PyList_GET_SIZE(__pyx_t_4); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2646; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyList_GET_SIZE(__pyx_t_4); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_v_self->_cached_tags = ((struct __pyx_t_4lxml_5etree_qname *)PyMem_Malloc((__pyx_t_5 * (sizeof(struct __pyx_t_4lxml_5etree_qname)))));
- /* "src/lxml/lxml.etree.pyx":2647
+ /* "src/lxml/lxml.etree.pyx":2656
* if not self._cached_tags:
* self._cached_tags = <qname*>cpython.mem.PyMem_Malloc(len(self._py_tags) * sizeof(qname))
* if not self._cached_tags: # <<<<<<<<<<<<<<
__pyx_t_3 = ((!(__pyx_v_self->_cached_tags != 0)) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2648
+ /* "src/lxml/lxml.etree.pyx":2657
* self._cached_tags = <qname*>cpython.mem.PyMem_Malloc(len(self._py_tags) * sizeof(qname))
* if not self._cached_tags:
* self._cached_doc = None # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_cached_doc));
__pyx_v_self->_cached_doc = ((struct LxmlDocument *)Py_None);
- /* "src/lxml/lxml.etree.pyx":2649
+ /* "src/lxml/lxml.etree.pyx":2658
* if not self._cached_tags:
* self._cached_doc = None
* raise MemoryError() # <<<<<<<<<<<<<<
* self._tag_count = <size_t>_mapTagsToQnameMatchArray(
* doc._c_doc, self._py_tags, self._cached_tags, force_into_dict)
*/
- PyErr_NoMemory(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2649; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyErr_NoMemory(); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2658; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L7;
}
__pyx_L7:;
- /* "src/lxml/lxml.etree.pyx":2651
+ /* "src/lxml/lxml.etree.pyx":2660
* raise MemoryError()
* self._tag_count = <size_t>_mapTagsToQnameMatchArray(
* doc._c_doc, self._py_tags, self._cached_tags, force_into_dict) # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_self->_py_tags;
__Pyx_INCREF(__pyx_t_4);
- /* "src/lxml/lxml.etree.pyx":2650
+ /* "src/lxml/lxml.etree.pyx":2659
* self._cached_doc = None
* raise MemoryError()
* self._tag_count = <size_t>_mapTagsToQnameMatchArray( # <<<<<<<<<<<<<<
* doc._c_doc, self._py_tags, self._cached_tags, force_into_dict)
* self._cached_doc = doc
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__mapTagsToQnameMatchArray(__pyx_v_doc->_c_doc, ((PyObject*)__pyx_t_4), __pyx_v_self->_cached_tags, __pyx_v_force_into_dict); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2650; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__mapTagsToQnameMatchArray(__pyx_v_doc->_c_doc, ((PyObject*)__pyx_t_4), __pyx_v_self->_cached_tags, __pyx_v_force_into_dict); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2659; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_v_self->_tag_count = ((size_t)__pyx_t_5);
- /* "src/lxml/lxml.etree.pyx":2652
+ /* "src/lxml/lxml.etree.pyx":2661
* self._tag_count = <size_t>_mapTagsToQnameMatchArray(
* doc._c_doc, self._py_tags, self._cached_tags, force_into_dict)
* self._cached_doc = doc # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_cached_doc));
__pyx_v_self->_cached_doc = __pyx_v_doc;
- /* "src/lxml/lxml.etree.pyx":2653
+ /* "src/lxml/lxml.etree.pyx":2662
* doc._c_doc, self._py_tags, self._cached_tags, force_into_dict)
* self._cached_doc = doc
* self._cached_size = dict_size # <<<<<<<<<<<<<<
*/
__pyx_v_self->_cached_size = __pyx_v_dict_size;
- /* "src/lxml/lxml.etree.pyx":2654
+ /* "src/lxml/lxml.etree.pyx":2663
* self._cached_doc = doc
* self._cached_size = dict_size
* return 0 # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2632
+ /* "src/lxml/lxml.etree.pyx":2641
* self._storeTags(item, seen)
*
* cdef inline int cacheTags(self, _Document doc, bint force_into_dict=False) except -1: # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2656
+/* "src/lxml/lxml.etree.pyx":2665
* return 0
*
* cdef inline bint matches(self, xmlNode* c_node): # <<<<<<<<<<<<<<
struct __pyx_t_4lxml_5etree_qname *__pyx_t_4;
__Pyx_RefNannySetupContext("matches", 0);
- /* "src/lxml/lxml.etree.pyx":2658
+ /* "src/lxml/lxml.etree.pyx":2667
* cdef inline bint matches(self, xmlNode* c_node):
* cdef qname* c_qname
* if self._node_types & (1 << c_node.type): # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_node_types & (1 << __pyx_v_c_node->type)) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2659
+ /* "src/lxml/lxml.etree.pyx":2668
* cdef qname* c_qname
* if self._node_types & (1 << c_node.type):
* return True # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2660
+ /* "src/lxml/lxml.etree.pyx":2669
* if self._node_types & (1 << c_node.type):
* return True
* elif c_node.type == tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_node->type == XML_ELEMENT_NODE) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2661
+ /* "src/lxml/lxml.etree.pyx":2670
* return True
* elif c_node.type == tree.XML_ELEMENT_NODE:
* for c_qname in self._cached_tags[:self._tag_count]: # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_t_4;
__pyx_v_c_qname = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":2662
+ /* "src/lxml/lxml.etree.pyx":2671
* elif c_node.type == tree.XML_ELEMENT_NODE:
* for c_qname in self._cached_tags[:self._tag_count]:
* if _tagMatchesExactly(c_node, c_qname): # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_f_4lxml_5etree__tagMatchesExactly(__pyx_v_c_node, __pyx_v_c_qname) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2663
+ /* "src/lxml/lxml.etree.pyx":2672
* for c_qname in self._cached_tags[:self._tag_count]:
* if _tagMatchesExactly(c_node, c_qname):
* return True # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2664
+ /* "src/lxml/lxml.etree.pyx":2673
* if _tagMatchesExactly(c_node, c_qname):
* return True
* return False # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2656
+ /* "src/lxml/lxml.etree.pyx":2665
* return 0
*
* cdef inline bint matches(self, xmlNode* c_node): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2666
+/* "src/lxml/lxml.etree.pyx":2675
* return False
*
* cdef inline bint matchesNsTag(self, const_xmlChar* c_href, # <<<<<<<<<<<<<<
struct __pyx_t_4lxml_5etree_qname *__pyx_t_4;
__Pyx_RefNannySetupContext("matchesNsTag", 0);
- /* "src/lxml/lxml.etree.pyx":2669
+ /* "src/lxml/lxml.etree.pyx":2678
* const_xmlChar* c_name):
* cdef qname* c_qname
* if self._node_types & (1 << tree.XML_ELEMENT_NODE): # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_node_types & (1 << XML_ELEMENT_NODE)) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2670
+ /* "src/lxml/lxml.etree.pyx":2679
* cdef qname* c_qname
* if self._node_types & (1 << tree.XML_ELEMENT_NODE):
* return True # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2671
+ /* "src/lxml/lxml.etree.pyx":2680
* if self._node_types & (1 << tree.XML_ELEMENT_NODE):
* return True
* for c_qname in self._cached_tags[:self._tag_count]: # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_t_4;
__pyx_v_c_qname = __pyx_t_2;
- /* "src/lxml/lxml.etree.pyx":2672
+ /* "src/lxml/lxml.etree.pyx":2681
* return True
* for c_qname in self._cached_tags[:self._tag_count]:
* if _nsTagMatchesExactly(c_href, c_name, c_qname): # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_f_4lxml_5etree__nsTagMatchesExactly(__pyx_v_c_href, __pyx_v_c_name, __pyx_v_c_qname) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2673
+ /* "src/lxml/lxml.etree.pyx":2682
* for c_qname in self._cached_tags[:self._tag_count]:
* if _nsTagMatchesExactly(c_href, c_name, c_qname):
* return True # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/lxml.etree.pyx":2674
+ /* "src/lxml/lxml.etree.pyx":2683
* if _nsTagMatchesExactly(c_href, c_name, c_qname):
* return True
* return False # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2666
+ /* "src/lxml/lxml.etree.pyx":2675
* return False
*
* cdef inline bint matchesNsTag(self, const_xmlChar* c_href, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2676
+/* "src/lxml/lxml.etree.pyx":2685
* return False
*
* cdef inline bint matchesAttribute(self, xmlAttr* c_attr): # <<<<<<<<<<<<<<
int __pyx_t_4;
__Pyx_RefNannySetupContext("matchesAttribute", 0);
- /* "src/lxml/lxml.etree.pyx":2681
+ /* "src/lxml/lxml.etree.pyx":2690
* """
* cdef qname* c_qname
* for c_qname in self._cached_tags[:self._tag_count]: # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_t_3;
__pyx_v_c_qname = __pyx_t_1;
- /* "src/lxml/lxml.etree.pyx":2682
+ /* "src/lxml/lxml.etree.pyx":2691
* cdef qname* c_qname
* for c_qname in self._cached_tags[:self._tag_count]:
* if _tagMatchesExactly(<xmlNode*>c_attr, c_qname): # <<<<<<<<<<<<<<
__pyx_t_4 = (__pyx_f_4lxml_5etree__tagMatchesExactly(((xmlNode *)__pyx_v_c_attr), __pyx_v_c_qname) != 0);
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2683
+ /* "src/lxml/lxml.etree.pyx":2692
* for c_qname in self._cached_tags[:self._tag_count]:
* if _tagMatchesExactly(<xmlNode*>c_attr, c_qname):
* return True # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/lxml.etree.pyx":2684
+ /* "src/lxml/lxml.etree.pyx":2693
* if _tagMatchesExactly(<xmlNode*>c_attr, c_qname):
* return True
* return False # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2676
+ /* "src/lxml/lxml.etree.pyx":2685
* return False
*
* cdef inline bint matchesAttribute(self, xmlAttr* c_attr): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2692
+/* "src/lxml/lxml.etree.pyx":2701
*
* @cython.final
* cdef _initTagMatcher(self, tags): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_initTagMatcher", 0);
- /* "src/lxml/lxml.etree.pyx":2693
+ /* "src/lxml/lxml.etree.pyx":2702
* @cython.final
* cdef _initTagMatcher(self, tags):
* self._matcher = _MultiTagMatcher(tags) # <<<<<<<<<<<<<<
*
* def __iter__(self):
*/
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2693; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(__pyx_v_tags);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_tags);
__Pyx_GIVEREF(__pyx_v_tags);
- __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__MultiTagMatcher)), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2693; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__MultiTagMatcher)), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2702; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_GIVEREF(__pyx_t_2);
__pyx_v_self->_matcher = ((struct __pyx_obj_4lxml_5etree__MultiTagMatcher *)__pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2692
+ /* "src/lxml/lxml.etree.pyx":2701
*
* @cython.final
* cdef _initTagMatcher(self, tags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2695
+/* "src/lxml/lxml.etree.pyx":2704
* self._matcher = _MultiTagMatcher(tags)
*
* def __iter__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__iter__", 0);
- /* "src/lxml/lxml.etree.pyx":2696
+ /* "src/lxml/lxml.etree.pyx":2705
*
* def __iter__(self):
* return self # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2695
+ /* "src/lxml/lxml.etree.pyx":2704
* self._matcher = _MultiTagMatcher(tags)
*
* def __iter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2699
+/* "src/lxml/lxml.etree.pyx":2708
*
* @cython.final
* cdef int _storeNext(self, _Element node) except -1: # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_storeNext", 0);
- /* "src/lxml/lxml.etree.pyx":2700
+ /* "src/lxml/lxml.etree.pyx":2709
* @cython.final
* cdef int _storeNext(self, _Element node) except -1:
* self._matcher.cacheTags(node._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_node->_doc);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->_matcher, ((struct LxmlDocument *)__pyx_t_1), NULL); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2700; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->_matcher, ((struct LxmlDocument *)__pyx_t_1), NULL); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2709; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2701
+ /* "src/lxml/lxml.etree.pyx":2710
* cdef int _storeNext(self, _Element node) except -1:
* self._matcher.cacheTags(node._doc)
* c_node = self._next_element(node._c_node) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_v_self->_next_element(__pyx_v_node->_c_node);
- /* "src/lxml/lxml.etree.pyx":2702
+ /* "src/lxml/lxml.etree.pyx":2711
* self._matcher.cacheTags(node._doc)
* c_node = self._next_element(node._c_node)
* while c_node is not NULL and not self._matcher.matches(c_node): # <<<<<<<<<<<<<<
__pyx_L5_bool_binop_done:;
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":2703
+ /* "src/lxml/lxml.etree.pyx":2712
* c_node = self._next_element(node._c_node)
* while c_node is not NULL and not self._matcher.matches(c_node):
* c_node = self._next_element(c_node) # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_v_self->_next_element(__pyx_v_c_node);
}
- /* "src/lxml/lxml.etree.pyx":2705
+ /* "src/lxml/lxml.etree.pyx":2714
* c_node = self._next_element(c_node)
* # store Python ref to next node to make sure it's kept alive
* self._node = _elementFactory(node._doc, c_node) if c_node is not NULL else None # <<<<<<<<<<<<<<
if (((__pyx_v_c_node != NULL) != 0)) {
__pyx_t_5 = ((PyObject *)__pyx_v_node->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_6 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2705; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2714; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_t_1 = __pyx_t_6;
__pyx_v_self->_node = ((struct LxmlElement *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2706
+ /* "src/lxml/lxml.etree.pyx":2715
* # store Python ref to next node to make sure it's kept alive
* self._node = _elementFactory(node._doc, c_node) if c_node is not NULL else None
* return 0 # <<<<<<<<<<<<<<
__pyx_r = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2699
+ /* "src/lxml/lxml.etree.pyx":2708
*
* @cython.final
* cdef int _storeNext(self, _Element node) except -1: # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2708
+/* "src/lxml/lxml.etree.pyx":2717
* return 0
*
* def __next__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__next__", 0);
- /* "src/lxml/lxml.etree.pyx":2709
+ /* "src/lxml/lxml.etree.pyx":2718
*
* def __next__(self):
* cdef _Element current_node = self._node # <<<<<<<<<<<<<<
__pyx_v_current_node = ((struct LxmlElement *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2710
+ /* "src/lxml/lxml.etree.pyx":2719
* def __next__(self):
* cdef _Element current_node = self._node
* if current_node is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2711
+ /* "src/lxml/lxml.etree.pyx":2720
* cdef _Element current_node = self._node
* if current_node is None:
* raise StopIteration # <<<<<<<<<<<<<<
* return current_node
*/
__Pyx_Raise(__pyx_builtin_StopIteration, 0, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2711; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2720; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2712
+ /* "src/lxml/lxml.etree.pyx":2721
* if current_node is None:
* raise StopIteration
* self._storeNext(current_node) # <<<<<<<<<<<<<<
* return current_node
*
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext(__pyx_v_self, __pyx_v_current_node); if (unlikely(__pyx_t_4 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2712; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext(__pyx_v_self, __pyx_v_current_node); if (unlikely(__pyx_t_4 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2721; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2713
+ /* "src/lxml/lxml.etree.pyx":2722
* raise StopIteration
* self._storeNext(current_node)
* return current_node # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_current_node);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2708
+ /* "src/lxml/lxml.etree.pyx":2717
* return 0
*
* def __next__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2719
+/* "src/lxml/lxml.etree.pyx":2728
* Iterates over the children of an element.
* """
* def __cinit__(self, _Element node not None, tag=None, *, bint reversed=False): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2719; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2728; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__pyx_v_node = ((struct LxmlElement *)values[0]);
__pyx_v_tag = values[1];
if (values[2]) {
- __pyx_v_reversed = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_reversed == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2719; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_reversed = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_reversed == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2728; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_reversed = ((int)0);
}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2719; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2728; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.ElementChildIterator.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2719; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2728; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_20ElementChildIterator___cinit__(((struct __pyx_obj_4lxml_5etree_ElementChildIterator *)__pyx_v_self), __pyx_v_node, __pyx_v_tag, __pyx_v_reversed);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2721
+ /* "src/lxml/lxml.etree.pyx":2730
* def __cinit__(self, _Element node not None, tag=None, *, bint reversed=False):
* cdef xmlNode* c_node
* _assertValidNode(node) # <<<<<<<<<<<<<<
* self._initTagMatcher(tag)
* if reversed:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2721; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2730; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2722
+ /* "src/lxml/lxml.etree.pyx":2731
* cdef xmlNode* c_node
* _assertValidNode(node)
* self._initTagMatcher(tag) # <<<<<<<<<<<<<<
* if reversed:
* c_node = _findChildBackwards(node._c_node, 0)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__initTagMatcher(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_tag); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2722; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__initTagMatcher(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_tag); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2723
+ /* "src/lxml/lxml.etree.pyx":2732
* _assertValidNode(node)
* self._initTagMatcher(tag)
* if reversed: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_v_reversed != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2724
+ /* "src/lxml/lxml.etree.pyx":2733
* self._initTagMatcher(tag)
* if reversed:
* c_node = _findChildBackwards(node._c_node, 0) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__findChildBackwards(__pyx_v_node->_c_node, 0);
- /* "src/lxml/lxml.etree.pyx":2725
+ /* "src/lxml/lxml.etree.pyx":2734
* if reversed:
* c_node = _findChildBackwards(node._c_node, 0)
* self._next_element = _previousElement # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2727
+ /* "src/lxml/lxml.etree.pyx":2736
* self._next_element = _previousElement
* else:
* c_node = _findChildForwards(node._c_node, 0) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__findChildForwards(__pyx_v_node->_c_node, 0);
- /* "src/lxml/lxml.etree.pyx":2728
+ /* "src/lxml/lxml.etree.pyx":2737
* else:
* c_node = _findChildForwards(node._c_node, 0)
* self._next_element = _nextElement # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2729
+ /* "src/lxml/lxml.etree.pyx":2738
* c_node = _findChildForwards(node._c_node, 0)
* self._next_element = _nextElement
* self._matcher.cacheTags(node._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_2 = ((PyObject *)__pyx_v_node->_doc);
__Pyx_INCREF(__pyx_t_2);
- __pyx_t_1 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->__pyx_base._matcher, ((struct LxmlDocument *)__pyx_t_2), NULL); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2729; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->__pyx_base._matcher, ((struct LxmlDocument *)__pyx_t_2), NULL); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2738; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2730
+ /* "src/lxml/lxml.etree.pyx":2739
* self._next_element = _nextElement
* self._matcher.cacheTags(node._doc)
* while c_node is not NULL and not self._matcher.matches(c_node): # <<<<<<<<<<<<<<
__pyx_L6_bool_binop_done:;
if (!__pyx_t_3) break;
- /* "src/lxml/lxml.etree.pyx":2731
+ /* "src/lxml/lxml.etree.pyx":2740
* self._matcher.cacheTags(node._doc)
* while c_node is not NULL and not self._matcher.matches(c_node):
* c_node = self._next_element(c_node) # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_v_self->__pyx_base._next_element(__pyx_v_c_node);
}
- /* "src/lxml/lxml.etree.pyx":2733
+ /* "src/lxml/lxml.etree.pyx":2742
* c_node = self._next_element(c_node)
* # store Python ref to next node to make sure it's kept alive
* self._node = _elementFactory(node._doc, c_node) if c_node is not NULL else None # <<<<<<<<<<<<<<
if (((__pyx_v_c_node != NULL) != 0)) {
__pyx_t_5 = ((PyObject *)__pyx_v_node->_doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_6 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_node)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_t_2 = __pyx_t_6;
__pyx_v_self->__pyx_base._node = ((struct LxmlElement *)__pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2719
+ /* "src/lxml/lxml.etree.pyx":2728
* Iterates over the children of an element.
* """
* def __cinit__(self, _Element node not None, tag=None, *, bint reversed=False): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2741
+/* "src/lxml/lxml.etree.pyx":2750
* You can pass the boolean keyword ``preceding`` to specify the direction.
* """
* def __cinit__(self, _Element node not None, tag=None, *, bint preceding=False): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2741; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2750; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__pyx_v_node = ((struct LxmlElement *)values[0]);
__pyx_v_tag = values[1];
if (values[2]) {
- __pyx_v_preceding = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_preceding == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2741; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_preceding = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_preceding == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2750; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_preceding = ((int)0);
}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2741; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2750; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.SiblingsIterator.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2750; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_16SiblingsIterator___cinit__(((struct __pyx_obj_4lxml_5etree_SiblingsIterator *)__pyx_v_self), __pyx_v_node, __pyx_v_tag, __pyx_v_preceding);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2742
+ /* "src/lxml/lxml.etree.pyx":2751
* """
* def __cinit__(self, _Element node not None, tag=None, *, bint preceding=False):
* _assertValidNode(node) # <<<<<<<<<<<<<<
* self._initTagMatcher(tag)
* if preceding:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2743
+ /* "src/lxml/lxml.etree.pyx":2752
* def __cinit__(self, _Element node not None, tag=None, *, bint preceding=False):
* _assertValidNode(node)
* self._initTagMatcher(tag) # <<<<<<<<<<<<<<
* if preceding:
* self._next_element = _previousElement
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__initTagMatcher(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_tag); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__initTagMatcher(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_tag); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2752; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2744
+ /* "src/lxml/lxml.etree.pyx":2753
* _assertValidNode(node)
* self._initTagMatcher(tag)
* if preceding: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_v_preceding != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2745
+ /* "src/lxml/lxml.etree.pyx":2754
* self._initTagMatcher(tag)
* if preceding:
* self._next_element = _previousElement # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2747
+ /* "src/lxml/lxml.etree.pyx":2756
* self._next_element = _previousElement
* else:
* self._next_element = _nextElement # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2748
+ /* "src/lxml/lxml.etree.pyx":2757
* else:
* self._next_element = _nextElement
* self._storeNext(node) # <<<<<<<<<<<<<<
*
* cdef class AncestorsIterator(_ElementMatchIterator):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2757; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2741
+ /* "src/lxml/lxml.etree.pyx":2750
* You can pass the boolean keyword ``preceding`` to specify the direction.
* """
* def __cinit__(self, _Element node not None, tag=None, *, bint preceding=False): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2754
+/* "src/lxml/lxml.etree.pyx":2763
* Iterates over the ancestors of an element (from parent to parent).
* """
* def __cinit__(self, _Element node not None, tag=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2754; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2763; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2754; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2763; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.AncestorsIterator.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2754; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2763; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_17AncestorsIterator___cinit__(((struct __pyx_obj_4lxml_5etree_AncestorsIterator *)__pyx_v_self), __pyx_v_node, __pyx_v_tag);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2755
+ /* "src/lxml/lxml.etree.pyx":2764
* """
* def __cinit__(self, _Element node not None, tag=None):
* _assertValidNode(node) # <<<<<<<<<<<<<<
* self._initTagMatcher(tag)
* self._next_element = _parentElement
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2755; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2764; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2756
+ /* "src/lxml/lxml.etree.pyx":2765
* def __cinit__(self, _Element node not None, tag=None):
* _assertValidNode(node)
* self._initTagMatcher(tag) # <<<<<<<<<<<<<<
* self._next_element = _parentElement
* self._storeNext(node)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__initTagMatcher(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_tag); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2756; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__initTagMatcher(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_tag); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2765; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/lxml.etree.pyx":2757
+ /* "src/lxml/lxml.etree.pyx":2766
* _assertValidNode(node)
* self._initTagMatcher(tag)
* self._next_element = _parentElement # <<<<<<<<<<<<<<
*/
__pyx_v_self->__pyx_base._next_element = __pyx_f_4lxml_5etree__parentElement;
- /* "src/lxml/lxml.etree.pyx":2758
+ /* "src/lxml/lxml.etree.pyx":2767
* self._initTagMatcher(tag)
* self._next_element = _parentElement
* self._storeNext(node) # <<<<<<<<<<<<<<
*
* cdef class ElementDepthFirstIterator:
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2758; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext(((struct __pyx_obj_4lxml_5etree__ElementMatchIterator *)__pyx_v_self), __pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2767; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2754
+ /* "src/lxml/lxml.etree.pyx":2763
* Iterates over the ancestors of an element (from parent to parent).
* """
* def __cinit__(self, _Element node not None, tag=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2785
+/* "src/lxml/lxml.etree.pyx":2794
* cdef _Element _top_node
* cdef _MultiTagMatcher _matcher
* def __cinit__(self, _Element node not None, tag=None, *, bint inclusive=True): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2785; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__pyx_v_node = ((struct LxmlElement *)values[0]);
__pyx_v_tag = values[1];
if (values[2]) {
- __pyx_v_inclusive = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_inclusive == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2785; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_inclusive = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_inclusive == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_inclusive = ((int)1);
}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2785; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2794; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.ElementDepthFirstIterator.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2785; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_node), __pyx_ptype_4lxml_5etree__Element, 0, "node", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_25ElementDepthFirstIterator___cinit__(((struct __pyx_obj_4lxml_5etree_ElementDepthFirstIterator *)__pyx_v_self), __pyx_v_node, __pyx_v_tag, __pyx_v_inclusive);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2786
+ /* "src/lxml/lxml.etree.pyx":2795
* cdef _MultiTagMatcher _matcher
* def __cinit__(self, _Element node not None, tag=None, *, bint inclusive=True):
* _assertValidNode(node) # <<<<<<<<<<<<<<
* self._top_node = node
* self._next_node = node
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2786; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_node); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2795; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2787
+ /* "src/lxml/lxml.etree.pyx":2796
* def __cinit__(self, _Element node not None, tag=None, *, bint inclusive=True):
* _assertValidNode(node)
* self._top_node = node # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_top_node));
__pyx_v_self->_top_node = __pyx_v_node;
- /* "src/lxml/lxml.etree.pyx":2788
+ /* "src/lxml/lxml.etree.pyx":2797
* _assertValidNode(node)
* self._top_node = node
* self._next_node = node # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_next_node));
__pyx_v_self->_next_node = __pyx_v_node;
- /* "src/lxml/lxml.etree.pyx":2789
+ /* "src/lxml/lxml.etree.pyx":2798
* self._top_node = node
* self._next_node = node
* self._matcher = _MultiTagMatcher(tag) # <<<<<<<<<<<<<<
* self._matcher.cacheTags(node._doc)
* if not inclusive or not self._matcher.matches(node._c_node):
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2798; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(__pyx_v_tag);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_tag);
__Pyx_GIVEREF(__pyx_v_tag);
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__MultiTagMatcher)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__MultiTagMatcher)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2798; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_GIVEREF(__pyx_t_3);
__pyx_v_self->_matcher = ((struct __pyx_obj_4lxml_5etree__MultiTagMatcher *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2790
+ /* "src/lxml/lxml.etree.pyx":2799
* self._next_node = node
* self._matcher = _MultiTagMatcher(tag)
* self._matcher.cacheTags(node._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_3 = ((PyObject *)__pyx_v_node->_doc);
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_1 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->_matcher, ((struct LxmlDocument *)__pyx_t_3), NULL); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->_matcher, ((struct LxmlDocument *)__pyx_t_3), NULL); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2799; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2791
+ /* "src/lxml/lxml.etree.pyx":2800
* self._matcher = _MultiTagMatcher(tag)
* self._matcher.cacheTags(node._doc)
* if not inclusive or not self._matcher.matches(node._c_node): # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_4) {
- /* "src/lxml/lxml.etree.pyx":2793
+ /* "src/lxml/lxml.etree.pyx":2802
* if not inclusive or not self._matcher.matches(node._c_node):
* # find start node (this cannot raise StopIteration, self._next_node != None)
* next(self) # <<<<<<<<<<<<<<
*
* def __iter__(self):
*/
- __pyx_t_3 = __Pyx_PyIter_Next(((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyIter_Next(((PyObject *)__pyx_v_self)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
goto __pyx_L3;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2785
+ /* "src/lxml/lxml.etree.pyx":2794
* cdef _Element _top_node
* cdef _MultiTagMatcher _matcher
* def __cinit__(self, _Element node not None, tag=None, *, bint inclusive=True): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2795
+/* "src/lxml/lxml.etree.pyx":2804
* next(self)
*
* def __iter__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__iter__", 0);
- /* "src/lxml/lxml.etree.pyx":2796
+ /* "src/lxml/lxml.etree.pyx":2805
*
* def __iter__(self):
* return self # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2795
+ /* "src/lxml/lxml.etree.pyx":2804
* next(self)
*
* def __iter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2798
+/* "src/lxml/lxml.etree.pyx":2807
* return self
*
* def __next__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__next__", 0);
- /* "src/lxml/lxml.etree.pyx":2800
+ /* "src/lxml/lxml.etree.pyx":2809
* def __next__(self):
* cdef xmlNode* c_node
* cdef _Element current_node = self._next_node # <<<<<<<<<<<<<<
__pyx_v_current_node = ((struct LxmlElement *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2801
+ /* "src/lxml/lxml.etree.pyx":2810
* cdef xmlNode* c_node
* cdef _Element current_node = self._next_node
* if current_node is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2802
+ /* "src/lxml/lxml.etree.pyx":2811
* cdef _Element current_node = self._next_node
* if current_node is None:
* raise StopIteration # <<<<<<<<<<<<<<
* self._matcher.cacheTags(current_node._doc)
*/
__Pyx_Raise(__pyx_builtin_StopIteration, 0, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2811; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":2803
+ /* "src/lxml/lxml.etree.pyx":2812
* if current_node is None:
* raise StopIteration
* c_node = current_node._c_node # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_current_node->_c_node;
__pyx_v_c_node = __pyx_t_4;
- /* "src/lxml/lxml.etree.pyx":2804
+ /* "src/lxml/lxml.etree.pyx":2813
* raise StopIteration
* c_node = current_node._c_node
* self._matcher.cacheTags(current_node._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_current_node->_doc);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_5 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->_matcher, ((struct LxmlDocument *)__pyx_t_1), NULL); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_16_MultiTagMatcher_cacheTags(__pyx_v_self->_matcher, ((struct LxmlDocument *)__pyx_t_1), NULL); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2805
+ /* "src/lxml/lxml.etree.pyx":2814
* c_node = current_node._c_node
* self._matcher.cacheTags(current_node._doc)
* if not self._matcher._tag_count: # <<<<<<<<<<<<<<
__pyx_t_3 = ((!(__pyx_v_self->_matcher->_tag_count != 0)) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2808
+ /* "src/lxml/lxml.etree.pyx":2817
* # no tag name was found in the dict => not in document either
* # try to match by node type
* c_node = self._nextNodeAnyTag(c_node) # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2810
+ /* "src/lxml/lxml.etree.pyx":2819
* c_node = self._nextNodeAnyTag(c_node)
* else:
* c_node = self._nextNodeMatchTag(c_node) # <<<<<<<<<<<<<<
}
__pyx_L4:;
- /* "src/lxml/lxml.etree.pyx":2811
+ /* "src/lxml/lxml.etree.pyx":2820
* else:
* c_node = self._nextNodeMatchTag(c_node)
* if c_node is NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_c_node == NULL) != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2812
+ /* "src/lxml/lxml.etree.pyx":2821
* c_node = self._nextNodeMatchTag(c_node)
* if c_node is NULL:
* self._next_node = None # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2814
+ /* "src/lxml/lxml.etree.pyx":2823
* self._next_node = None
* else:
* self._next_node = _elementFactory(current_node._doc, c_node) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = ((PyObject *)__pyx_v_current_node->_doc);
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_6 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_1), __pyx_v_c_node)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2814; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_1), __pyx_v_c_node)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_GIVEREF(__pyx_t_6);
}
__pyx_L5:;
- /* "src/lxml/lxml.etree.pyx":2815
+ /* "src/lxml/lxml.etree.pyx":2824
* else:
* self._next_node = _elementFactory(current_node._doc, c_node)
* return current_node # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_current_node);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2798
+ /* "src/lxml/lxml.etree.pyx":2807
* return self
*
* def __next__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2818
+/* "src/lxml/lxml.etree.pyx":2827
*
* @cython.final
* cdef xmlNode* _nextNodeAnyTag(self, xmlNode* c_node): # <<<<<<<<<<<<<<
int __pyx_t_2;
__Pyx_RefNannySetupContext("_nextNodeAnyTag", 0);
- /* "src/lxml/lxml.etree.pyx":2819
+ /* "src/lxml/lxml.etree.pyx":2828
* @cython.final
* cdef xmlNode* _nextNodeAnyTag(self, xmlNode* c_node):
* cdef int node_types = self._matcher._node_types # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_self->_matcher->_node_types;
__pyx_v_node_types = __pyx_t_1;
- /* "src/lxml/lxml.etree.pyx":2820
+ /* "src/lxml/lxml.etree.pyx":2829
* cdef xmlNode* _nextNodeAnyTag(self, xmlNode* c_node):
* cdef int node_types = self._matcher._node_types
* if not node_types: # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(__pyx_v_node_types != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2821
+ /* "src/lxml/lxml.etree.pyx":2830
* cdef int node_types = self._matcher._node_types
* if not node_types:
* return NULL # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2822
+ /* "src/lxml/lxml.etree.pyx":2831
* if not node_types:
* return NULL
* tree.BEGIN_FOR_EACH_ELEMENT_FROM(self._top_node._c_node, c_node, 0) # <<<<<<<<<<<<<<
*/
BEGIN_FOR_EACH_ELEMENT_FROM(__pyx_v_self->_top_node->_c_node, __pyx_v_c_node, 0);
- /* "src/lxml/lxml.etree.pyx":2823
+ /* "src/lxml/lxml.etree.pyx":2832
* return NULL
* tree.BEGIN_FOR_EACH_ELEMENT_FROM(self._top_node._c_node, c_node, 0)
* if node_types & (1 << c_node.type): # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_node_types & (1 << __pyx_v_c_node->type)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2824
+ /* "src/lxml/lxml.etree.pyx":2833
* tree.BEGIN_FOR_EACH_ELEMENT_FROM(self._top_node._c_node, c_node, 0)
* if node_types & (1 << c_node.type):
* return c_node # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2825
+ /* "src/lxml/lxml.etree.pyx":2834
* if node_types & (1 << c_node.type):
* return c_node
* tree.END_FOR_EACH_ELEMENT_FROM(c_node) # <<<<<<<<<<<<<<
*/
END_FOR_EACH_ELEMENT_FROM(__pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":2826
+ /* "src/lxml/lxml.etree.pyx":2835
* return c_node
* tree.END_FOR_EACH_ELEMENT_FROM(c_node)
* return NULL # <<<<<<<<<<<<<<
__pyx_r = NULL;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2818
+ /* "src/lxml/lxml.etree.pyx":2827
*
* @cython.final
* cdef xmlNode* _nextNodeAnyTag(self, xmlNode* c_node): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2829
+/* "src/lxml/lxml.etree.pyx":2838
*
* @cython.final
* cdef xmlNode* _nextNodeMatchTag(self, xmlNode* c_node): # <<<<<<<<<<<<<<
int __pyx_t_1;
__Pyx_RefNannySetupContext("_nextNodeMatchTag", 0);
- /* "src/lxml/lxml.etree.pyx":2830
+ /* "src/lxml/lxml.etree.pyx":2839
* @cython.final
* cdef xmlNode* _nextNodeMatchTag(self, xmlNode* c_node):
* tree.BEGIN_FOR_EACH_ELEMENT_FROM(self._top_node._c_node, c_node, 0) # <<<<<<<<<<<<<<
*/
BEGIN_FOR_EACH_ELEMENT_FROM(__pyx_v_self->_top_node->_c_node, __pyx_v_c_node, 0);
- /* "src/lxml/lxml.etree.pyx":2831
+ /* "src/lxml/lxml.etree.pyx":2840
* cdef xmlNode* _nextNodeMatchTag(self, xmlNode* c_node):
* tree.BEGIN_FOR_EACH_ELEMENT_FROM(self._top_node._c_node, c_node, 0)
* if self._matcher.matches(c_node): # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_f_4lxml_5etree_16_MultiTagMatcher_matches(__pyx_v_self->_matcher, __pyx_v_c_node) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2832
+ /* "src/lxml/lxml.etree.pyx":2841
* tree.BEGIN_FOR_EACH_ELEMENT_FROM(self._top_node._c_node, c_node, 0)
* if self._matcher.matches(c_node):
* return c_node # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":2833
+ /* "src/lxml/lxml.etree.pyx":2842
* if self._matcher.matches(c_node):
* return c_node
* tree.END_FOR_EACH_ELEMENT_FROM(c_node) # <<<<<<<<<<<<<<
*/
END_FOR_EACH_ELEMENT_FROM(__pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":2834
+ /* "src/lxml/lxml.etree.pyx":2843
* return c_node
* tree.END_FOR_EACH_ELEMENT_FROM(c_node)
* return NULL # <<<<<<<<<<<<<<
__pyx_r = NULL;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2829
+ /* "src/lxml/lxml.etree.pyx":2838
*
* @cython.final
* cdef xmlNode* _nextNodeMatchTag(self, xmlNode* c_node): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2848
+/* "src/lxml/lxml.etree.pyx":2857
* cdef object _nextEvent
* cdef _Element _start_element
* def __cinit__(self, _Element element not None, tag=None, *, bint with_tail=True): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2848; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2857; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
__pyx_v_element = ((struct LxmlElement *)values[0]);
__pyx_v_tag = values[1];
if (values[2]) {
- __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2848; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2857; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_with_tail = ((int)1);
}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2848; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2857; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.ElementTextIterator.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 0, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_19ElementTextIterator___cinit__(((struct __pyx_obj_4lxml_5etree_ElementTextIterator *)__pyx_v_self), __pyx_v_element, __pyx_v_tag, __pyx_v_with_tail);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2849
+ /* "src/lxml/lxml.etree.pyx":2858
* cdef _Element _start_element
* def __cinit__(self, _Element element not None, tag=None, *, bint with_tail=True):
* _assertValidNode(element) # <<<<<<<<<<<<<<
* if with_tail:
* events = (u"start", u"end")
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(__pyx_v_element); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2858; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2850
+ /* "src/lxml/lxml.etree.pyx":2859
* def __cinit__(self, _Element element not None, tag=None, *, bint with_tail=True):
* _assertValidNode(element)
* if with_tail: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_v_with_tail != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2851
+ /* "src/lxml/lxml.etree.pyx":2860
* _assertValidNode(element)
* if with_tail:
* events = (u"start", u"end") # <<<<<<<<<<<<<<
* else:
* events = (u"start",)
*/
- __Pyx_INCREF(__pyx_tuple__37);
- __pyx_v_events = __pyx_tuple__37;
+ __Pyx_INCREF(__pyx_tuple__38);
+ __pyx_v_events = __pyx_tuple__38;
goto __pyx_L3;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2853
+ /* "src/lxml/lxml.etree.pyx":2862
* events = (u"start", u"end")
* else:
* events = (u"start",) # <<<<<<<<<<<<<<
* self._start_element = element
* self._nextEvent = iterwalk(element, events=events, tag=tag).__next__
*/
- __Pyx_INCREF(__pyx_tuple__38);
- __pyx_v_events = __pyx_tuple__38;
+ __Pyx_INCREF(__pyx_tuple__39);
+ __pyx_v_events = __pyx_tuple__39;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2854
+ /* "src/lxml/lxml.etree.pyx":2863
* else:
* events = (u"start",)
* self._start_element = element # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_start_element));
__pyx_v_self->_start_element = __pyx_v_element;
- /* "src/lxml/lxml.etree.pyx":2855
+ /* "src/lxml/lxml.etree.pyx":2864
* events = (u"start",)
* self._start_element = element
* self._nextEvent = iterwalk(element, events=events, tag=tag).__next__ # <<<<<<<<<<<<<<
*
* def __iter__(self):
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_INCREF(((PyObject *)__pyx_v_element));
PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_v_element));
__Pyx_GIVEREF(((PyObject *)__pyx_v_element));
- __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_events, __pyx_v_events) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_tag, __pyx_v_tag) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_iterwalk)), __pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_events, __pyx_v_events) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_tag, __pyx_v_tag) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_iterwalk)), __pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_next); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_next); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_GIVEREF(__pyx_t_4);
__pyx_v_self->_nextEvent = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":2848
+ /* "src/lxml/lxml.etree.pyx":2857
* cdef object _nextEvent
* cdef _Element _start_element
* def __cinit__(self, _Element element not None, tag=None, *, bint with_tail=True): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2857
+/* "src/lxml/lxml.etree.pyx":2866
* self._nextEvent = iterwalk(element, events=events, tag=tag).__next__
*
* def __iter__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__iter__", 0);
- /* "src/lxml/lxml.etree.pyx":2858
+ /* "src/lxml/lxml.etree.pyx":2867
*
* def __iter__(self):
* return self # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self);
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2857
+ /* "src/lxml/lxml.etree.pyx":2866
* self._nextEvent = iterwalk(element, events=events, tag=tag).__next__
*
* def __iter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2860
+/* "src/lxml/lxml.etree.pyx":2869
* return self
*
* def __next__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__next__", 0);
- /* "src/lxml/lxml.etree.pyx":2862
+ /* "src/lxml/lxml.etree.pyx":2871
* def __next__(self):
* cdef _Element element
* result = None # <<<<<<<<<<<<<<
__Pyx_INCREF(Py_None);
__pyx_v_result = Py_None;
- /* "src/lxml/lxml.etree.pyx":2863
+ /* "src/lxml/lxml.etree.pyx":2872
* cdef _Element element
* result = None
* while result is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (!__pyx_t_2) break;
- /* "src/lxml/lxml.etree.pyx":2864
+ /* "src/lxml/lxml.etree.pyx":2873
* result = None
* while result is None:
* event, element = self._nextEvent() # raises StopIteration # <<<<<<<<<<<<<<
}
}
if (__pyx_t_5) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_4);
__Pyx_INCREF(__pyx_t_5);
#else
- __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
#endif
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_6 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_7 = Py_TYPE(__pyx_t_6)->tp_iternext;
__Pyx_GOTREF(__pyx_t_4);
index = 1; __pyx_t_5 = __pyx_t_7(__pyx_t_6); if (unlikely(!__pyx_t_5)) goto __pyx_L5_unpacking_failed;
__Pyx_GOTREF(__pyx_t_5);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_6), 2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_6), 2) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_7 = NULL;
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
goto __pyx_L6_unpacking_done;
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_t_7 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L6_unpacking_done:;
}
- if (!(likely(((__pyx_t_5) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_5, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_5) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_5, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_XDECREF_SET(__pyx_v_event, __pyx_t_4);
__pyx_t_4 = 0;
__Pyx_XDECREF_SET(__pyx_v_element, ((struct LxmlElement *)__pyx_t_5));
__pyx_t_5 = 0;
- /* "src/lxml/lxml.etree.pyx":2865
+ /* "src/lxml/lxml.etree.pyx":2874
* while result is None:
* event, element = self._nextEvent() # raises StopIteration
* if event == u"start": # <<<<<<<<<<<<<<
* result = element.text
* elif element is not self._start_element:
*/
- __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_v_event, __pyx_n_u_start, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2865; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_v_event, __pyx_n_u_start, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2874; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2866
+ /* "src/lxml/lxml.etree.pyx":2875
* event, element = self._nextEvent() # raises StopIteration
* if event == u"start":
* result = element.text # <<<<<<<<<<<<<<
* elif element is not self._start_element:
* result = element.tail
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_text); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2866; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_text); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2875; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_result, __pyx_t_3);
__pyx_t_3 = 0;
goto __pyx_L7;
}
- /* "src/lxml/lxml.etree.pyx":2867
+ /* "src/lxml/lxml.etree.pyx":2876
* if event == u"start":
* result = element.text
* elif element is not self._start_element: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":2868
+ /* "src/lxml/lxml.etree.pyx":2877
* result = element.text
* elif element is not self._start_element:
* result = element.tail # <<<<<<<<<<<<<<
* return result
*
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_tail); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2868; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_element), __pyx_n_s_tail); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2877; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_result, __pyx_t_3);
__pyx_t_3 = 0;
__pyx_L7:;
}
- /* "src/lxml/lxml.etree.pyx":2869
+ /* "src/lxml/lxml.etree.pyx":2878
* elif element is not self._start_element:
* result = element.tail
* return result # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_result;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2860
+ /* "src/lxml/lxml.etree.pyx":2869
* return self
*
* def __next__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2871
+/* "src/lxml/lxml.etree.pyx":2880
* return result
*
* cdef xmlNode* _createElement(xmlDoc* c_doc, object name_utf) except NULL: # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("_createElement", 0);
- /* "src/lxml/lxml.etree.pyx":2873
+ /* "src/lxml/lxml.etree.pyx":2882
* cdef xmlNode* _createElement(xmlDoc* c_doc, object name_utf) except NULL:
* cdef xmlNode* c_node
* c_node = tree.xmlNewDocNode(c_doc, NULL, _xcstr(name_utf), NULL) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = xmlNewDocNode(__pyx_v_c_doc, NULL, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_name_utf), NULL);
- /* "src/lxml/lxml.etree.pyx":2874
+ /* "src/lxml/lxml.etree.pyx":2883
* cdef xmlNode* c_node
* c_node = tree.xmlNewDocNode(c_doc, NULL, _xcstr(name_utf), NULL)
* return c_node # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_c_node;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2871
+ /* "src/lxml/lxml.etree.pyx":2880
* return result
*
* cdef xmlNode* _createElement(xmlDoc* c_doc, object name_utf) except NULL: # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2876
+/* "src/lxml/lxml.etree.pyx":2885
* return c_node
*
* cdef xmlNode* _createComment(xmlDoc* c_doc, const_xmlChar* text): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("_createComment", 0);
- /* "src/lxml/lxml.etree.pyx":2878
+ /* "src/lxml/lxml.etree.pyx":2887
* cdef xmlNode* _createComment(xmlDoc* c_doc, const_xmlChar* text):
* cdef xmlNode* c_node
* c_node = tree.xmlNewDocComment(c_doc, text) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = xmlNewDocComment(__pyx_v_c_doc, __pyx_v_text);
- /* "src/lxml/lxml.etree.pyx":2879
+ /* "src/lxml/lxml.etree.pyx":2888
* cdef xmlNode* c_node
* c_node = tree.xmlNewDocComment(c_doc, text)
* return c_node # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_c_node;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2876
+ /* "src/lxml/lxml.etree.pyx":2885
* return c_node
*
* cdef xmlNode* _createComment(xmlDoc* c_doc, const_xmlChar* text): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2881
+/* "src/lxml/lxml.etree.pyx":2890
* return c_node
*
* cdef xmlNode* _createPI(xmlDoc* c_doc, const_xmlChar* target, const_xmlChar* text): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("_createPI", 0);
- /* "src/lxml/lxml.etree.pyx":2883
+ /* "src/lxml/lxml.etree.pyx":2892
* cdef xmlNode* _createPI(xmlDoc* c_doc, const_xmlChar* target, const_xmlChar* text):
* cdef xmlNode* c_node
* c_node = tree.xmlNewDocPI(c_doc, target, text) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = xmlNewDocPI(__pyx_v_c_doc, __pyx_v_target, __pyx_v_text);
- /* "src/lxml/lxml.etree.pyx":2884
+ /* "src/lxml/lxml.etree.pyx":2893
* cdef xmlNode* c_node
* c_node = tree.xmlNewDocPI(c_doc, target, text)
* return c_node # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_c_node;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2881
+ /* "src/lxml/lxml.etree.pyx":2890
* return c_node
*
* cdef xmlNode* _createPI(xmlDoc* c_doc, const_xmlChar* target, const_xmlChar* text): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2886
+/* "src/lxml/lxml.etree.pyx":2895
* return c_node
*
* cdef xmlNode* _createEntity(xmlDoc* c_doc, const_xmlChar* name): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("_createEntity", 0);
- /* "src/lxml/lxml.etree.pyx":2888
+ /* "src/lxml/lxml.etree.pyx":2897
* cdef xmlNode* _createEntity(xmlDoc* c_doc, const_xmlChar* name):
* cdef xmlNode* c_node
* c_node = tree.xmlNewReference(c_doc, name) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = xmlNewReference(__pyx_v_c_doc, __pyx_v_name);
- /* "src/lxml/lxml.etree.pyx":2889
+ /* "src/lxml/lxml.etree.pyx":2898
* cdef xmlNode* c_node
* c_node = tree.xmlNewReference(c_doc, name)
* return c_node # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_c_node;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2886
+ /* "src/lxml/lxml.etree.pyx":2895
* return c_node
*
* cdef xmlNode* _createEntity(xmlDoc* c_doc, const_xmlChar* name): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2893
+/* "src/lxml/lxml.etree.pyx":2902
* # module-level API for ElementTree
*
* def Element(_tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "Element") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2893; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "Element") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2902; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("Element", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2893; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Element", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2902; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v__extra); __pyx_v__extra = 0;
__Pyx_AddTraceback("lxml.etree.Element", __pyx_clineno, __pyx_lineno, __pyx_filename);
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("Element", 0);
- /* "src/lxml/lxml.etree.pyx":2903
+ /* "src/lxml/lxml.etree.pyx":2912
* create an Element within a specific document or parser context.
* """
* return _makeElement(_tag, NULL, None, None, None, None, # <<<<<<<<<<<<<<
*/
__Pyx_XDECREF(__pyx_r);
- /* "src/lxml/lxml.etree.pyx":2904
+ /* "src/lxml/lxml.etree.pyx":2913
* """
* return _makeElement(_tag, NULL, None, None, None, None,
* attrib, nsmap, _extra) # <<<<<<<<<<<<<<
*
* def Comment(text=None):
*/
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__makeElement(__pyx_v__tag, NULL, ((struct LxmlDocument *)Py_None), ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None), Py_None, Py_None, __pyx_v_attrib, __pyx_v_nsmap, __pyx_v__extra)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__makeElement(__pyx_v__tag, NULL, ((struct LxmlDocument *)Py_None), ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None), Py_None, Py_None, __pyx_v_attrib, __pyx_v_nsmap, __pyx_v__extra)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2912; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2893
+ /* "src/lxml/lxml.etree.pyx":2902
* # module-level API for ElementTree
*
* def Element(_tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2906
+/* "src/lxml/lxml.etree.pyx":2915
* attrib, nsmap, _extra)
*
* def Comment(text=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "Comment") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2906; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "Comment") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2915; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("Comment", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2906; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Comment", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2915; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.Comment", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("Comment", 0);
__Pyx_INCREF(__pyx_v_text);
- /* "src/lxml/lxml.etree.pyx":2915
+ /* "src/lxml/lxml.etree.pyx":2924
* cdef xmlNode* c_node
* cdef xmlDoc* c_doc
* if text is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2916
+ /* "src/lxml/lxml.etree.pyx":2925
* cdef xmlDoc* c_doc
* if text is None:
* text = b'' # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2918
+ /* "src/lxml/lxml.etree.pyx":2927
* text = b''
* else:
* text = _utf8(text) # <<<<<<<<<<<<<<
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None)
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__utf8(__pyx_v_text); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__utf8(__pyx_v_text); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_text, __pyx_t_3);
__pyx_t_3 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2919
+ /* "src/lxml/lxml.etree.pyx":2928
* else:
* text = _utf8(text)
* c_doc = _newXMLDoc() # <<<<<<<<<<<<<<
* doc = _documentFactory(c_doc, None)
* c_node = _createComment(c_doc, _xcstr(text))
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_4 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_4 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_4;
- /* "src/lxml/lxml.etree.pyx":2920
+ /* "src/lxml/lxml.etree.pyx":2929
* text = _utf8(text)
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None) # <<<<<<<<<<<<<<
* c_node = _createComment(c_doc, _xcstr(text))
* tree.xmlAddChild(<xmlNode*>c_doc, c_node)
*/
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2920; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2929; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":2921
+ /* "src/lxml/lxml.etree.pyx":2930
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None)
* c_node = _createComment(c_doc, _xcstr(text)) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__createComment(__pyx_v_c_doc, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_text));
- /* "src/lxml/lxml.etree.pyx":2922
+ /* "src/lxml/lxml.etree.pyx":2931
* doc = _documentFactory(c_doc, None)
* c_node = _createComment(c_doc, _xcstr(text))
* tree.xmlAddChild(<xmlNode*>c_doc, c_node) # <<<<<<<<<<<<<<
*/
xmlAddChild(((xmlNode *)__pyx_v_c_doc), __pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":2923
+ /* "src/lxml/lxml.etree.pyx":2932
* c_node = _createComment(c_doc, _xcstr(text))
* tree.xmlAddChild(<xmlNode*>c_doc, c_node)
* return _elementFactory(doc, c_node) # <<<<<<<<<<<<<<
* def ProcessingInstruction(target, text=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2932; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2906
+ /* "src/lxml/lxml.etree.pyx":2915
* attrib, nsmap, _extra)
*
* def Comment(text=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2925
+/* "src/lxml/lxml.etree.pyx":2934
* return _elementFactory(doc, c_node)
*
* def ProcessingInstruction(target, text=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "ProcessingInstruction") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2925; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "ProcessingInstruction") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2934; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("ProcessingInstruction", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2925; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("ProcessingInstruction", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2934; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.ProcessingInstruction", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_INCREF(__pyx_v_target);
__Pyx_INCREF(__pyx_v_text);
- /* "src/lxml/lxml.etree.pyx":2934
+ /* "src/lxml/lxml.etree.pyx":2943
* cdef xmlNode* c_node
* cdef xmlDoc* c_doc
* target = _utf8(target) # <<<<<<<<<<<<<<
* if text is None:
* text = b''
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_target); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2934; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_target); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2943; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF_SET(__pyx_v_target, __pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2935
+ /* "src/lxml/lxml.etree.pyx":2944
* cdef xmlDoc* c_doc
* target = _utf8(target)
* if text is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/lxml.etree.pyx":2936
+ /* "src/lxml/lxml.etree.pyx":2945
* target = _utf8(target)
* if text is None:
* text = b'' # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":2938
+ /* "src/lxml/lxml.etree.pyx":2947
* text = b''
* else:
* text = _utf8(text) # <<<<<<<<<<<<<<
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_text); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2938; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_text); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2947; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF_SET(__pyx_v_text, __pyx_t_1);
__pyx_t_1 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2939
+ /* "src/lxml/lxml.etree.pyx":2948
* else:
* text = _utf8(text)
* c_doc = _newXMLDoc() # <<<<<<<<<<<<<<
* doc = _documentFactory(c_doc, None)
* c_node = _createPI(c_doc, _xcstr(target), _xcstr(text))
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_4 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2939; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_4 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2948; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_4;
- /* "src/lxml/lxml.etree.pyx":2940
+ /* "src/lxml/lxml.etree.pyx":2949
* text = _utf8(text)
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None) # <<<<<<<<<<<<<<
* c_node = _createPI(c_doc, _xcstr(target), _xcstr(text))
* tree.xmlAddChild(<xmlNode*>c_doc, c_node)
*/
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2940; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2949; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2941
+ /* "src/lxml/lxml.etree.pyx":2950
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None)
* c_node = _createPI(c_doc, _xcstr(target), _xcstr(text)) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__createPI(__pyx_v_c_doc, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_target), (const xmlChar*)PyBytes_AS_STRING(__pyx_v_text));
- /* "src/lxml/lxml.etree.pyx":2942
+ /* "src/lxml/lxml.etree.pyx":2951
* doc = _documentFactory(c_doc, None)
* c_node = _createPI(c_doc, _xcstr(target), _xcstr(text))
* tree.xmlAddChild(<xmlNode*>c_doc, c_node) # <<<<<<<<<<<<<<
*/
xmlAddChild(((xmlNode *)__pyx_v_c_doc), __pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":2943
+ /* "src/lxml/lxml.etree.pyx":2952
* c_node = _createPI(c_doc, _xcstr(target), _xcstr(text))
* tree.xmlAddChild(<xmlNode*>c_doc, c_node)
* return _elementFactory(doc, c_node) # <<<<<<<<<<<<<<
* PI = ProcessingInstruction
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2943; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2952; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2925
+ /* "src/lxml/lxml.etree.pyx":2934
* return _elementFactory(doc, c_node)
*
* def ProcessingInstruction(target, text=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2962
+/* "src/lxml/lxml.etree.pyx":2971
* """
* cdef bytes _utf8_data
* def __cinit__(self, data): # <<<<<<<<<<<<<<
else goto __pyx_L5_argtuple_error;
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2962; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2971; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2962; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2971; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.CDATA.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":2963
+ /* "src/lxml/lxml.etree.pyx":2972
* cdef bytes _utf8_data
* def __cinit__(self, data):
* self._utf8_data = _utf8(data) # <<<<<<<<<<<<<<
*
* def Entity(name):
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_data); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2963; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_data); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2972; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_self->_utf8_data);
__pyx_v_self->_utf8_data = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2962
+ /* "src/lxml/lxml.etree.pyx":2971
* """
* cdef bytes _utf8_data
* def __cinit__(self, data): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2965
+/* "src/lxml/lxml.etree.pyx":2974
* self._utf8_data = _utf8(data)
*
* def Entity(name): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("Entity", 0);
- /* "src/lxml/lxml.etree.pyx":2977
+ /* "src/lxml/lxml.etree.pyx":2986
* cdef xmlNode* c_node
* cdef xmlDoc* c_doc
* name_utf = _utf8(name) # <<<<<<<<<<<<<<
* c_name = _xcstr(name_utf)
* if c_name[0] == c'#':
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_name); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2977; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_name); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2986; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_name_utf = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2978
+ /* "src/lxml/lxml.etree.pyx":2987
* cdef xmlDoc* c_doc
* name_utf = _utf8(name)
* c_name = _xcstr(name_utf) # <<<<<<<<<<<<<<
*/
__pyx_v_c_name = (const xmlChar*)PyBytes_AS_STRING(__pyx_v_name_utf);
- /* "src/lxml/lxml.etree.pyx":2979
+ /* "src/lxml/lxml.etree.pyx":2988
* name_utf = _utf8(name)
* c_name = _xcstr(name_utf)
* if c_name[0] == c'#': # <<<<<<<<<<<<<<
__pyx_t_2 = (((__pyx_v_c_name[0]) == '#') != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2980
+ /* "src/lxml/lxml.etree.pyx":2989
* c_name = _xcstr(name_utf)
* if c_name[0] == c'#':
* if not _characterReferenceIsValid(c_name + 1): # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(__pyx_f_4lxml_5etree__characterReferenceIsValid((__pyx_v_c_name + 1)) != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2981
+ /* "src/lxml/lxml.etree.pyx":2990
* if c_name[0] == c'#':
* if not _characterReferenceIsValid(c_name + 1):
* raise ValueError, u"Invalid character reference: '%s'" % name # <<<<<<<<<<<<<<
* elif not _xmlNameIsValid(c_name):
* raise ValueError, u"Invalid entity reference: '%s'" % name
*/
- __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_Invalid_character_reference_s, __pyx_v_name); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2981; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_Invalid_character_reference_s, __pyx_v_name); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_t_1, 0, 0);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2981; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":2982
+ /* "src/lxml/lxml.etree.pyx":2991
* if not _characterReferenceIsValid(c_name + 1):
* raise ValueError, u"Invalid character reference: '%s'" % name
* elif not _xmlNameIsValid(c_name): # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(__pyx_f_4lxml_5etree__xmlNameIsValid(__pyx_v_c_name) != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":2983
+ /* "src/lxml/lxml.etree.pyx":2992
* raise ValueError, u"Invalid character reference: '%s'" % name
* elif not _xmlNameIsValid(c_name):
* raise ValueError, u"Invalid entity reference: '%s'" % name # <<<<<<<<<<<<<<
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None)
*/
- __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_Invalid_entity_reference_s, __pyx_v_name); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2983; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_Invalid_entity_reference_s, __pyx_v_name); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2992; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_t_1, 0, 0);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2983; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2992; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":2984
+ /* "src/lxml/lxml.etree.pyx":2993
* elif not _xmlNameIsValid(c_name):
* raise ValueError, u"Invalid entity reference: '%s'" % name
* c_doc = _newXMLDoc() # <<<<<<<<<<<<<<
* doc = _documentFactory(c_doc, None)
* c_node = _createEntity(c_doc, c_name)
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2984; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2993; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_3;
- /* "src/lxml/lxml.etree.pyx":2985
+ /* "src/lxml/lxml.etree.pyx":2994
* raise ValueError, u"Invalid entity reference: '%s'" % name
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None) # <<<<<<<<<<<<<<
* c_node = _createEntity(c_doc, c_name)
* tree.xmlAddChild(<xmlNode*>c_doc, c_node)
*/
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2985; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, ((struct __pyx_obj_4lxml_5etree__BaseParser *)Py_None))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2994; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2986
+ /* "src/lxml/lxml.etree.pyx":2995
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, None)
* c_node = _createEntity(c_doc, c_name) # <<<<<<<<<<<<<<
*/
__pyx_v_c_node = __pyx_f_4lxml_5etree__createEntity(__pyx_v_c_doc, __pyx_v_c_name);
- /* "src/lxml/lxml.etree.pyx":2987
+ /* "src/lxml/lxml.etree.pyx":2996
* doc = _documentFactory(c_doc, None)
* c_node = _createEntity(c_doc, c_name)
* tree.xmlAddChild(<xmlNode*>c_doc, c_node) # <<<<<<<<<<<<<<
*/
xmlAddChild(((xmlNode *)__pyx_v_c_doc), __pyx_v_c_node);
- /* "src/lxml/lxml.etree.pyx":2988
+ /* "src/lxml/lxml.etree.pyx":2997
* c_node = _createEntity(c_doc, c_name)
* tree.xmlAddChild(<xmlNode*>c_doc, c_node)
* return _elementFactory(doc, c_node) # <<<<<<<<<<<<<<
* def SubElement(_Element _parent not None, _tag,
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2988; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(__pyx_v_doc, __pyx_v_c_node)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2997; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2965
+ /* "src/lxml/lxml.etree.pyx":2974
* self._utf8_data = _utf8(data)
*
* def Entity(name): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2990
+/* "src/lxml/lxml.etree.pyx":2999
* return _elementFactory(doc, c_node)
*
* def SubElement(_Element _parent not None, _tag, # <<<<<<<<<<<<<<
static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_parent,&__pyx_n_s_tag_2,&__pyx_n_s_attrib,&__pyx_n_s_nsmap,0};
PyObject* values[4] = {0,0,0,0};
- /* "src/lxml/lxml.etree.pyx":2991
+ /* "src/lxml/lxml.etree.pyx":3000
*
* def SubElement(_Element _parent not None, _tag,
* attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_tag_2)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("SubElement", 0, 2, 4, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("SubElement", 0, 2, 4, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
if (kw_args > 0) {
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "SubElement") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "SubElement") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("SubElement", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("SubElement", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v__extra); __pyx_v__extra = 0;
__Pyx_AddTraceback("lxml.etree.SubElement", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v__parent), __pyx_ptype_4lxml_5etree__Element, 0, "_parent", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v__parent), __pyx_ptype_4lxml_5etree__Element, 0, "_parent", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_14SubElement(__pyx_self, __pyx_v__parent, __pyx_v__tag, __pyx_v_attrib, __pyx_v_nsmap, __pyx_v__extra);
- /* "src/lxml/lxml.etree.pyx":2990
+ /* "src/lxml/lxml.etree.pyx":2999
* return _elementFactory(doc, c_node)
*
* def SubElement(_Element _parent not None, _tag, # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("SubElement", 0);
- /* "src/lxml/lxml.etree.pyx":2997
+ /* "src/lxml/lxml.etree.pyx":3006
* appends it to an existing element.
* """
* return _makeSubElement(_parent, _tag, None, None, attrib, nsmap, _extra) # <<<<<<<<<<<<<<
* def ElementTree(_Element element=None, *, file=None, _BaseParser parser=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__makeSubElement(__pyx_v__parent, __pyx_v__tag, Py_None, Py_None, __pyx_v_attrib, __pyx_v_nsmap, __pyx_v__extra)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2997; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__makeSubElement(__pyx_v__parent, __pyx_v__tag, Py_None, Py_None, __pyx_v_attrib, __pyx_v_nsmap, __pyx_v__extra)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3006; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2990
+ /* "src/lxml/lxml.etree.pyx":2999
* return _elementFactory(doc, c_node)
*
* def SubElement(_Element _parent not None, _tag, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":2999
+/* "src/lxml/lxml.etree.pyx":3008
* return _makeSubElement(_parent, _tag, None, None, attrib, nsmap, _extra)
*
* def ElementTree(_Element element=None, *, file=None, _BaseParser parser=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "ElementTree") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "ElementTree") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("ElementTree", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("ElementTree", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.ElementTree", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 1, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_element), __pyx_ptype_4lxml_5etree__Element, 1, "element", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_16ElementTree(__pyx_self, __pyx_v_element, __pyx_v_file, __pyx_v_parser);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("ElementTree", 0);
- /* "src/lxml/lxml.etree.pyx":3011
+ /* "src/lxml/lxml.etree.pyx":3020
* cdef _Document doc
*
* if element is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3012
+ /* "src/lxml/lxml.etree.pyx":3021
*
* if element is not None:
* doc = element._doc # <<<<<<<<<<<<<<
goto __pyx_L3;
}
- /* "src/lxml/lxml.etree.pyx":3013
+ /* "src/lxml/lxml.etree.pyx":3022
* if element is not None:
* doc = element._doc
* elif file is not None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3014
+ /* "src/lxml/lxml.etree.pyx":3023
* doc = element._doc
* elif file is not None:
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_6);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":3015
+ /* "src/lxml/lxml.etree.pyx":3024
* elif file is not None:
* try:
* doc = _parseDocument(file, parser, None) # <<<<<<<<<<<<<<
* except _TargetParserResult as result_container:
* return result_container.result
*/
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocument(__pyx_v_file, __pyx_v_parser, Py_None)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3015; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocument(__pyx_v_file, __pyx_v_parser, Py_None)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_3);
__pyx_t_3 = 0;
__pyx_L4_error:;
__Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":3016
+ /* "src/lxml/lxml.etree.pyx":3025
* try:
* doc = _parseDocument(file, parser, None)
* except _TargetParserResult as result_container: # <<<<<<<<<<<<<<
* return result_container.result
* else:
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3016; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3025; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_7 = PyErr_ExceptionMatches(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
if (__pyx_t_7) {
__Pyx_AddTraceback("lxml.etree.ElementTree", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3016; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3025; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_GOTREF(__pyx_t_8);
__Pyx_GOTREF(__pyx_t_9);
__Pyx_INCREF(__pyx_t_8);
__pyx_v_result_container = __pyx_t_8;
- /* "src/lxml/lxml.etree.pyx":3017
+ /* "src/lxml/lxml.etree.pyx":3026
* doc = _parseDocument(file, parser, None)
* except _TargetParserResult as result_container:
* return result_container.result # <<<<<<<<<<<<<<
* c_doc = _newXMLDoc()
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3017; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3026; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
__Pyx_GOTREF(__pyx_t_10);
__pyx_r = __pyx_t_10;
__pyx_t_10 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":3019
+ /* "src/lxml/lxml.etree.pyx":3028
* return result_container.result
* else:
* c_doc = _newXMLDoc() # <<<<<<<<<<<<<<
* doc = _documentFactory(c_doc, parser)
*
*/
- __pyx_t_11 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_11 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3019; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_11 = __pyx_f_4lxml_5etree__newXMLDoc(); if (unlikely(__pyx_t_11 == NULL)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3028; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_11;
- /* "src/lxml/lxml.etree.pyx":3020
+ /* "src/lxml/lxml.etree.pyx":3029
* else:
* c_doc = _newXMLDoc()
* doc = _documentFactory(c_doc, parser) # <<<<<<<<<<<<<<
*
* return _elementTreeFactory(doc, element)
*/
- __pyx_t_9 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, __pyx_v_parser)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3020; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = ((PyObject *)__pyx_f_4lxml_5etree__documentFactory(__pyx_v_c_doc, __pyx_v_parser)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3029; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_9);
__pyx_t_9 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":3022
+ /* "src/lxml/lxml.etree.pyx":3031
* doc = _documentFactory(c_doc, parser)
*
* return _elementTreeFactory(doc, element) # <<<<<<<<<<<<<<
* def HTML(text, _BaseParser parser=None, *, base_url=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_9 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_doc, __pyx_v_element)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3022; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_doc, __pyx_v_element)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3031; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__pyx_r = __pyx_t_9;
__pyx_t_9 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":2999
+ /* "src/lxml/lxml.etree.pyx":3008
* return _makeSubElement(_parent, _tag, None, None, attrib, nsmap, _extra)
*
* def ElementTree(_Element element=None, *, file=None, _BaseParser parser=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3024
+/* "src/lxml/lxml.etree.pyx":3033
* return _elementTreeFactory(doc, element)
*
* def HTML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "HTML") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "HTML") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3033; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("HTML", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("HTML", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3033; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.HTML", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_18HTML(__pyx_self, __pyx_v_text, __pyx_v_parser, __pyx_v_base_url);
/* function exit code */
__Pyx_RefNannySetupContext("HTML", 0);
__Pyx_INCREF((PyObject *)__pyx_v_parser);
- /* "src/lxml/lxml.etree.pyx":3039
+ /* "src/lxml/lxml.etree.pyx":3048
* """
* cdef _Document doc
* if parser is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3040
+ /* "src/lxml/lxml.etree.pyx":3049
* cdef _Document doc
* if parser is None:
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser() # <<<<<<<<<<<<<<
* if not isinstance(parser, HTMLParser):
* parser = __DEFAULT_HTML_PARSER
*/
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree_24_ParserDictionaryContext_getDefaultParser(__pyx_v_4lxml_5etree___GLOBAL_PARSER_CONTEXT)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3040; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree_24_ParserDictionaryContext_getDefaultParser(__pyx_v_4lxml_5etree___GLOBAL_PARSER_CONTEXT)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_parser, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_3));
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":3041
+ /* "src/lxml/lxml.etree.pyx":3050
* if parser is None:
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser()
* if not isinstance(parser, HTMLParser): # <<<<<<<<<<<<<<
__pyx_t_1 = ((!(__pyx_t_2 != 0)) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3042
+ /* "src/lxml/lxml.etree.pyx":3051
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser()
* if not isinstance(parser, HTMLParser):
* parser = __DEFAULT_HTML_PARSER # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":3043
+ /* "src/lxml/lxml.etree.pyx":3052
* if not isinstance(parser, HTMLParser):
* parser = __DEFAULT_HTML_PARSER
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_6);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":3044
+ /* "src/lxml/lxml.etree.pyx":3053
* parser = __DEFAULT_HTML_PARSER
* try:
* doc = _parseMemoryDocument(text, base_url, parser) # <<<<<<<<<<<<<<
* return doc.getroot()
* except _TargetParserResult as result_container:
*/
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__parseMemoryDocument(__pyx_v_text, __pyx_v_base_url, __pyx_v_parser)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3044; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__parseMemoryDocument(__pyx_v_text, __pyx_v_base_url, __pyx_v_parser)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3053; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":3045
+ /* "src/lxml/lxml.etree.pyx":3054
* try:
* doc = _parseMemoryDocument(text, base_url, parser)
* return doc.getroot() # <<<<<<<<<<<<<<
* return result_container.result
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3045; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3054; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
__pyx_L5_error:;
__Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":3046
+ /* "src/lxml/lxml.etree.pyx":3055
* doc = _parseMemoryDocument(text, base_url, parser)
* return doc.getroot()
* except _TargetParserResult as result_container: # <<<<<<<<<<<<<<
* return result_container.result
*
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3046; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3055; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_7 = PyErr_ExceptionMatches(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
if (__pyx_t_7) {
__Pyx_AddTraceback("lxml.etree.HTML", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3046; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
+ if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3055; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_GOTREF(__pyx_t_8);
__Pyx_GOTREF(__pyx_t_9);
__Pyx_INCREF(__pyx_t_8);
__pyx_v_result_container = __pyx_t_8;
- /* "src/lxml/lxml.etree.pyx":3047
+ /* "src/lxml/lxml.etree.pyx":3056
* return doc.getroot()
* except _TargetParserResult as result_container:
* return result_container.result # <<<<<<<<<<<<<<
* def XML(text, _BaseParser parser=None, *, base_url=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3047; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
+ __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3056; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
__Pyx_GOTREF(__pyx_t_10);
__pyx_r = __pyx_t_10;
__pyx_t_10 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":3024
+ /* "src/lxml/lxml.etree.pyx":3033
* return _elementTreeFactory(doc, element)
*
* def HTML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3049
+/* "src/lxml/lxml.etree.pyx":3058
* return result_container.result
*
* def XML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "XML") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "XML") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3058; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("XML", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("XML", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3058; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.XML", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3058; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_20XML(__pyx_self, __pyx_v_text, __pyx_v_parser, __pyx_v_base_url);
/* function exit code */
__Pyx_RefNannySetupContext("XML", 0);
__Pyx_INCREF((PyObject *)__pyx_v_parser);
- /* "src/lxml/lxml.etree.pyx":3069
+ /* "src/lxml/lxml.etree.pyx":3078
* """
* cdef _Document doc
* if parser is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3070
+ /* "src/lxml/lxml.etree.pyx":3079
* cdef _Document doc
* if parser is None:
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser() # <<<<<<<<<<<<<<
* if not isinstance(parser, XMLParser):
* parser = __DEFAULT_XML_PARSER
*/
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree_24_ParserDictionaryContext_getDefaultParser(__pyx_v_4lxml_5etree___GLOBAL_PARSER_CONTEXT)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3070; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree_24_ParserDictionaryContext_getDefaultParser(__pyx_v_4lxml_5etree___GLOBAL_PARSER_CONTEXT)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_parser, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_3));
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":3071
+ /* "src/lxml/lxml.etree.pyx":3080
* if parser is None:
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser()
* if not isinstance(parser, XMLParser): # <<<<<<<<<<<<<<
__pyx_t_1 = ((!(__pyx_t_2 != 0)) != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3072
+ /* "src/lxml/lxml.etree.pyx":3081
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser()
* if not isinstance(parser, XMLParser):
* parser = __DEFAULT_XML_PARSER # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":3073
+ /* "src/lxml/lxml.etree.pyx":3082
* if not isinstance(parser, XMLParser):
* parser = __DEFAULT_XML_PARSER
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_6);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":3074
+ /* "src/lxml/lxml.etree.pyx":3083
* parser = __DEFAULT_XML_PARSER
* try:
* doc = _parseMemoryDocument(text, base_url, parser) # <<<<<<<<<<<<<<
* return doc.getroot()
* except _TargetParserResult as result_container:
*/
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__parseMemoryDocument(__pyx_v_text, __pyx_v_base_url, __pyx_v_parser)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3074; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__parseMemoryDocument(__pyx_v_text, __pyx_v_base_url, __pyx_v_parser)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3083; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":3075
+ /* "src/lxml/lxml.etree.pyx":3084
* try:
* doc = _parseMemoryDocument(text, base_url, parser)
* return doc.getroot() # <<<<<<<<<<<<<<
* return result_container.result
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3075; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3084; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
__pyx_L5_error:;
__Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/lxml.etree.pyx":3076
+ /* "src/lxml/lxml.etree.pyx":3085
* doc = _parseMemoryDocument(text, base_url, parser)
* return doc.getroot()
* except _TargetParserResult as result_container: # <<<<<<<<<<<<<<
* return result_container.result
*
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3076; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3085; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_7 = PyErr_ExceptionMatches(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
if (__pyx_t_7) {
__Pyx_AddTraceback("lxml.etree.XML", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3076; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
+ if (__Pyx_GetException(&__pyx_t_3, &__pyx_t_8, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3085; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_GOTREF(__pyx_t_8);
__Pyx_GOTREF(__pyx_t_9);
__Pyx_INCREF(__pyx_t_8);
__pyx_v_result_container = __pyx_t_8;
- /* "src/lxml/lxml.etree.pyx":3077
+ /* "src/lxml/lxml.etree.pyx":3086
* return doc.getroot()
* except _TargetParserResult as result_container:
* return result_container.result # <<<<<<<<<<<<<<
* def fromstring(text, _BaseParser parser=None, *, base_url=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3077; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
+ __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3086; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
__Pyx_GOTREF(__pyx_t_10);
__pyx_r = __pyx_t_10;
__pyx_t_10 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":3049
+ /* "src/lxml/lxml.etree.pyx":3058
* return result_container.result
*
* def XML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3079
+/* "src/lxml/lxml.etree.pyx":3088
* return result_container.result
*
* def fromstring(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "fromstring") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "fromstring") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3088; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("fromstring", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("fromstring", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3088; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.fromstring", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_22fromstring(__pyx_self, __pyx_v_text, __pyx_v_parser, __pyx_v_base_url);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("fromstring", 0);
- /* "src/lxml/lxml.etree.pyx":3093
+ /* "src/lxml/lxml.etree.pyx":3102
* """
* cdef _Document doc
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_3);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":3094
+ /* "src/lxml/lxml.etree.pyx":3103
* cdef _Document doc
* try:
* doc = _parseMemoryDocument(text, base_url, parser) # <<<<<<<<<<<<<<
* return doc.getroot()
* except _TargetParserResult as result_container:
*/
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__parseMemoryDocument(__pyx_v_text, __pyx_v_base_url, __pyx_v_parser)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3094; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__parseMemoryDocument(__pyx_v_text, __pyx_v_base_url, __pyx_v_parser)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3103; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3095
+ /* "src/lxml/lxml.etree.pyx":3104
* try:
* doc = _parseMemoryDocument(text, base_url, parser)
* return doc.getroot() # <<<<<<<<<<<<<<
* return result_container.result
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3095; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_doc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3104; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
__pyx_L3_error:;
__Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3096
+ /* "src/lxml/lxml.etree.pyx":3105
* doc = _parseMemoryDocument(text, base_url, parser)
* return doc.getroot()
* except _TargetParserResult as result_container: # <<<<<<<<<<<<<<
* return result_container.result
*
*/
- __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3096; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3105; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = PyErr_ExceptionMatches(__pyx_t_4);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_5) {
__Pyx_AddTraceback("lxml.etree.fromstring", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3096; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3105; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_7);
__Pyx_INCREF(__pyx_t_6);
__pyx_v_result_container = __pyx_t_6;
- /* "src/lxml/lxml.etree.pyx":3097
+ /* "src/lxml/lxml.etree.pyx":3106
* return doc.getroot()
* except _TargetParserResult as result_container:
* return result_container.result # <<<<<<<<<<<<<<
* def fromstringlist(strings, _BaseParser parser=None):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3097; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3106; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_8);
__pyx_r = __pyx_t_8;
__pyx_t_8 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":3079
+ /* "src/lxml/lxml.etree.pyx":3088
* return result_container.result
*
* def fromstring(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3099
+/* "src/lxml/lxml.etree.pyx":3108
* return result_container.result
*
* def fromstringlist(strings, _BaseParser parser=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "fromstringlist") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3099; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "fromstringlist") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3108; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("fromstringlist", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3099; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("fromstringlist", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3108; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.fromstringlist", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_24fromstringlist(__pyx_self, __pyx_v_strings, __pyx_v_parser);
/* function exit code */
__Pyx_RefNannySetupContext("fromstringlist", 0);
__Pyx_INCREF((PyObject *)__pyx_v_parser);
- /* "src/lxml/lxml.etree.pyx":3109
+ /* "src/lxml/lxml.etree.pyx":3118
* """
* cdef _Document doc
* if isinstance(strings, (bytes, unicode)): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3110
+ /* "src/lxml/lxml.etree.pyx":3119
* cdef _Document doc
* if isinstance(strings, (bytes, unicode)):
* raise ValueError("passing a single string into fromstringlist() is not" # <<<<<<<<<<<<<<
* " efficient, use fromstring() instead")
* if parser is None:
*/
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__39, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__40, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_Raise(__pyx_t_4, 0, 0, 0);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3112
+ /* "src/lxml/lxml.etree.pyx":3121
* raise ValueError("passing a single string into fromstringlist() is not"
* " efficient, use fromstring() instead")
* if parser is None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3113
+ /* "src/lxml/lxml.etree.pyx":3122
* " efficient, use fromstring() instead")
* if parser is None:
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser() # <<<<<<<<<<<<<<
* feed = parser.feed
* for data in strings:
*/
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree_24_ParserDictionaryContext_getDefaultParser(__pyx_v_4lxml_5etree___GLOBAL_PARSER_CONTEXT)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3113; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree_24_ParserDictionaryContext_getDefaultParser(__pyx_v_4lxml_5etree___GLOBAL_PARSER_CONTEXT)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3122; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_parser, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_t_4));
__pyx_t_4 = 0;
}
__pyx_L6:;
- /* "src/lxml/lxml.etree.pyx":3114
+ /* "src/lxml/lxml.etree.pyx":3123
* if parser is None:
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser()
* feed = parser.feed # <<<<<<<<<<<<<<
* for data in strings:
* feed(data)
*/
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_parser), __pyx_n_s_feed); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_parser), __pyx_n_s_feed); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3123; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_feed = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3115
+ /* "src/lxml/lxml.etree.pyx":3124
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser()
* feed = parser.feed
* for data in strings: # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_strings; __Pyx_INCREF(__pyx_t_4); __pyx_t_5 = 0;
__pyx_t_6 = NULL;
} else {
- __pyx_t_5 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_v_strings); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_v_strings); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_6 = Py_TYPE(__pyx_t_4)->tp_iternext; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = Py_TYPE(__pyx_t_4)->tp_iternext; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
for (;;) {
if (likely(!__pyx_t_6)) {
if (likely(PyList_CheckExact(__pyx_t_4))) {
if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_4)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_7 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_7); __pyx_t_5++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_7); __pyx_t_5++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_7 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
} else {
if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_4)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_7 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_7); __pyx_t_5++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_7); __pyx_t_5++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_7 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
}
} else {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ else {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
break;
}
__Pyx_XDECREF_SET(__pyx_v_data, __pyx_t_7);
__pyx_t_7 = 0;
- /* "src/lxml/lxml.etree.pyx":3116
+ /* "src/lxml/lxml.etree.pyx":3125
* feed = parser.feed
* for data in strings:
* feed(data) # <<<<<<<<<<<<<<
}
}
if (!__pyx_t_9) {
- __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_v_data); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_v_data); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3125; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
} else {
- __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3125; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_10);
PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_9); __Pyx_GIVEREF(__pyx_t_9); __pyx_t_9 = NULL;
__Pyx_INCREF(__pyx_v_data);
PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_data);
__Pyx_GIVEREF(__pyx_v_data);
- __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_10, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_10, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3125; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
}
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
- /* "src/lxml/lxml.etree.pyx":3115
+ /* "src/lxml/lxml.etree.pyx":3124
* parser = __GLOBAL_PARSER_CONTEXT.getDefaultParser()
* feed = parser.feed
* for data in strings: # <<<<<<<<<<<<<<
}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3117
+ /* "src/lxml/lxml.etree.pyx":3126
* for data in strings:
* feed(data)
* return parser.close() # <<<<<<<<<<<<<<
* def iselement(element):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_parser), __pyx_n_s_close); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_parser), __pyx_n_s_close); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__pyx_t_8 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_7))) {
}
}
if (__pyx_t_8) {
- __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
} else {
- __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__pyx_t_4 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":3099
+ /* "src/lxml/lxml.etree.pyx":3108
* return result_container.result
*
* def fromstringlist(strings, _BaseParser parser=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3119
+/* "src/lxml/lxml.etree.pyx":3128
* return parser.close()
*
* def iselement(element): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("iselement", 0);
- /* "src/lxml/lxml.etree.pyx":3124
+ /* "src/lxml/lxml.etree.pyx":3133
* Checks if an object appears to be a valid element object.
* """
* return isinstance(element, _Element) and (<_Element>element)._c_node is not NULL # <<<<<<<<<<<<<<
__pyx_t_2 = __Pyx_TypeCheck(__pyx_v_element, ((PyObject*)__pyx_ptype_4lxml_5etree__Element));
if (__pyx_t_2) {
} else {
- __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_1 = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L3_bool_binop_done;
}
__pyx_t_2 = (((struct LxmlElement *)__pyx_v_element)->_c_node != NULL);
- __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_1 = __pyx_t_3;
__pyx_t_3 = 0;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":3119
+ /* "src/lxml/lxml.etree.pyx":3128
* return parser.close()
*
* def iselement(element): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3126
+/* "src/lxml/lxml.etree.pyx":3135
* return isinstance(element, _Element) and (<_Element>element)._c_node is not NULL
*
* def dump(_Element elem not None, *, bint pretty_print=True, with_tail=True): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "dump") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "dump") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
}
__pyx_v_elem = ((struct LxmlElement *)values[0]);
if (values[1]) {
- __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[1]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[1]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_pretty_print = ((int)1);
}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("dump", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("dump", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.dump", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elem), __pyx_ptype_4lxml_5etree__Element, 0, "elem", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elem), __pyx_ptype_4lxml_5etree__Element, 0, "elem", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_28dump(__pyx_self, __pyx_v_elem, __pyx_v_pretty_print, __pyx_v_with_tail);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("dump", 0);
- /* "src/lxml/lxml.etree.pyx":3132
+ /* "src/lxml/lxml.etree.pyx":3141
* should be used for debugging only.
* """
* xml = tostring(elem, pretty_print=pretty_print, with_tail=with_tail, # <<<<<<<<<<<<<<
* encoding=u'unicode' if python.IS_PYTHON3 else None)
* if not pretty_print:
*/
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_tostring); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_tostring); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(((PyObject *)__pyx_v_elem));
PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_elem));
__Pyx_GIVEREF(((PyObject *)__pyx_v_elem));
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = __Pyx_PyBool_FromLong(__pyx_v_pretty_print); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyBool_FromLong(__pyx_v_pretty_print); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_pretty_print, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_pretty_print, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_with_tail, __pyx_v_with_tail) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_with_tail, __pyx_v_with_tail) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3133
+ /* "src/lxml/lxml.etree.pyx":3142
* """
* xml = tostring(elem, pretty_print=pretty_print, with_tail=with_tail,
* encoding=u'unicode' if python.IS_PYTHON3 else None) # <<<<<<<<<<<<<<
__Pyx_INCREF(Py_None);
__pyx_t_4 = Py_None;
}
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_encoding, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_encoding, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3132
+ /* "src/lxml/lxml.etree.pyx":3141
* should be used for debugging only.
* """
* xml = tostring(elem, pretty_print=pretty_print, with_tail=with_tail, # <<<<<<<<<<<<<<
* encoding=u'unicode' if python.IS_PYTHON3 else None)
* if not pretty_print:
*/
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_v_xml = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3134
+ /* "src/lxml/lxml.etree.pyx":3143
* xml = tostring(elem, pretty_print=pretty_print, with_tail=with_tail,
* encoding=u'unicode' if python.IS_PYTHON3 else None)
* if not pretty_print: # <<<<<<<<<<<<<<
__pyx_t_5 = ((!(__pyx_v_pretty_print != 0)) != 0);
if (__pyx_t_5) {
- /* "src/lxml/lxml.etree.pyx":3135
+ /* "src/lxml/lxml.etree.pyx":3144
* encoding=u'unicode' if python.IS_PYTHON3 else None)
* if not pretty_print:
* xml += '\n' # <<<<<<<<<<<<<<
* sys.stdout.write(xml)
*
*/
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_xml, __pyx_kp_s__22); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_xml, __pyx_kp_s__22); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_xml, __pyx_t_4);
__pyx_t_4 = 0;
}
__pyx_L3:;
- /* "src/lxml/lxml.etree.pyx":3136
+ /* "src/lxml/lxml.etree.pyx":3145
* if not pretty_print:
* xml += '\n'
* sys.stdout.write(xml) # <<<<<<<<<<<<<<
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml",
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_sys, __pyx_n_s_stdout); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_sys, __pyx_n_s_stdout); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_write); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_write); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_3 = NULL;
}
}
if (!__pyx_t_3) {
- __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_xml); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_xml); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
} else {
- __pyx_t_1 = PyTuple_New(1+1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1+1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __pyx_t_3 = NULL;
__Pyx_INCREF(__pyx_v_xml);
PyTuple_SET_ITEM(__pyx_t_1, 0+1, __pyx_v_xml);
__Pyx_GIVEREF(__pyx_v_xml);
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_1, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_1, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3126
+ /* "src/lxml/lxml.etree.pyx":3135
* return isinstance(element, _Element) and (<_Element>element)._c_node is not NULL
*
* def dump(_Element elem not None, *, bint pretty_print=True, with_tail=True): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3138
+/* "src/lxml/lxml.etree.pyx":3147
* sys.stdout.write(xml)
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
values[1] = ((PyObject *)Py_None);
values[2] = ((PyObject *)__pyx_n_u_xml);
- /* "src/lxml/lxml.etree.pyx":3139
+ /* "src/lxml/lxml.etree.pyx":3148
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml",
* xml_declaration=None, bint pretty_print=False, bint with_tail=True, # <<<<<<<<<<<<<<
*/
values[3] = ((PyObject *)Py_None);
- /* "src/lxml/lxml.etree.pyx":3140
+ /* "src/lxml/lxml.etree.pyx":3149
* def tostring(element_or_tree, *, encoding=None, method=u"xml",
* xml_declaration=None, bint pretty_print=False, bint with_tail=True,
* standalone=None, doctype=None, # <<<<<<<<<<<<<<
values[6] = ((PyObject *)Py_None);
values[7] = ((PyObject *)Py_None);
- /* "src/lxml/lxml.etree.pyx":3141
+ /* "src/lxml/lxml.etree.pyx":3150
* xml_declaration=None, bint pretty_print=False, bint with_tail=True,
* standalone=None, doctype=None,
* bint exclusive=False, bint with_comments=True, inclusive_ns_prefixes=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "tostring") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3138; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "tostring") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3147; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
__pyx_v_method = values[2];
__pyx_v_xml_declaration = values[3];
if (values[4]) {
- __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[4]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3139; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[4]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3148; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
- /* "src/lxml/lxml.etree.pyx":3139
+ /* "src/lxml/lxml.etree.pyx":3148
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml",
* xml_declaration=None, bint pretty_print=False, bint with_tail=True, # <<<<<<<<<<<<<<
__pyx_v_pretty_print = ((int)0);
}
if (values[5]) {
- __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[5]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3139; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[5]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3148; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_with_tail = ((int)1);
}
__pyx_v_standalone = values[6];
__pyx_v_doctype = values[7];
if (values[8]) {
- __pyx_v_exclusive = __Pyx_PyObject_IsTrue(values[8]); if (unlikely((__pyx_v_exclusive == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_exclusive = __Pyx_PyObject_IsTrue(values[8]); if (unlikely((__pyx_v_exclusive == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3150; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
- /* "src/lxml/lxml.etree.pyx":3141
+ /* "src/lxml/lxml.etree.pyx":3150
* xml_declaration=None, bint pretty_print=False, bint with_tail=True,
* standalone=None, doctype=None,
* bint exclusive=False, bint with_comments=True, inclusive_ns_prefixes=None): # <<<<<<<<<<<<<<
__pyx_v_exclusive = ((int)0);
}
if (values[9]) {
- __pyx_v_with_comments = __Pyx_PyObject_IsTrue(values[9]); if (unlikely((__pyx_v_with_comments == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3141; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_with_comments = __Pyx_PyObject_IsTrue(values[9]); if (unlikely((__pyx_v_with_comments == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3150; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_with_comments = ((int)1);
}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("tostring", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3138; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("tostring", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3147; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.tostring", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__pyx_L4_argument_unpacking_done:;
__pyx_r = __pyx_pf_4lxml_5etree_30tostring(__pyx_self, __pyx_v_element_or_tree, __pyx_v_encoding, __pyx_v_method, __pyx_v_xml_declaration, __pyx_v_pretty_print, __pyx_v_with_tail, __pyx_v_standalone, __pyx_v_doctype, __pyx_v_exclusive, __pyx_v_with_comments, __pyx_v_inclusive_ns_prefixes);
- /* "src/lxml/lxml.etree.pyx":3138
+ /* "src/lxml/lxml.etree.pyx":3147
* sys.stdout.write(xml)
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("tostring", 0);
__Pyx_INCREF(__pyx_v_encoding);
- /* "src/lxml/lxml.etree.pyx":3187
+ /* "src/lxml/lxml.etree.pyx":3196
* cdef int is_standalone
* # C14N serialisation
* if method == 'c14n': # <<<<<<<<<<<<<<
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N")
*/
- __pyx_t_1 = (__Pyx_PyString_Equals(__pyx_v_method, __pyx_n_s_c14n, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3187; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = (__Pyx_PyString_Equals(__pyx_v_method, __pyx_n_s_c14n, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3196; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3188
+ /* "src/lxml/lxml.etree.pyx":3197
* # C14N serialisation
* if method == 'c14n':
* if encoding is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3189
+ /* "src/lxml/lxml.etree.pyx":3198
* if method == 'c14n':
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N") # <<<<<<<<<<<<<<
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N")
*/
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__40, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__41, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3198; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3198; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3190
+ /* "src/lxml/lxml.etree.pyx":3199
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N")
* if xml_declaration: # <<<<<<<<<<<<<<
* raise ValueError("Cannot enable XML declaration in C14N")
* return _tostringC14N(element_or_tree, exclusive, with_comments, inclusive_ns_prefixes)
*/
- __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3190; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3199; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3191
+ /* "src/lxml/lxml.etree.pyx":3200
* raise ValueError("Cannot specify encoding with C14N")
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N") # <<<<<<<<<<<<<<
* return _tostringC14N(element_or_tree, exclusive, with_comments, inclusive_ns_prefixes)
* if not with_comments:
*/
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__41, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__42, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3200; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3200; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3192
+ /* "src/lxml/lxml.etree.pyx":3201
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N")
* return _tostringC14N(element_or_tree, exclusive, with_comments, inclusive_ns_prefixes) # <<<<<<<<<<<<<<
* raise ValueError("Can only discard comments in C14N serialisation")
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __pyx_f_4lxml_5etree__tostringC14N(__pyx_v_element_or_tree, __pyx_v_exclusive, __pyx_v_with_comments, __pyx_v_inclusive_ns_prefixes); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3192; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__tostringC14N(__pyx_v_element_or_tree, __pyx_v_exclusive, __pyx_v_with_comments, __pyx_v_inclusive_ns_prefixes); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3201; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":3193
+ /* "src/lxml/lxml.etree.pyx":3202
* raise ValueError("Cannot enable XML declaration in C14N")
* return _tostringC14N(element_or_tree, exclusive, with_comments, inclusive_ns_prefixes)
* if not with_comments: # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(__pyx_v_with_comments != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3194
+ /* "src/lxml/lxml.etree.pyx":3203
* return _tostringC14N(element_or_tree, exclusive, with_comments, inclusive_ns_prefixes)
* if not with_comments:
* raise ValueError("Can only discard comments in C14N serialisation") # <<<<<<<<<<<<<<
* if encoding is _unicode or (encoding is not None and encoding.upper() == 'UNICODE'):
* if xml_declaration:
*/
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__42, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__43, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3195
+ /* "src/lxml/lxml.etree.pyx":3204
* if not with_comments:
* raise ValueError("Can only discard comments in C14N serialisation")
* if encoding is _unicode or (encoding is not None and encoding.upper() == 'UNICODE'): # <<<<<<<<<<<<<<
__pyx_t_2 = __pyx_t_1;
goto __pyx_L8_bool_binop_done;
}
- __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3195; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3204; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_5))) {
}
}
if (__pyx_t_6) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3195; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3204; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3195; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3204; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_1 = (__Pyx_PyString_Equals(__pyx_t_3, __pyx_n_s_UNICODE, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3195; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = (__Pyx_PyString_Equals(__pyx_t_3, __pyx_n_s_UNICODE, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3204; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = __pyx_t_1;
__pyx_L8_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3196
+ /* "src/lxml/lxml.etree.pyx":3205
* raise ValueError("Can only discard comments in C14N serialisation")
* if encoding is _unicode or (encoding is not None and encoding.upper() == 'UNICODE'):
* if xml_declaration: # <<<<<<<<<<<<<<
* raise ValueError, \
* u"Serialisation to unicode must not request an XML declaration"
*/
- __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3196; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3205; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3197
+ /* "src/lxml/lxml.etree.pyx":3206
* if encoding is _unicode or (encoding is not None and encoding.upper() == 'UNICODE'):
* if xml_declaration:
* raise ValueError, \ # <<<<<<<<<<<<<<
* write_declaration = 0
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Serialisation_to_unicode_must_no, 0, 0);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3197; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3206; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3199
+ /* "src/lxml/lxml.etree.pyx":3208
* raise ValueError, \
* u"Serialisation to unicode must not request an XML declaration"
* write_declaration = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_write_declaration = 0;
- /* "src/lxml/lxml.etree.pyx":3200
+ /* "src/lxml/lxml.etree.pyx":3209
* u"Serialisation to unicode must not request an XML declaration"
* write_declaration = 0
* encoding = _unicode # <<<<<<<<<<<<<<
goto __pyx_L7;
}
- /* "src/lxml/lxml.etree.pyx":3201
+ /* "src/lxml/lxml.etree.pyx":3210
* write_declaration = 0
* encoding = _unicode
* elif xml_declaration is None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3203
+ /* "src/lxml/lxml.etree.pyx":3212
* elif xml_declaration is None:
* # by default, write an XML declaration only for non-standard encodings
* write_declaration = encoding is not None and encoding.upper() not in \ # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_t_4;
goto __pyx_L12_bool_binop_done;
}
- __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_upper); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_5))) {
}
}
if (__pyx_t_6) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_n_u_ASCII, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_n_u_ASCII, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
} else {
__pyx_t_4 = __pyx_t_2;
goto __pyx_L14_bool_binop_done;
}
- __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_kp_u_UTF_8, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_kp_u_UTF_8, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
} else {
__pyx_t_4 = __pyx_t_2;
goto __pyx_L14_bool_binop_done;
}
- __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_n_u_UTF8, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_n_u_UTF8, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_2) {
} else {
__pyx_t_4 = __pyx_t_2;
goto __pyx_L14_bool_binop_done;
}
- __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_kp_u_US_ASCII, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_3, __pyx_kp_u_US_ASCII, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3212; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_4 = __pyx_t_2;
__pyx_L14_bool_binop_done:;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":3206
+ /* "src/lxml/lxml.etree.pyx":3215
* (u'ASCII', u'UTF-8', u'UTF8', u'US-ASCII')
* else:
* write_declaration = xml_declaration # <<<<<<<<<<<<<<
* if encoding is None:
* encoding = u'ASCII'
*/
- __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3206; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_xml_declaration); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3215; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_write_declaration = __pyx_t_1;
}
__pyx_L7:;
- /* "src/lxml/lxml.etree.pyx":3207
+ /* "src/lxml/lxml.etree.pyx":3216
* else:
* write_declaration = xml_declaration
* if encoding is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3208
+ /* "src/lxml/lxml.etree.pyx":3217
* write_declaration = xml_declaration
* if encoding is None:
* encoding = u'ASCII' # <<<<<<<<<<<<<<
}
__pyx_L18:;
- /* "src/lxml/lxml.etree.pyx":3209
+ /* "src/lxml/lxml.etree.pyx":3218
* if encoding is None:
* encoding = u'ASCII'
* if standalone is None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3210
+ /* "src/lxml/lxml.etree.pyx":3219
* encoding = u'ASCII'
* if standalone is None:
* is_standalone = -1 # <<<<<<<<<<<<<<
goto __pyx_L19;
}
- /* "src/lxml/lxml.etree.pyx":3211
+ /* "src/lxml/lxml.etree.pyx":3220
* if standalone is None:
* is_standalone = -1
* elif standalone: # <<<<<<<<<<<<<<
* write_declaration = 1
* is_standalone = 1
*/
- __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_standalone); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3211; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_standalone); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3220; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3212
+ /* "src/lxml/lxml.etree.pyx":3221
* is_standalone = -1
* elif standalone:
* write_declaration = 1 # <<<<<<<<<<<<<<
*/
__pyx_v_write_declaration = 1;
- /* "src/lxml/lxml.etree.pyx":3213
+ /* "src/lxml/lxml.etree.pyx":3222
* elif standalone:
* write_declaration = 1
* is_standalone = 1 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":3215
+ /* "src/lxml/lxml.etree.pyx":3224
* is_standalone = 1
* else:
* write_declaration = 1 # <<<<<<<<<<<<<<
*/
__pyx_v_write_declaration = 1;
- /* "src/lxml/lxml.etree.pyx":3216
+ /* "src/lxml/lxml.etree.pyx":3225
* else:
* write_declaration = 1
* is_standalone = 0 # <<<<<<<<<<<<<<
}
__pyx_L19:;
- /* "src/lxml/lxml.etree.pyx":3218
+ /* "src/lxml/lxml.etree.pyx":3227
* is_standalone = 0
*
* if isinstance(element_or_tree, _Element): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3219
+ /* "src/lxml/lxml.etree.pyx":3228
*
* if isinstance(element_or_tree, _Element):
* return _tostring(<_Element>element_or_tree, encoding, doctype, method, # <<<<<<<<<<<<<<
*/
__Pyx_XDECREF(__pyx_r);
- /* "src/lxml/lxml.etree.pyx":3221
+ /* "src/lxml/lxml.etree.pyx":3230
* return _tostring(<_Element>element_or_tree, encoding, doctype, method,
* write_declaration, 0, pretty_print, with_tail,
* is_standalone) # <<<<<<<<<<<<<<
* elif isinstance(element_or_tree, _ElementTree):
* return _tostring((<_ElementTree>element_or_tree)._context_node,
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_v_element_or_tree), __pyx_v_encoding, __pyx_v_doctype, __pyx_v_method, __pyx_v_write_declaration, 0, __pyx_v_pretty_print, __pyx_v_with_tail, __pyx_v_is_standalone); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3219; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_v_element_or_tree), __pyx_v_encoding, __pyx_v_doctype, __pyx_v_method, __pyx_v_write_declaration, 0, __pyx_v_pretty_print, __pyx_v_with_tail, __pyx_v_is_standalone); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3228; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":3222
+ /* "src/lxml/lxml.etree.pyx":3231
* write_declaration, 0, pretty_print, with_tail,
* is_standalone)
* elif isinstance(element_or_tree, _ElementTree): # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3223
+ /* "src/lxml/lxml.etree.pyx":3232
* is_standalone)
* elif isinstance(element_or_tree, _ElementTree):
* return _tostring((<_ElementTree>element_or_tree)._context_node, # <<<<<<<<<<<<<<
__pyx_t_3 = ((PyObject *)((struct LxmlElementTree *)__pyx_v_element_or_tree)->_context_node);
__Pyx_INCREF(__pyx_t_3);
- /* "src/lxml/lxml.etree.pyx":3225
+ /* "src/lxml/lxml.etree.pyx":3234
* return _tostring((<_ElementTree>element_or_tree)._context_node,
* encoding, doctype, method, write_declaration, 1,
* pretty_print, with_tail, is_standalone) # <<<<<<<<<<<<<<
* else:
* raise TypeError, u"Type '%s' cannot be serialized." % \
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_t_3), __pyx_v_encoding, __pyx_v_doctype, __pyx_v_method, __pyx_v_write_declaration, 1, __pyx_v_pretty_print, __pyx_v_with_tail, __pyx_v_is_standalone); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3223; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_t_3), __pyx_v_encoding, __pyx_v_doctype, __pyx_v_method, __pyx_v_write_declaration, 1, __pyx_v_pretty_print, __pyx_v_with_tail, __pyx_v_is_standalone); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_r = __pyx_t_5;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":3228
+ /* "src/lxml/lxml.etree.pyx":3237
* else:
* raise TypeError, u"Type '%s' cannot be serialized." % \
* python._fqtypename(element_or_tree).decode('utf8') # <<<<<<<<<<<<<<
* def tostringlist(element_or_tree, *args, **kwargs):
*/
__pyx_t_7 = _fqtypename(__pyx_v_element_or_tree);
- __pyx_t_5 = __Pyx_decode_c_string(__pyx_t_7, 0, strlen(__pyx_t_7), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3228; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_decode_c_string(__pyx_t_7, 0, strlen(__pyx_t_7), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3237; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- /* "src/lxml/lxml.etree.pyx":3227
+ /* "src/lxml/lxml.etree.pyx":3236
* pretty_print, with_tail, is_standalone)
* else:
* raise TypeError, u"Type '%s' cannot be serialized." % \ # <<<<<<<<<<<<<<
* python._fqtypename(element_or_tree).decode('utf8')
*
*/
- __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_Type_s_cannot_be_serialized, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_Type_s_cannot_be_serialized, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3236; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_t_3, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3236; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3138
+ /* "src/lxml/lxml.etree.pyx":3147
* sys.stdout.write(xml)
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3230
+/* "src/lxml/lxml.etree.pyx":3239
* python._fqtypename(element_or_tree).decode('utf8')
*
* def tostringlist(element_or_tree, *args, **kwargs): # <<<<<<<<<<<<<<
}
if (unlikely(kw_args > 0)) {
const Py_ssize_t used_pos_args = (pos_args < 1) ? pos_args : 1;
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "tostringlist") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3230; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v_kwargs, values, used_pos_args, "tostringlist") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) < 1) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("tostringlist", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3230; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("tostringlist", 0, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0;
__Pyx_DECREF(__pyx_v_kwargs); __pyx_v_kwargs = 0;
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("tostringlist", 0);
- /* "src/lxml/lxml.etree.pyx":3239
+ /* "src/lxml/lxml.etree.pyx":3248
* single string wrapped in a list.
* """
* return [tostring(element_or_tree, *args, **kwargs)] # <<<<<<<<<<<<<<
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False,
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_tostring); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_tostring); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(__pyx_v_element_or_tree);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_element_or_tree);
__Pyx_GIVEREF(__pyx_v_element_or_tree);
- __pyx_t_3 = PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_Add(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_3 = __pyx_v_kwargs;
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = PyList_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyList_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
PyList_SET_ITEM(__pyx_t_3, 0, __pyx_t_2);
__Pyx_GIVEREF(__pyx_t_2);
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":3230
+ /* "src/lxml/lxml.etree.pyx":3239
* python._fqtypename(element_or_tree).decode('utf8')
*
* def tostringlist(element_or_tree, *args, **kwargs): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3241
+/* "src/lxml/lxml.etree.pyx":3250
* return [tostring(element_or_tree, *args, **kwargs)]
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False, # <<<<<<<<<<<<<<
PyObject* values[5] = {0,0,0,0,0};
values[1] = ((PyObject *)__pyx_n_u_xml);
- /* "src/lxml/lxml.etree.pyx":3242
+ /* "src/lxml/lxml.etree.pyx":3251
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False,
* bint with_tail=True, doctype=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "tounicode") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3241; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "tounicode") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3250; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
goto __pyx_L5_argtuple_error;
__pyx_v_element_or_tree = values[0];
__pyx_v_method = values[1];
if (values[2]) {
- __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3241; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[2]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3250; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
- /* "src/lxml/lxml.etree.pyx":3241
+ /* "src/lxml/lxml.etree.pyx":3250
* return [tostring(element_or_tree, *args, **kwargs)]
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False, # <<<<<<<<<<<<<<
__pyx_v_pretty_print = ((int)0);
}
if (values[3]) {
- __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[3]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3242; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[3]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3251; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
- /* "src/lxml/lxml.etree.pyx":3242
+ /* "src/lxml/lxml.etree.pyx":3251
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False,
* bint with_tail=True, doctype=None): # <<<<<<<<<<<<<<
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("tounicode", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3241; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("tounicode", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3250; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.tounicode", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__pyx_L4_argument_unpacking_done:;
__pyx_r = __pyx_pf_4lxml_5etree_34tounicode(__pyx_self, __pyx_v_element_or_tree, __pyx_v_method, __pyx_v_pretty_print, __pyx_v_with_tail, __pyx_v_doctype);
- /* "src/lxml/lxml.etree.pyx":3241
+ /* "src/lxml/lxml.etree.pyx":3250
* return [tostring(element_or_tree, *args, **kwargs)]
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False, # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("tounicode", 0);
- /* "src/lxml/lxml.etree.pyx":3264
+ /* "src/lxml/lxml.etree.pyx":3273
* on the tail text of children, which will always be serialised.
* """
* if isinstance(element_or_tree, _Element): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/lxml.etree.pyx":3265
+ /* "src/lxml/lxml.etree.pyx":3274
* """
* if isinstance(element_or_tree, _Element):
* return _tostring(<_Element>element_or_tree, _unicode, doctype, method, # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_4lxml_5etree__unicode;
__Pyx_INCREF(__pyx_t_3);
- /* "src/lxml/lxml.etree.pyx":3266
+ /* "src/lxml/lxml.etree.pyx":3275
* if isinstance(element_or_tree, _Element):
* return _tostring(<_Element>element_or_tree, _unicode, doctype, method,
* 0, 0, pretty_print, with_tail, -1) # <<<<<<<<<<<<<<
* elif isinstance(element_or_tree, _ElementTree):
* return _tostring((<_ElementTree>element_or_tree)._context_node,
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_v_element_or_tree), __pyx_t_3, __pyx_v_doctype, __pyx_v_method, 0, 0, __pyx_v_pretty_print, __pyx_v_with_tail, -1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3265; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_v_element_or_tree), __pyx_t_3, __pyx_v_doctype, __pyx_v_method, 0, 0, __pyx_v_pretty_print, __pyx_v_with_tail, -1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3274; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_r = __pyx_t_4;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":3267
+ /* "src/lxml/lxml.etree.pyx":3276
* return _tostring(<_Element>element_or_tree, _unicode, doctype, method,
* 0, 0, pretty_print, with_tail, -1)
* elif isinstance(element_or_tree, _ElementTree): # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/lxml.etree.pyx":3268
+ /* "src/lxml/lxml.etree.pyx":3277
* 0, 0, pretty_print, with_tail, -1)
* elif isinstance(element_or_tree, _ElementTree):
* return _tostring((<_ElementTree>element_or_tree)._context_node, # <<<<<<<<<<<<<<
__pyx_t_4 = ((PyObject *)((struct LxmlElementTree *)__pyx_v_element_or_tree)->_context_node);
__Pyx_INCREF(__pyx_t_4);
- /* "src/lxml/lxml.etree.pyx":3269
+ /* "src/lxml/lxml.etree.pyx":3278
* elif isinstance(element_or_tree, _ElementTree):
* return _tostring((<_ElementTree>element_or_tree)._context_node,
* _unicode, doctype, method, 0, 1, pretty_print, # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_4lxml_5etree__unicode;
__Pyx_INCREF(__pyx_t_3);
- /* "src/lxml/lxml.etree.pyx":3268
+ /* "src/lxml/lxml.etree.pyx":3277
* 0, 0, pretty_print, with_tail, -1)
* elif isinstance(element_or_tree, _ElementTree):
* return _tostring((<_ElementTree>element_or_tree)._context_node, # <<<<<<<<<<<<<<
* _unicode, doctype, method, 0, 1, pretty_print,
* with_tail, -1)
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_t_4), __pyx_t_3, __pyx_v_doctype, __pyx_v_method, 0, 1, __pyx_v_pretty_print, __pyx_v_with_tail, -1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3268; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__tostring(((struct LxmlElement *)__pyx_t_4), __pyx_t_3, __pyx_v_doctype, __pyx_v_method, 0, 1, __pyx_v_pretty_print, __pyx_v_with_tail, -1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3277; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
}
/*else*/ {
- /* "src/lxml/lxml.etree.pyx":3272
+ /* "src/lxml/lxml.etree.pyx":3281
* with_tail, -1)
* else:
* raise TypeError, u"Type '%s' cannot be serialized." % \ # <<<<<<<<<<<<<<
* type(element_or_tree)
*
*/
- __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_Type_s_cannot_be_serialized, ((PyObject *)Py_TYPE(__pyx_v_element_or_tree))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3272; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_Type_s_cannot_be_serialized, ((PyObject *)Py_TYPE(__pyx_v_element_or_tree))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3281; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_Raise(__pyx_builtin_TypeError, __pyx_t_5, 0, 0);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3272; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3281; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3241
+ /* "src/lxml/lxml.etree.pyx":3250
* return [tostring(element_or_tree, *args, **kwargs)]
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3275
+/* "src/lxml/lxml.etree.pyx":3284
* type(element_or_tree)
*
* def parse(source, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
if (value) { values[index] = value; kw_args--; }
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "parse") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3275; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "parse") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3284; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("parse", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3275; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("parse", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3284; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.parse", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3275; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_parser), __pyx_ptype_4lxml_5etree__BaseParser, 1, "parser", 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3284; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_36parse(__pyx_self, __pyx_v_source, __pyx_v_parser, __pyx_v_base_url);
/* function exit code */
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("parse", 0);
- /* "src/lxml/lxml.etree.pyx":3300
+ /* "src/lxml/lxml.etree.pyx":3309
* """
* cdef _Document doc
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_3);
/*try:*/ {
- /* "src/lxml/lxml.etree.pyx":3301
+ /* "src/lxml/lxml.etree.pyx":3310
* cdef _Document doc
* try:
* doc = _parseDocument(source, parser, base_url) # <<<<<<<<<<<<<<
* return _elementTreeFactory(doc, None)
* except _TargetParserResult as result_container:
*/
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocument(__pyx_v_source, __pyx_v_parser, __pyx_v_base_url)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3301; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocument(__pyx_v_source, __pyx_v_parser, __pyx_v_base_url)); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3310; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_doc = ((struct LxmlDocument *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3302
+ /* "src/lxml/lxml.etree.pyx":3311
* try:
* doc = _parseDocument(source, parser, base_url)
* return _elementTreeFactory(doc, None) # <<<<<<<<<<<<<<
* return result_container.result
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_doc, ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3302; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_4 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_doc, ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3311; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_r = __pyx_t_4;
__pyx_t_4 = 0;
__pyx_L3_error:;
__Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/lxml.etree.pyx":3303
+ /* "src/lxml/lxml.etree.pyx":3312
* doc = _parseDocument(source, parser, base_url)
* return _elementTreeFactory(doc, None)
* except _TargetParserResult as result_container: # <<<<<<<<<<<<<<
* return result_container.result
*
*/
- __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3303; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_TargetParserResult); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3312; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = PyErr_ExceptionMatches(__pyx_t_4);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_5) {
__Pyx_AddTraceback("lxml.etree.parse", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3303; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3312; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_7);
__Pyx_INCREF(__pyx_t_6);
__pyx_v_result_container = __pyx_t_6;
- /* "src/lxml/lxml.etree.pyx":3304
+ /* "src/lxml/lxml.etree.pyx":3313
* return _elementTreeFactory(doc, None)
* except _TargetParserResult as result_container:
* return result_container.result # <<<<<<<<<<<<<<
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3304; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_result_container, __pyx_n_s_result); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3313; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
__Pyx_GOTREF(__pyx_t_8);
__pyx_r = __pyx_t_8;
__pyx_t_8 = 0;
goto __pyx_L0;
}
- /* "src/lxml/lxml.etree.pyx":3275
+ /* "src/lxml/lxml.etree.pyx":3284
* type(element_or_tree)
*
* def parse(source, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* return 0
*
*/
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ReferenceError, __pyx_tuple__43, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ReferenceError, __pyx_tuple__44, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_XDECREF(__pyx_r);
__pyx_t_2 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->_c_node->name); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 60; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_s_3, __pyx_t_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 60; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_s_5, __pyx_t_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 60; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__pyx_r = __pyx_t_4;
__Pyx_XDECREF(__pyx_r);
__pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s_3, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_r = __pyx_t_3;
__Pyx_XDECREF(__pyx_r);
__pyx_t_3 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->_c_node->name); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_s_3, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_s_5, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 92; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_r = __pyx_t_4;
__Pyx_XDECREF(__pyx_r);
__pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_target); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 98; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s_2, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 98; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyUnicode_Format(__pyx_kp_u_s_4, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 98; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_2 = __pyx_t_4;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_4 = (__Pyx_PyString_Equals(__pyx_v_tag, __pyx_kp_s__35, Py_NE)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 193; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = (__Pyx_PyString_Equals(__pyx_v_tag, __pyx_kp_s__36, Py_NE)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 193; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = __pyx_t_4;
__pyx_L4_bool_binop_done:;
if (__pyx_t_2) {
* return iter(children)
*
*/
- __pyx_t_1 = PyObject_GetItem(__pyx_v_children, __pyx_slice__44); if (unlikely(__pyx_t_1 == NULL)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 196; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_1 = PyObject_GetItem(__pyx_v_children, __pyx_slice__45); if (unlikely(__pyx_t_1 == NULL)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 196; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF_SET(__pyx_v_children, __pyx_t_1);
__pyx_t_1 = 0;
* raise ValueError(u"Invalid entity name '%s'" % value)
* tree.xmlNodeSetName(self._c_node, _xcstr(value_utf))
*/
- __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_kp_u__25, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 265; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_kp_u__26, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 265; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_4 = (__pyx_t_3 != 0);
if (!__pyx_t_4) {
} else {
__pyx_t_2 = __pyx_t_4;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_4 = (__Pyx_PySequence_Contains(__pyx_kp_u__26, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 265; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = (__Pyx_PySequence_Contains(__pyx_kp_u__27, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 265; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = (__pyx_t_4 != 0);
__pyx_t_2 = __pyx_t_3;
__pyx_L4_bool_binop_done:;
__Pyx_XDECREF(__pyx_r);
__pyx_t_1 = __pyx_f_4lxml_5etree_funicode(__pyx_v_self->__pyx_base._c_node->name); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 271; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_s_3, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 271; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_s_5, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 271; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_r = __pyx_t_2;
*/
#ifndef CYTHON_WITHOUT_ASSERTIONS
if (unlikely(!Py_OptimizeFlag)) {
- __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_kp_u__25, __pyx_v_value, Py_NE)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_kp_u__26, __pyx_v_value, Py_NE)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_4 = (__pyx_t_3 != 0);
if (__pyx_t_4) {
} else {
__pyx_t_2 = __pyx_t_4;
goto __pyx_L3_bool_binop_done;
}
- __pyx_t_4 = (__Pyx_PySequence_Contains(__pyx_kp_u__26, __pyx_v_value, Py_NE)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = (__Pyx_PySequence_Contains(__pyx_kp_u__27, __pyx_v_value, Py_NE)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = (__pyx_t_4 != 0);
__pyx_t_2 = __pyx_t_3;
__pyx_L3_bool_binop_done:;
*/
__pyx_t_13 = __Pyx_PyObject_GetAttrStr(__pyx_v_tag, __pyx_n_s_split); if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 61; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
__Pyx_GOTREF(__pyx_t_13);
- __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_13, __pyx_tuple__45, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 61; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_13, __pyx_tuple__46, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 61; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0;
__pyx_t_13 = __Pyx_GetItemInt(__pyx_t_5, -1, long, 1, __Pyx_PyInt_From_long, 0, 1, 1); if (unlikely(__pyx_t_13 == NULL)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 61; __pyx_clineno = __LINE__; goto __pyx_L15_except_error;};
} else {
goto __pyx_L10_next_and;
}
- __pyx_t_4 = __Pyx_PyObject_GetSlice(__pyx_v_name, 0, 1, NULL, NULL, &__pyx_slice__46, 0, 1, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 46; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetSlice(__pyx_v_name, 0, 1, NULL, NULL, &__pyx_slice__47, 0, 1, 1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 46; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_11 = (__Pyx_PyString_Equals(__pyx_t_4, __pyx_n_s__47, Py_NE)); if (unlikely(__pyx_t_11 < 0)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 46; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_11 = (__Pyx_PyString_Equals(__pyx_t_4, __pyx_n_s__48, Py_NE)); if (unlikely(__pyx_t_11 < 0)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 46; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_11) {
} else {
* self._setBaseURL(base_url)
* self._collectEvents(events, tag)
*/
- __Pyx_INCREF(__pyx_tuple__48);
- __Pyx_DECREF_SET(__pyx_v_events, __pyx_tuple__48);
+ __Pyx_INCREF(__pyx_tuple__49);
+ __Pyx_DECREF_SET(__pyx_v_events, __pyx_tuple__49);
goto __pyx_L3;
}
__pyx_L3:;
* self._setBaseURL(base_url)
* self._collectEvents(events, tag)
*/
- __Pyx_INCREF(__pyx_tuple__49);
- __Pyx_DECREF_SET(__pyx_v_events, __pyx_tuple__49);
+ __Pyx_INCREF(__pyx_tuple__50);
+ __Pyx_DECREF_SET(__pyx_v_events, __pyx_tuple__50);
goto __pyx_L3;
}
__pyx_L3:;
* u"Unicode strings with encoding declaration are not supported. "
* u"Please use bytes input or XML fragments without declaration.")
*/
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__50, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__51, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = __pyx_t_4;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_4 = (__Pyx_PyString_Equals(__pyx_v_tag, __pyx_kp_s__35, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[12]; __pyx_lineno = 179; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = (__Pyx_PyString_Equals(__pyx_v_tag, __pyx_kp_s__36, Py_EQ)); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[12]; __pyx_lineno = 179; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = __pyx_t_4;
__pyx_L4_bool_binop_done:;
if (__pyx_t_2) {
*/
__pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_encoding, __pyx_n_s_decode); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__51, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__52, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF_SET(__pyx_v_encoding, __pyx_t_6);
*
* cdef void _writeDtdToBuffer(tree.xmlOutputBuffer* c_buffer,
*/
- xmlOutputBufferWrite(__pyx_v_c_buffer, 4, __pyx_k__52);
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 4, __pyx_k__53);
break;
}
static void __pyx_f_4lxml_5etree__writeDtdToBuffer(xmlOutputBuffer *__pyx_v_c_buffer, xmlDoc *__pyx_v_c_doc, const xmlChar *__pyx_v_c_root_name, const char *__pyx_v_encoding) {
xmlDtd *__pyx_v_c_dtd;
xmlNode *__pyx_v_c_node;
+ char *__pyx_v_quotechar;
xmlBuffer *__pyx_v_c_buf;
xmlDtd *__pyx_t_1;
int __pyx_t_2;
int __pyx_t_3;
xmlNode *__pyx_t_4;
- /* "src/lxml/serializer.pxi":283
- * cdef tree.xmlDtd* c_dtd
+ /* "src/lxml/serializer.pxi":284
* cdef xmlNode* c_node
+ * cdef char* quotechar
* c_dtd = c_doc.intSubset # <<<<<<<<<<<<<<
* if not c_dtd or not c_dtd.name:
* return
__pyx_t_1 = __pyx_v_c_doc->intSubset;
__pyx_v_c_dtd = __pyx_t_1;
- /* "src/lxml/serializer.pxi":284
- * cdef xmlNode* c_node
+ /* "src/lxml/serializer.pxi":285
+ * cdef char* quotechar
* c_dtd = c_doc.intSubset
* if not c_dtd or not c_dtd.name: # <<<<<<<<<<<<<<
* return
__pyx_L4_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":285
+ /* "src/lxml/serializer.pxi":286
* c_dtd = c_doc.intSubset
* if not c_dtd or not c_dtd.name:
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":286
+ /* "src/lxml/serializer.pxi":287
* if not c_dtd or not c_dtd.name:
* return
* if tree.xmlStrcmp(c_root_name, c_dtd.name) != 0: # <<<<<<<<<<<<<<
__pyx_t_2 = ((xmlStrcmp(__pyx_v_c_root_name, __pyx_v_c_dtd->name) != 0) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":287
+ /* "src/lxml/serializer.pxi":288
* return
* if tree.xmlStrcmp(c_root_name, c_dtd.name) != 0:
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":288
+ /* "src/lxml/serializer.pxi":289
* if tree.xmlStrcmp(c_root_name, c_dtd.name) != 0:
* return
* tree.xmlOutputBufferWrite(c_buffer, 10, "<!DOCTYPE ") # <<<<<<<<<<<<<<
*/
xmlOutputBufferWrite(__pyx_v_c_buffer, 10, __pyx_k_DOCTYPE);
- /* "src/lxml/serializer.pxi":289
+ /* "src/lxml/serializer.pxi":290
* return
* tree.xmlOutputBufferWrite(c_buffer, 10, "<!DOCTYPE ")
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.name) # <<<<<<<<<<<<<<
*/
xmlOutputBufferWriteString(__pyx_v_c_buffer, ((const char *)__pyx_v_c_dtd->name));
- /* "src/lxml/serializer.pxi":290
+ /* "src/lxml/serializer.pxi":291
* tree.xmlOutputBufferWrite(c_buffer, 10, "<!DOCTYPE ")
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.name)
* if c_dtd.SystemID and c_dtd.SystemID[0] != c'\0': # <<<<<<<<<<<<<<
__pyx_L8_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":291
+ /* "src/lxml/serializer.pxi":292
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.name)
* if c_dtd.SystemID and c_dtd.SystemID[0] != c'\0':
* if c_dtd.ExternalID != NULL and c_dtd.ExternalID[0] != c'\0': # <<<<<<<<<<<<<<
__pyx_L11_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":292
+ /* "src/lxml/serializer.pxi":293
* if c_dtd.SystemID and c_dtd.SystemID[0] != c'\0':
* if c_dtd.ExternalID != NULL and c_dtd.ExternalID[0] != c'\0':
* tree.xmlOutputBufferWrite(c_buffer, 9, ' PUBLIC "') # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.ExternalID)
- * tree.xmlOutputBufferWrite(c_buffer, 3, '" "')
+ * tree.xmlOutputBufferWrite(c_buffer, 2, '" ')
*/
xmlOutputBufferWrite(__pyx_v_c_buffer, 9, __pyx_k_PUBLIC);
- /* "src/lxml/serializer.pxi":293
+ /* "src/lxml/serializer.pxi":294
* if c_dtd.ExternalID != NULL and c_dtd.ExternalID[0] != c'\0':
* tree.xmlOutputBufferWrite(c_buffer, 9, ' PUBLIC "')
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.ExternalID) # <<<<<<<<<<<<<<
- * tree.xmlOutputBufferWrite(c_buffer, 3, '" "')
+ * tree.xmlOutputBufferWrite(c_buffer, 2, '" ')
* else:
*/
xmlOutputBufferWriteString(__pyx_v_c_buffer, ((const char *)__pyx_v_c_dtd->ExternalID));
- /* "src/lxml/serializer.pxi":294
+ /* "src/lxml/serializer.pxi":295
* tree.xmlOutputBufferWrite(c_buffer, 9, ' PUBLIC "')
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.ExternalID)
- * tree.xmlOutputBufferWrite(c_buffer, 3, '" "') # <<<<<<<<<<<<<<
+ * tree.xmlOutputBufferWrite(c_buffer, 2, '" ') # <<<<<<<<<<<<<<
* else:
- * tree.xmlOutputBufferWrite(c_buffer, 9, ' SYSTEM "')
+ * tree.xmlOutputBufferWrite(c_buffer, 8, ' SYSTEM ')
*/
- xmlOutputBufferWrite(__pyx_v_c_buffer, 3, __pyx_k__53);
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 2, __pyx_k__54);
goto __pyx_L10;
}
/*else*/ {
- /* "src/lxml/serializer.pxi":296
- * tree.xmlOutputBufferWrite(c_buffer, 3, '" "')
+ /* "src/lxml/serializer.pxi":297
+ * tree.xmlOutputBufferWrite(c_buffer, 2, '" ')
* else:
- * tree.xmlOutputBufferWrite(c_buffer, 9, ' SYSTEM "') # <<<<<<<<<<<<<<
- * tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.SystemID)
- * tree.xmlOutputBufferWrite(c_buffer, 1, '"')
+ * tree.xmlOutputBufferWrite(c_buffer, 8, ' SYSTEM ') # <<<<<<<<<<<<<<
+ *
+ * if tree.xmlStrchr(<const_xmlChar*>c_dtd.SystemID, c'"'):
*/
- xmlOutputBufferWrite(__pyx_v_c_buffer, 9, __pyx_k_SYSTEM);
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 8, __pyx_k_SYSTEM);
}
__pyx_L10:;
- /* "src/lxml/serializer.pxi":297
+ /* "src/lxml/serializer.pxi":299
+ * tree.xmlOutputBufferWrite(c_buffer, 8, ' SYSTEM ')
+ *
+ * if tree.xmlStrchr(<const_xmlChar*>c_dtd.SystemID, c'"'): # <<<<<<<<<<<<<<
+ * quotechar = '\''
+ * else:
+ */
+ __pyx_t_2 = (xmlStrchr(((const xmlChar *)__pyx_v_c_dtd->SystemID), '"') != 0);
+ if (__pyx_t_2) {
+
+ /* "src/lxml/serializer.pxi":300
+ *
+ * if tree.xmlStrchr(<const_xmlChar*>c_dtd.SystemID, c'"'):
+ * quotechar = '\'' # <<<<<<<<<<<<<<
+ * else:
+ * quotechar = '"'
+ */
+ __pyx_v_quotechar = __pyx_k__55;
+ goto __pyx_L13;
+ }
+ /*else*/ {
+
+ /* "src/lxml/serializer.pxi":302
+ * quotechar = '\''
+ * else:
+ * quotechar = '"' # <<<<<<<<<<<<<<
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar)
+ * tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.SystemID)
+ */
+ __pyx_v_quotechar = __pyx_k__25;
+ }
+ __pyx_L13:;
+
+ /* "src/lxml/serializer.pxi":303
* else:
- * tree.xmlOutputBufferWrite(c_buffer, 9, ' SYSTEM "')
+ * quotechar = '"'
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar) # <<<<<<<<<<<<<<
+ * tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.SystemID)
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar)
+ */
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 1, __pyx_v_quotechar);
+
+ /* "src/lxml/serializer.pxi":304
+ * quotechar = '"'
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar)
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.SystemID) # <<<<<<<<<<<<<<
- * tree.xmlOutputBufferWrite(c_buffer, 1, '"')
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar)
* if not c_dtd.entities and not c_dtd.elements and \
*/
xmlOutputBufferWriteString(__pyx_v_c_buffer, ((const char *)__pyx_v_c_dtd->SystemID));
- /* "src/lxml/serializer.pxi":298
- * tree.xmlOutputBufferWrite(c_buffer, 9, ' SYSTEM "')
+ /* "src/lxml/serializer.pxi":305
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar)
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.SystemID)
- * tree.xmlOutputBufferWrite(c_buffer, 1, '"') # <<<<<<<<<<<<<<
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar) # <<<<<<<<<<<<<<
* if not c_dtd.entities and not c_dtd.elements and \
* not c_dtd.attributes and not c_dtd.notations and \
*/
- xmlOutputBufferWrite(__pyx_v_c_buffer, 1, __pyx_k__54);
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 1, __pyx_v_quotechar);
goto __pyx_L7;
}
__pyx_L7:;
- /* "src/lxml/serializer.pxi":299
+ /* "src/lxml/serializer.pxi":306
* tree.xmlOutputBufferWriteString(c_buffer, <const_char*>c_dtd.SystemID)
- * tree.xmlOutputBufferWrite(c_buffer, 1, '"')
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar)
* if not c_dtd.entities and not c_dtd.elements and \ # <<<<<<<<<<<<<<
* not c_dtd.attributes and not c_dtd.notations and \
* not c_dtd.pentities:
if (__pyx_t_3) {
} else {
__pyx_t_2 = __pyx_t_3;
- goto __pyx_L14_bool_binop_done;
+ goto __pyx_L15_bool_binop_done;
}
__pyx_t_3 = ((!(__pyx_v_c_dtd->elements != 0)) != 0);
if (__pyx_t_3) {
} else {
__pyx_t_2 = __pyx_t_3;
- goto __pyx_L14_bool_binop_done;
+ goto __pyx_L15_bool_binop_done;
}
- /* "src/lxml/serializer.pxi":300
- * tree.xmlOutputBufferWrite(c_buffer, 1, '"')
+ /* "src/lxml/serializer.pxi":307
+ * tree.xmlOutputBufferWrite(c_buffer, 1, quotechar)
* if not c_dtd.entities and not c_dtd.elements and \
* not c_dtd.attributes and not c_dtd.notations and \ # <<<<<<<<<<<<<<
* not c_dtd.pentities:
if (__pyx_t_3) {
} else {
__pyx_t_2 = __pyx_t_3;
- goto __pyx_L14_bool_binop_done;
+ goto __pyx_L15_bool_binop_done;
}
__pyx_t_3 = ((!(__pyx_v_c_dtd->notations != 0)) != 0);
if (__pyx_t_3) {
} else {
__pyx_t_2 = __pyx_t_3;
- goto __pyx_L14_bool_binop_done;
+ goto __pyx_L15_bool_binop_done;
}
- /* "src/lxml/serializer.pxi":301
+ /* "src/lxml/serializer.pxi":308
* if not c_dtd.entities and not c_dtd.elements and \
* not c_dtd.attributes and not c_dtd.notations and \
* not c_dtd.pentities: # <<<<<<<<<<<<<<
*/
__pyx_t_3 = ((!(__pyx_v_c_dtd->pentities != 0)) != 0);
__pyx_t_2 = __pyx_t_3;
- __pyx_L14_bool_binop_done:;
+ __pyx_L15_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":302
+ /* "src/lxml/serializer.pxi":309
* not c_dtd.attributes and not c_dtd.notations and \
* not c_dtd.pentities:
* tree.xmlOutputBufferWrite(c_buffer, 2, '>\n') # <<<<<<<<<<<<<<
* return
* tree.xmlOutputBufferWrite(c_buffer, 3, ' [\n')
*/
- xmlOutputBufferWrite(__pyx_v_c_buffer, 2, __pyx_k__55);
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 2, __pyx_k__56);
- /* "src/lxml/serializer.pxi":303
+ /* "src/lxml/serializer.pxi":310
* not c_dtd.pentities:
* tree.xmlOutputBufferWrite(c_buffer, 2, '>\n')
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":304
+ /* "src/lxml/serializer.pxi":311
* tree.xmlOutputBufferWrite(c_buffer, 2, '>\n')
* return
* tree.xmlOutputBufferWrite(c_buffer, 3, ' [\n') # <<<<<<<<<<<<<<
* if c_dtd.notations and not c_buffer.error:
* c_buf = tree.xmlBufferCreate()
*/
- xmlOutputBufferWrite(__pyx_v_c_buffer, 3, __pyx_k__56);
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 3, __pyx_k__57);
- /* "src/lxml/serializer.pxi":305
+ /* "src/lxml/serializer.pxi":312
* return
* tree.xmlOutputBufferWrite(c_buffer, 3, ' [\n')
* if c_dtd.notations and not c_buffer.error: # <<<<<<<<<<<<<<
if (__pyx_t_3) {
} else {
__pyx_t_2 = __pyx_t_3;
- goto __pyx_L20_bool_binop_done;
+ goto __pyx_L21_bool_binop_done;
}
__pyx_t_3 = ((!(__pyx_v_c_buffer->error != 0)) != 0);
__pyx_t_2 = __pyx_t_3;
- __pyx_L20_bool_binop_done:;
+ __pyx_L21_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":306
+ /* "src/lxml/serializer.pxi":313
* tree.xmlOutputBufferWrite(c_buffer, 3, ' [\n')
* if c_dtd.notations and not c_buffer.error:
* c_buf = tree.xmlBufferCreate() # <<<<<<<<<<<<<<
*/
__pyx_v_c_buf = xmlBufferCreate();
- /* "src/lxml/serializer.pxi":307
+ /* "src/lxml/serializer.pxi":314
* if c_dtd.notations and not c_buffer.error:
* c_buf = tree.xmlBufferCreate()
* if not c_buf: # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(__pyx_v_c_buf != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":308
+ /* "src/lxml/serializer.pxi":315
* c_buf = tree.xmlBufferCreate()
* if not c_buf:
* c_buffer.error = xmlerror.XML_ERR_NO_MEMORY # <<<<<<<<<<<<<<
*/
__pyx_v_c_buffer->error = XML_ERR_NO_MEMORY;
- /* "src/lxml/serializer.pxi":309
+ /* "src/lxml/serializer.pxi":316
* if not c_buf:
* c_buffer.error = xmlerror.XML_ERR_NO_MEMORY
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":310
+ /* "src/lxml/serializer.pxi":317
* c_buffer.error = xmlerror.XML_ERR_NO_MEMORY
* return
* tree.xmlDumpNotationTable(c_buf, <tree.xmlNotationTable*>c_dtd.notations) # <<<<<<<<<<<<<<
*/
xmlDumpNotationTable(__pyx_v_c_buf, ((xmlNotationTable *)__pyx_v_c_dtd->notations));
- /* "src/lxml/serializer.pxi":311
+ /* "src/lxml/serializer.pxi":318
* return
* tree.xmlDumpNotationTable(c_buf, <tree.xmlNotationTable*>c_dtd.notations)
* tree.xmlOutputBufferWrite( # <<<<<<<<<<<<<<
*/
xmlOutputBufferWrite(__pyx_v_c_buffer, xmlBufferLength(__pyx_v_c_buf), ((const char *)xmlBufferContent(__pyx_v_c_buf)));
- /* "src/lxml/serializer.pxi":314
+ /* "src/lxml/serializer.pxi":321
* c_buffer, tree.xmlBufferLength(c_buf),
* <const_char*>tree.xmlBufferContent(c_buf))
* tree.xmlBufferFree(c_buf) # <<<<<<<<<<<<<<
* while c_node and not c_buffer.error:
*/
xmlBufferFree(__pyx_v_c_buf);
- goto __pyx_L19;
+ goto __pyx_L20;
}
- __pyx_L19:;
+ __pyx_L20:;
- /* "src/lxml/serializer.pxi":315
+ /* "src/lxml/serializer.pxi":322
* <const_char*>tree.xmlBufferContent(c_buf))
* tree.xmlBufferFree(c_buf)
* c_node = c_dtd.children # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_c_dtd->children;
__pyx_v_c_node = __pyx_t_4;
- /* "src/lxml/serializer.pxi":316
+ /* "src/lxml/serializer.pxi":323
* tree.xmlBufferFree(c_buf)
* c_node = c_dtd.children
* while c_node and not c_buffer.error: # <<<<<<<<<<<<<<
if (__pyx_t_3) {
} else {
__pyx_t_2 = __pyx_t_3;
- goto __pyx_L25_bool_binop_done;
+ goto __pyx_L26_bool_binop_done;
}
__pyx_t_3 = ((!(__pyx_v_c_buffer->error != 0)) != 0);
__pyx_t_2 = __pyx_t_3;
- __pyx_L25_bool_binop_done:;
+ __pyx_L26_bool_binop_done:;
if (!__pyx_t_2) break;
- /* "src/lxml/serializer.pxi":317
+ /* "src/lxml/serializer.pxi":324
* c_node = c_dtd.children
* while c_node and not c_buffer.error:
* tree.xmlNodeDumpOutput(c_buffer, c_node.doc, c_node, 0, 0, encoding) # <<<<<<<<<<<<<<
*/
xmlNodeDumpOutput(__pyx_v_c_buffer, __pyx_v_c_node->doc, __pyx_v_c_node, 0, 0, __pyx_v_encoding);
- /* "src/lxml/serializer.pxi":318
+ /* "src/lxml/serializer.pxi":325
* while c_node and not c_buffer.error:
* tree.xmlNodeDumpOutput(c_buffer, c_node.doc, c_node, 0, 0, encoding)
* c_node = c_node.next # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_t_4;
}
- /* "src/lxml/serializer.pxi":319
+ /* "src/lxml/serializer.pxi":326
* tree.xmlNodeDumpOutput(c_buffer, c_node.doc, c_node, 0, 0, encoding)
* c_node = c_node.next
* tree.xmlOutputBufferWrite(c_buffer, 3, "]>\n") # <<<<<<<<<<<<<<
*
* cdef void _writeTail(tree.xmlOutputBuffer* c_buffer, xmlNode* c_node,
*/
- xmlOutputBufferWrite(__pyx_v_c_buffer, 3, __pyx_k__57);
+ xmlOutputBufferWrite(__pyx_v_c_buffer, 3, __pyx_k__58);
/* "src/lxml/serializer.pxi":278
* tree.xmlOutputBufferWrite(c_buffer, 4, "'?>\n")
__pyx_L0:;
}
-/* "src/lxml/serializer.pxi":321
+/* "src/lxml/serializer.pxi":328
* tree.xmlOutputBufferWrite(c_buffer, 3, "]>\n")
*
* cdef void _writeTail(tree.xmlOutputBuffer* c_buffer, xmlNode* c_node, # <<<<<<<<<<<<<<
int __pyx_t_3;
int __pyx_t_4;
- /* "src/lxml/serializer.pxi":324
+ /* "src/lxml/serializer.pxi":331
* const_char* encoding, int c_method, bint pretty_print) nogil:
* u"Write the element tail."
* c_node = c_node.next # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_c_node->next;
__pyx_v_c_node = __pyx_t_1;
- /* "src/lxml/serializer.pxi":325
+ /* "src/lxml/serializer.pxi":332
* u"Write the element tail."
* c_node = c_node.next
* while c_node and not c_buffer.error and c_node.type in ( # <<<<<<<<<<<<<<
}
switch (__pyx_v_c_node->type) {
- /* "src/lxml/serializer.pxi":326
+ /* "src/lxml/serializer.pxi":333
* c_node = c_node.next
* while c_node and not c_buffer.error and c_node.type in (
* tree.XML_TEXT_NODE, tree.XML_CDATA_SECTION_NODE): # <<<<<<<<<<<<<<
case XML_TEXT_NODE:
case XML_CDATA_SECTION_NODE:
- /* "src/lxml/serializer.pxi":325
+ /* "src/lxml/serializer.pxi":332
* u"Write the element tail."
* c_node = c_node.next
* while c_node and not c_buffer.error and c_node.type in ( # <<<<<<<<<<<<<<
__pyx_L5_bool_binop_done:;
if (!__pyx_t_2) break;
- /* "src/lxml/serializer.pxi":327
+ /* "src/lxml/serializer.pxi":334
* while c_node and not c_buffer.error and c_node.type in (
* tree.XML_TEXT_NODE, tree.XML_CDATA_SECTION_NODE):
* if c_method == OUTPUT_METHOD_HTML: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_method == __pyx_e_4lxml_5etree_OUTPUT_METHOD_HTML) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":328
+ /* "src/lxml/serializer.pxi":335
* tree.XML_TEXT_NODE, tree.XML_CDATA_SECTION_NODE):
* if c_method == OUTPUT_METHOD_HTML:
* tree.htmlNodeDumpFormatOutput( # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":331
+ /* "src/lxml/serializer.pxi":338
* c_buffer, c_node.doc, c_node, encoding, pretty_print)
* else:
* tree.xmlNodeDumpOutput( # <<<<<<<<<<<<<<
}
__pyx_L8:;
- /* "src/lxml/serializer.pxi":333
+ /* "src/lxml/serializer.pxi":340
* tree.xmlNodeDumpOutput(
* c_buffer, c_node.doc, c_node, 0, pretty_print, encoding)
* c_node = c_node.next # <<<<<<<<<<<<<<
__pyx_v_c_node = __pyx_t_1;
}
- /* "src/lxml/serializer.pxi":321
+ /* "src/lxml/serializer.pxi":328
* tree.xmlOutputBufferWrite(c_buffer, 3, "]>\n")
*
* cdef void _writeTail(tree.xmlOutputBuffer* c_buffer, xmlNode* c_node, # <<<<<<<<<<<<<<
/* function exit code */
}
-/* "src/lxml/serializer.pxi":335
+/* "src/lxml/serializer.pxi":342
* c_node = c_node.next
*
* cdef void _writePrevSiblings(tree.xmlOutputBuffer* c_buffer, xmlNode* c_node, # <<<<<<<<<<<<<<
int __pyx_t_2;
xmlNode *__pyx_t_3;
- /* "src/lxml/serializer.pxi":338
+ /* "src/lxml/serializer.pxi":345
* const_char* encoding, bint pretty_print) nogil:
* cdef xmlNode* c_sibling
* if c_node.parent and _isElement(c_node.parent): # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":339
+ /* "src/lxml/serializer.pxi":346
* cdef xmlNode* c_sibling
* if c_node.parent and _isElement(c_node.parent):
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":341
+ /* "src/lxml/serializer.pxi":348
* return
* # we are at a root node, so add PI and comment siblings
* c_sibling = c_node # <<<<<<<<<<<<<<
*/
__pyx_v_c_sibling = __pyx_v_c_node;
- /* "src/lxml/serializer.pxi":342
+ /* "src/lxml/serializer.pxi":349
* # we are at a root node, so add PI and comment siblings
* c_sibling = c_node
* while c_sibling.prev and \ # <<<<<<<<<<<<<<
goto __pyx_L8_bool_binop_done;
}
- /* "src/lxml/serializer.pxi":343
+ /* "src/lxml/serializer.pxi":350
* c_sibling = c_node
* while c_sibling.prev and \
* (c_sibling.prev.type == tree.XML_PI_NODE or # <<<<<<<<<<<<<<
switch (__pyx_v_c_sibling->prev->type) {
case XML_PI_NODE:
- /* "src/lxml/serializer.pxi":344
+ /* "src/lxml/serializer.pxi":351
* while c_sibling.prev and \
* (c_sibling.prev.type == tree.XML_PI_NODE or
* c_sibling.prev.type == tree.XML_COMMENT_NODE): # <<<<<<<<<<<<<<
*/
case XML_COMMENT_NODE:
- /* "src/lxml/serializer.pxi":343
+ /* "src/lxml/serializer.pxi":350
* c_sibling = c_node
* while c_sibling.prev and \
* (c_sibling.prev.type == tree.XML_PI_NODE or # <<<<<<<<<<<<<<
__pyx_L8_bool_binop_done:;
if (!__pyx_t_1) break;
- /* "src/lxml/serializer.pxi":345
+ /* "src/lxml/serializer.pxi":352
* (c_sibling.prev.type == tree.XML_PI_NODE or
* c_sibling.prev.type == tree.XML_COMMENT_NODE):
* c_sibling = c_sibling.prev # <<<<<<<<<<<<<<
__pyx_v_c_sibling = __pyx_t_3;
}
- /* "src/lxml/serializer.pxi":346
+ /* "src/lxml/serializer.pxi":353
* c_sibling.prev.type == tree.XML_COMMENT_NODE):
* c_sibling = c_sibling.prev
* while c_sibling is not c_node and not c_buffer.error: # <<<<<<<<<<<<<<
__pyx_L12_bool_binop_done:;
if (!__pyx_t_1) break;
- /* "src/lxml/serializer.pxi":347
+ /* "src/lxml/serializer.pxi":354
* c_sibling = c_sibling.prev
* while c_sibling is not c_node and not c_buffer.error:
* tree.xmlNodeDumpOutput(c_buffer, c_node.doc, c_sibling, 0, # <<<<<<<<<<<<<<
*/
xmlNodeDumpOutput(__pyx_v_c_buffer, __pyx_v_c_node->doc, __pyx_v_c_sibling, 0, __pyx_v_pretty_print, __pyx_v_encoding);
- /* "src/lxml/serializer.pxi":349
+ /* "src/lxml/serializer.pxi":356
* tree.xmlNodeDumpOutput(c_buffer, c_node.doc, c_sibling, 0,
* pretty_print, encoding)
* if pretty_print: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_pretty_print != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":350
+ /* "src/lxml/serializer.pxi":357
* pretty_print, encoding)
* if pretty_print:
* tree.xmlOutputBufferWriteString(c_buffer, "\n") # <<<<<<<<<<<<<<
}
__pyx_L14:;
- /* "src/lxml/serializer.pxi":351
+ /* "src/lxml/serializer.pxi":358
* if pretty_print:
* tree.xmlOutputBufferWriteString(c_buffer, "\n")
* c_sibling = c_sibling.next # <<<<<<<<<<<<<<
__pyx_v_c_sibling = __pyx_t_3;
}
- /* "src/lxml/serializer.pxi":335
+ /* "src/lxml/serializer.pxi":342
* c_node = c_node.next
*
* cdef void _writePrevSiblings(tree.xmlOutputBuffer* c_buffer, xmlNode* c_node, # <<<<<<<<<<<<<<
__pyx_L0:;
}
-/* "src/lxml/serializer.pxi":353
+/* "src/lxml/serializer.pxi":360
* c_sibling = c_sibling.next
*
* cdef void _writeNextSiblings(tree.xmlOutputBuffer* c_buffer, xmlNode* c_node, # <<<<<<<<<<<<<<
int __pyx_t_2;
xmlNode *__pyx_t_3;
- /* "src/lxml/serializer.pxi":356
+ /* "src/lxml/serializer.pxi":363
* const_char* encoding, bint pretty_print) nogil:
* cdef xmlNode* c_sibling
* if c_node.parent and _isElement(c_node.parent): # <<<<<<<<<<<<<<
__pyx_L4_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":357
+ /* "src/lxml/serializer.pxi":364
* cdef xmlNode* c_sibling
* if c_node.parent and _isElement(c_node.parent):
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":359
+ /* "src/lxml/serializer.pxi":366
* return
* # we are at a root node, so add PI and comment siblings
* c_sibling = c_node.next # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_c_node->next;
__pyx_v_c_sibling = __pyx_t_3;
- /* "src/lxml/serializer.pxi":360
+ /* "src/lxml/serializer.pxi":367
* # we are at a root node, so add PI and comment siblings
* c_sibling = c_node.next
* while not c_buffer.error and c_sibling and \ # <<<<<<<<<<<<<<
goto __pyx_L8_bool_binop_done;
}
- /* "src/lxml/serializer.pxi":361
+ /* "src/lxml/serializer.pxi":368
* c_sibling = c_node.next
* while not c_buffer.error and c_sibling and \
* (c_sibling.type == tree.XML_PI_NODE or # <<<<<<<<<<<<<<
switch (__pyx_v_c_sibling->type) {
case XML_PI_NODE:
- /* "src/lxml/serializer.pxi":362
+ /* "src/lxml/serializer.pxi":369
* while not c_buffer.error and c_sibling and \
* (c_sibling.type == tree.XML_PI_NODE or
* c_sibling.type == tree.XML_COMMENT_NODE): # <<<<<<<<<<<<<<
*/
case XML_COMMENT_NODE:
- /* "src/lxml/serializer.pxi":361
+ /* "src/lxml/serializer.pxi":368
* c_sibling = c_node.next
* while not c_buffer.error and c_sibling and \
* (c_sibling.type == tree.XML_PI_NODE or # <<<<<<<<<<<<<<
__pyx_L8_bool_binop_done:;
if (!__pyx_t_1) break;
- /* "src/lxml/serializer.pxi":363
+ /* "src/lxml/serializer.pxi":370
* (c_sibling.type == tree.XML_PI_NODE or
* c_sibling.type == tree.XML_COMMENT_NODE):
* if pretty_print: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_pretty_print != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":364
+ /* "src/lxml/serializer.pxi":371
* c_sibling.type == tree.XML_COMMENT_NODE):
* if pretty_print:
* tree.xmlOutputBufferWriteString(c_buffer, "\n") # <<<<<<<<<<<<<<
}
__pyx_L11:;
- /* "src/lxml/serializer.pxi":365
+ /* "src/lxml/serializer.pxi":372
* if pretty_print:
* tree.xmlOutputBufferWriteString(c_buffer, "\n")
* tree.xmlNodeDumpOutput(c_buffer, c_node.doc, c_sibling, 0, # <<<<<<<<<<<<<<
*/
xmlNodeDumpOutput(__pyx_v_c_buffer, __pyx_v_c_node->doc, __pyx_v_c_sibling, 0, __pyx_v_pretty_print, __pyx_v_encoding);
- /* "src/lxml/serializer.pxi":367
+ /* "src/lxml/serializer.pxi":374
* tree.xmlNodeDumpOutput(c_buffer, c_node.doc, c_sibling, 0,
* pretty_print, encoding)
* c_sibling = c_sibling.next # <<<<<<<<<<<<<<
__pyx_v_c_sibling = __pyx_t_3;
}
- /* "src/lxml/serializer.pxi":353
+ /* "src/lxml/serializer.pxi":360
* c_sibling = c_sibling.next
*
* cdef void _writeNextSiblings(tree.xmlOutputBuffer* c_buffer, xmlNode* c_node, # <<<<<<<<<<<<<<
__pyx_L0:;
}
-/* "src/lxml/serializer.pxi":379
+/* "src/lxml/serializer.pxi":386
* cdef _ExceptionContext _exc_context
* cdef _ErrorLog error_log
* def __cinit__(self, filelike, exc_context=None, compression=None, close=False): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 379; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 386; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 4, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 379; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 0, 1, 4, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 386; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._FilelikeWriter.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_RefNannySetupContext("__cinit__", 0);
__Pyx_INCREF(__pyx_v_filelike);
- /* "src/lxml/serializer.pxi":380
+ /* "src/lxml/serializer.pxi":387
* cdef _ErrorLog error_log
* def __cinit__(self, filelike, exc_context=None, compression=None, close=False):
* if compression is not None and compression > 0: # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_t_3;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_compression, __pyx_int_0, Py_GT); __Pyx_XGOTREF(__pyx_t_4); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 380; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 380; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_compression, __pyx_int_0, Py_GT); __Pyx_XGOTREF(__pyx_t_4); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_t_1 = __pyx_t_3;
__pyx_L4_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":381
+ /* "src/lxml/serializer.pxi":388
* def __cinit__(self, filelike, exc_context=None, compression=None, close=False):
* if compression is not None and compression > 0:
* filelike = GzipFile( # <<<<<<<<<<<<<<
* fileobj=filelike, mode='wb', compresslevel=compression)
* self._close_filelike = filelike.close
*/
- __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- /* "src/lxml/serializer.pxi":382
+ /* "src/lxml/serializer.pxi":389
* if compression is not None and compression > 0:
* filelike = GzipFile(
* fileobj=filelike, mode='wb', compresslevel=compression) # <<<<<<<<<<<<<<
* self._close_filelike = filelike.close
* elif close:
*/
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_fileobj, __pyx_v_filelike) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_mode, __pyx_n_s_wb) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_compresslevel, __pyx_v_compression) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_fileobj, __pyx_v_filelike) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_mode, __pyx_n_s_wb) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_compresslevel, __pyx_v_compression) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/serializer.pxi":381
+ /* "src/lxml/serializer.pxi":388
* def __cinit__(self, filelike, exc_context=None, compression=None, close=False):
* if compression is not None and compression > 0:
* filelike = GzipFile( # <<<<<<<<<<<<<<
* fileobj=filelike, mode='wb', compresslevel=compression)
* self._close_filelike = filelike.close
*/
- __pyx_t_5 = __Pyx_PyObject_Call(__pyx_v_4lxml_5etree_GzipFile, __pyx_empty_tuple, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(__pyx_v_4lxml_5etree_GzipFile, __pyx_empty_tuple, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF_SET(__pyx_v_filelike, __pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":383
+ /* "src/lxml/serializer.pxi":390
* filelike = GzipFile(
* fileobj=filelike, mode='wb', compresslevel=compression)
* self._close_filelike = filelike.close # <<<<<<<<<<<<<<
* elif close:
* self._close_filelike = filelike.close
*/
- __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_filelike, __pyx_n_s_close); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_filelike, __pyx_n_s_close); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 390; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
__Pyx_GOTREF(__pyx_v_self->_close_filelike);
goto __pyx_L3;
}
- /* "src/lxml/serializer.pxi":384
+ /* "src/lxml/serializer.pxi":391
* fileobj=filelike, mode='wb', compresslevel=compression)
* self._close_filelike = filelike.close
* elif close: # <<<<<<<<<<<<<<
* self._close_filelike = filelike.close
* self._filelike = filelike
*/
- __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_close); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 384; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_close); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 391; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":385
+ /* "src/lxml/serializer.pxi":392
* self._close_filelike = filelike.close
* elif close:
* self._close_filelike = filelike.close # <<<<<<<<<<<<<<
* self._filelike = filelike
* if exc_context is None:
*/
- __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_filelike, __pyx_n_s_close); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 385; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_filelike, __pyx_n_s_close); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 392; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
__Pyx_GOTREF(__pyx_v_self->_close_filelike);
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":386
+ /* "src/lxml/serializer.pxi":393
* elif close:
* self._close_filelike = filelike.close
* self._filelike = filelike # <<<<<<<<<<<<<<
__Pyx_DECREF(__pyx_v_self->_filelike);
__pyx_v_self->_filelike = __pyx_v_filelike;
- /* "src/lxml/serializer.pxi":387
+ /* "src/lxml/serializer.pxi":394
* self._close_filelike = filelike.close
* self._filelike = filelike
* if exc_context is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_1 != 0);
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":388
+ /* "src/lxml/serializer.pxi":395
* self._filelike = filelike
* if exc_context is None:
* self._exc_context = _ExceptionContext() # <<<<<<<<<<<<<<
* else:
* self._exc_context = exc_context
*/
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ExceptionContext)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 388; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ExceptionContext)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
__Pyx_GOTREF(__pyx_v_self->_exc_context);
}
/*else*/ {
- /* "src/lxml/serializer.pxi":390
+ /* "src/lxml/serializer.pxi":397
* self._exc_context = _ExceptionContext()
* else:
* self._exc_context = exc_context # <<<<<<<<<<<<<<
* self.error_log = _ErrorLog()
*
*/
- if (!(likely(((__pyx_v_exc_context) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_exc_context, __pyx_ptype_4lxml_5etree__ExceptionContext))))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 390; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_v_exc_context) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_exc_context, __pyx_ptype_4lxml_5etree__ExceptionContext))))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 397; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_5 = __pyx_v_exc_context;
__Pyx_INCREF(__pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
}
__pyx_L6:;
- /* "src/lxml/serializer.pxi":391
+ /* "src/lxml/serializer.pxi":398
* else:
* self._exc_context = exc_context
* self.error_log = _ErrorLog() # <<<<<<<<<<<<<<
*
* cdef tree.xmlOutputBuffer* _createOutputBuffer(
*/
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ErrorLog)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 391; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ErrorLog)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
__Pyx_GOTREF(__pyx_v_self->error_log);
__pyx_v_self->error_log = ((struct __pyx_obj_4lxml_5etree__ErrorLog *)__pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":379
+ /* "src/lxml/serializer.pxi":386
* cdef _ExceptionContext _exc_context
* cdef _ErrorLog error_log
* def __cinit__(self, filelike, exc_context=None, compression=None, close=False): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":393
+/* "src/lxml/serializer.pxi":400
* self.error_log = _ErrorLog()
*
* cdef tree.xmlOutputBuffer* _createOutputBuffer( # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_createOutputBuffer", 0);
- /* "src/lxml/serializer.pxi":396
+ /* "src/lxml/serializer.pxi":403
* self, tree.xmlCharEncodingHandler* enchandler) except NULL:
* cdef tree.xmlOutputBuffer* c_buffer
* c_buffer = tree.xmlOutputBufferCreateIO( # <<<<<<<<<<<<<<
*/
__pyx_v_c_buffer = xmlOutputBufferCreateIO(((xmlOutputWriteCallback)__pyx_f_4lxml_5etree__writeFilelikeWriter), __pyx_f_4lxml_5etree__closeFilelikeWriter, ((PyObject *)__pyx_v_self), __pyx_v_enchandler);
- /* "src/lxml/serializer.pxi":399
+ /* "src/lxml/serializer.pxi":406
* <tree.xmlOutputWriteCallback>_writeFilelikeWriter, _closeFilelikeWriter,
* <python.PyObject*>self, enchandler)
* if c_buffer is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_buffer == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":400
+ /* "src/lxml/serializer.pxi":407
* <python.PyObject*>self, enchandler)
* if c_buffer is NULL:
* raise IOError, u"Could not create I/O writer context." # <<<<<<<<<<<<<<
*
*/
__Pyx_Raise(__pyx_builtin_IOError, __pyx_kp_u_Could_not_create_I_O_writer_cont, 0, 0);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 400; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 407; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":401
+ /* "src/lxml/serializer.pxi":408
* if c_buffer is NULL:
* raise IOError, u"Could not create I/O writer context."
* return c_buffer # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_c_buffer;
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":393
+ /* "src/lxml/serializer.pxi":400
* self.error_log = _ErrorLog()
*
* cdef tree.xmlOutputBuffer* _createOutputBuffer( # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":403
+/* "src/lxml/serializer.pxi":410
* return c_buffer
*
* cdef int write(self, char* c_buffer, int size): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("write", 0);
- /* "src/lxml/serializer.pxi":404
+ /* "src/lxml/serializer.pxi":411
*
* cdef int write(self, char* c_buffer, int size):
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_3);
/*try:*/ {
- /* "src/lxml/serializer.pxi":405
+ /* "src/lxml/serializer.pxi":412
* cdef int write(self, char* c_buffer, int size):
* try:
* if self._filelike is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/serializer.pxi":406
+ /* "src/lxml/serializer.pxi":413
* try:
* if self._filelike is None:
* raise IOError, u"File is already closed" # <<<<<<<<<<<<<<
* self._filelike.write(py_buffer)
*/
__Pyx_Raise(__pyx_builtin_IOError, __pyx_kp_u_File_is_already_closed, 0, 0);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 406; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 413; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
}
- /* "src/lxml/serializer.pxi":407
+ /* "src/lxml/serializer.pxi":414
* if self._filelike is None:
* raise IOError, u"File is already closed"
* py_buffer = <bytes>c_buffer[:size] # <<<<<<<<<<<<<<
* self._filelike.write(py_buffer)
* except:
*/
- __pyx_t_6 = __Pyx_PyBytes_FromStringAndSize(__pyx_v_c_buffer + 0, __pyx_v_size - 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 407; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_6 = __Pyx_PyBytes_FromStringAndSize(__pyx_v_c_buffer + 0, __pyx_v_size - 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 414; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_t_7 = __pyx_t_6;
__Pyx_INCREF(__pyx_t_7);
__pyx_v_py_buffer = ((PyObject*)__pyx_t_7);
__pyx_t_7 = 0;
- /* "src/lxml/serializer.pxi":408
+ /* "src/lxml/serializer.pxi":415
* raise IOError, u"File is already closed"
* py_buffer = <bytes>c_buffer[:size]
* self._filelike.write(py_buffer) # <<<<<<<<<<<<<<
* except:
* size = -1
*/
- __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->_filelike, __pyx_n_s_write); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 408; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->_filelike, __pyx_n_s_write); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 415; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_t_8 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_6))) {
}
}
if (!__pyx_t_8) {
- __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_py_buffer); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 408; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_py_buffer); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 415; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_7);
} else {
- __pyx_t_9 = PyTuple_New(1+1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 408; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_9 = PyTuple_New(1+1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 415; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_9);
PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_8); __pyx_t_8 = NULL;
__Pyx_INCREF(__pyx_v_py_buffer);
PyTuple_SET_ITEM(__pyx_t_9, 0+1, __pyx_v_py_buffer);
__Pyx_GIVEREF(__pyx_v_py_buffer);
- __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 408; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 415; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
}
__Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
- /* "src/lxml/serializer.pxi":409
+ /* "src/lxml/serializer.pxi":416
* py_buffer = <bytes>c_buffer[:size]
* self._filelike.write(py_buffer)
* except: # <<<<<<<<<<<<<<
*/
/*except:*/ {
__Pyx_AddTraceback("lxml.etree._FilelikeWriter.write", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_6, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 409; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
+ if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_6, &__pyx_t_9) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 416; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_9);
- /* "src/lxml/serializer.pxi":410
+ /* "src/lxml/serializer.pxi":417
* self._filelike.write(py_buffer)
* except:
* size = -1 # <<<<<<<<<<<<<<
*/
__pyx_v_size = -1;
- /* "src/lxml/serializer.pxi":411
+ /* "src/lxml/serializer.pxi":418
* except:
* size = -1
* self._exc_context._store_raised() # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/serializer.pxi":413
+ /* "src/lxml/serializer.pxi":420
* self._exc_context._store_raised()
* finally:
* return size # and swallow any further exceptions # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/serializer.pxi":403
+ /* "src/lxml/serializer.pxi":410
* return c_buffer
*
* cdef int write(self, char* c_buffer, int size): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":415
+/* "src/lxml/serializer.pxi":422
* return size # and swallow any further exceptions
*
* cdef int close(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("close", 0);
- /* "src/lxml/serializer.pxi":416
+ /* "src/lxml/serializer.pxi":423
*
* cdef int close(self):
* retval = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_retval = 0;
- /* "src/lxml/serializer.pxi":417
+ /* "src/lxml/serializer.pxi":424
* cdef int close(self):
* retval = 0
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_3);
/*try:*/ {
- /* "src/lxml/serializer.pxi":418
+ /* "src/lxml/serializer.pxi":425
* retval = 0
* try:
* if self._close_filelike is not None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_4 != 0);
if (__pyx_t_5) {
- /* "src/lxml/serializer.pxi":419
+ /* "src/lxml/serializer.pxi":426
* try:
* if self._close_filelike is not None:
* self._close_filelike() # <<<<<<<<<<<<<<
}
}
if (__pyx_t_8) {
- __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 426; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
} else {
- __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 426; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
}
__pyx_L14:;
- /* "src/lxml/serializer.pxi":421
+ /* "src/lxml/serializer.pxi":428
* self._close_filelike()
* # we should not close the file here as we didn't open it
* self._filelike = None # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":422
+ /* "src/lxml/serializer.pxi":429
* # we should not close the file here as we didn't open it
* self._filelike = None
* except: # <<<<<<<<<<<<<<
*/
/*except:*/ {
__Pyx_AddTraceback("lxml.etree._FilelikeWriter.close", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 422; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
+ if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 429; __pyx_clineno = __LINE__; goto __pyx_L8_except_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_7);
__Pyx_GOTREF(__pyx_t_8);
- /* "src/lxml/serializer.pxi":423
+ /* "src/lxml/serializer.pxi":430
* self._filelike = None
* except:
* retval = -1 # <<<<<<<<<<<<<<
*/
__pyx_v_retval = -1;
- /* "src/lxml/serializer.pxi":424
+ /* "src/lxml/serializer.pxi":431
* except:
* retval = -1
* self._exc_context._store_raised() # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/serializer.pxi":426
+ /* "src/lxml/serializer.pxi":433
* self._exc_context._store_raised()
* finally:
* return retval # and swallow any further exceptions # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/serializer.pxi":415
+ /* "src/lxml/serializer.pxi":422
* return size # and swallow any further exceptions
*
* cdef int close(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":428
+/* "src/lxml/serializer.pxi":435
* return retval # and swallow any further exceptions
*
* cdef int _writeFilelikeWriter(void* ctxt, char* c_buffer, int length): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("_writeFilelikeWriter", 0);
- /* "src/lxml/serializer.pxi":429
+ /* "src/lxml/serializer.pxi":436
*
* cdef int _writeFilelikeWriter(void* ctxt, char* c_buffer, int length):
* return (<_FilelikeWriter>ctxt).write(c_buffer, length) # <<<<<<<<<<<<<<
__pyx_r = __pyx_f_4lxml_5etree_15_FilelikeWriter_write(((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)__pyx_v_ctxt), __pyx_v_c_buffer, __pyx_v_length);
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":428
+ /* "src/lxml/serializer.pxi":435
* return retval # and swallow any further exceptions
*
* cdef int _writeFilelikeWriter(void* ctxt, char* c_buffer, int length): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":431
+/* "src/lxml/serializer.pxi":438
* return (<_FilelikeWriter>ctxt).write(c_buffer, length)
*
* cdef int _closeFilelikeWriter(void* ctxt): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("_closeFilelikeWriter", 0);
- /* "src/lxml/serializer.pxi":432
+ /* "src/lxml/serializer.pxi":439
*
* cdef int _closeFilelikeWriter(void* ctxt):
* return (<_FilelikeWriter>ctxt).close() # <<<<<<<<<<<<<<
__pyx_r = __pyx_f_4lxml_5etree_15_FilelikeWriter_close(((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)__pyx_v_ctxt));
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":431
+ /* "src/lxml/serializer.pxi":438
* return (<_FilelikeWriter>ctxt).write(c_buffer, length)
*
* cdef int _closeFilelikeWriter(void* ctxt): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":434
+/* "src/lxml/serializer.pxi":441
* return (<_FilelikeWriter>ctxt).close()
*
* cdef _tofilelike(f, _Element element, encoding, doctype, method, # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_v_encoding);
__Pyx_INCREF(__pyx_v_doctype);
- /* "src/lxml/serializer.pxi":438
+ /* "src/lxml/serializer.pxi":445
* bint pretty_print, bint with_tail, int standalone,
* int compression):
* cdef python.PyThreadState* state = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_state = NULL;
- /* "src/lxml/serializer.pxi":439
+ /* "src/lxml/serializer.pxi":446
* int compression):
* cdef python.PyThreadState* state = NULL
* cdef _FilelikeWriter writer = None # <<<<<<<<<<<<<<
__Pyx_INCREF(Py_None);
__pyx_v_writer = ((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)Py_None);
- /* "src/lxml/serializer.pxi":446
+ /* "src/lxml/serializer.pxi":453
* cdef int error_result
*
* c_method = _findOutputMethod(method) # <<<<<<<<<<<<<<
* if c_method == OUTPUT_METHOD_TEXT:
* data = _textToString(element._c_node, encoding, with_tail)
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__findOutputMethod(__pyx_v_method); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 446; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__findOutputMethod(__pyx_v_method); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 453; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_method = __pyx_t_1;
- /* "src/lxml/serializer.pxi":447
+ /* "src/lxml/serializer.pxi":454
*
* c_method = _findOutputMethod(method)
* if c_method == OUTPUT_METHOD_TEXT: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_method == __pyx_e_4lxml_5etree_OUTPUT_METHOD_TEXT) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":448
+ /* "src/lxml/serializer.pxi":455
* c_method = _findOutputMethod(method)
* if c_method == OUTPUT_METHOD_TEXT:
* data = _textToString(element._c_node, encoding, with_tail) # <<<<<<<<<<<<<<
* if compression:
* bytes_out = BytesIO()
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__textToString(__pyx_v_element->_c_node, __pyx_v_encoding, __pyx_v_with_tail); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 448; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__textToString(__pyx_v_element->_c_node, __pyx_v_encoding, __pyx_v_with_tail); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 455; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_data = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":449
+ /* "src/lxml/serializer.pxi":456
* if c_method == OUTPUT_METHOD_TEXT:
* data = _textToString(element._c_node, encoding, with_tail)
* if compression: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_v_compression != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":450
+ /* "src/lxml/serializer.pxi":457
* data = _textToString(element._c_node, encoding, with_tail)
* if compression:
* bytes_out = BytesIO() # <<<<<<<<<<<<<<
}
}
if (__pyx_t_5) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 450; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 450; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_v_bytes_out = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":451
+ /* "src/lxml/serializer.pxi":458
* if compression:
* bytes_out = BytesIO()
* gzip_file = GzipFile( # <<<<<<<<<<<<<<
* fileobj=bytes_out, mode='wb', compresslevel=compression)
* try:
*/
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 458; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- /* "src/lxml/serializer.pxi":452
+ /* "src/lxml/serializer.pxi":459
* bytes_out = BytesIO()
* gzip_file = GzipFile(
* fileobj=bytes_out, mode='wb', compresslevel=compression) # <<<<<<<<<<<<<<
* try:
* gzip_file.write(data)
*/
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_fileobj, __pyx_v_bytes_out) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_mode, __pyx_n_s_wb) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_compression); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 452; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_fileobj, __pyx_v_bytes_out) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 458; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_mode, __pyx_n_s_wb) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 458; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_compression); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 459; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_compresslevel, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_compresslevel, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 458; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":451
+ /* "src/lxml/serializer.pxi":458
* if compression:
* bytes_out = BytesIO()
* gzip_file = GzipFile( # <<<<<<<<<<<<<<
* fileobj=bytes_out, mode='wb', compresslevel=compression)
* try:
*/
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_v_4lxml_5etree_GzipFile, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_v_4lxml_5etree_GzipFile, __pyx_empty_tuple, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 458; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_gzip_file = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":453
+ /* "src/lxml/serializer.pxi":460
* gzip_file = GzipFile(
* fileobj=bytes_out, mode='wb', compresslevel=compression)
* try: # <<<<<<<<<<<<<<
*/
/*try:*/ {
- /* "src/lxml/serializer.pxi":454
+ /* "src/lxml/serializer.pxi":461
* fileobj=bytes_out, mode='wb', compresslevel=compression)
* try:
* gzip_file.write(data) # <<<<<<<<<<<<<<
* finally:
* gzip_file.close()
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_gzip_file, __pyx_n_s_write); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 454; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_gzip_file, __pyx_n_s_write); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 461; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (!__pyx_t_5) {
- __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_data); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 454; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_data); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 461; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_4);
} else {
- __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 454; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 461; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_6);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_data);
PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_v_data);
__Pyx_GIVEREF(__pyx_v_data);
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 454; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 461; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
}
- /* "src/lxml/serializer.pxi":456
+ /* "src/lxml/serializer.pxi":463
* gzip_file.write(data)
* finally:
* gzip_file.close() # <<<<<<<<<<<<<<
*/
/*finally:*/ {
/*normal exit:*/{
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_gzip_file, __pyx_n_s_close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 456; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_gzip_file, __pyx_n_s_close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 463; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_6) {
- __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 456; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 463; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
- __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 456; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 463; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_XGOTREF(__pyx_t_14);
__pyx_t_1 = __pyx_lineno; __pyx_t_7 = __pyx_clineno; __pyx_t_8 = __pyx_filename;
{
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_gzip_file, __pyx_n_s_close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 456; __pyx_clineno = __LINE__; goto __pyx_L9_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_gzip_file, __pyx_n_s_close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 463; __pyx_clineno = __LINE__; goto __pyx_L9_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_6) {
- __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 456; __pyx_clineno = __LINE__; goto __pyx_L9_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 463; __pyx_clineno = __LINE__; goto __pyx_L9_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
- __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 456; __pyx_clineno = __LINE__; goto __pyx_L9_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 463; __pyx_clineno = __LINE__; goto __pyx_L9_error;}
}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_L7:;
}
- /* "src/lxml/serializer.pxi":457
+ /* "src/lxml/serializer.pxi":464
* finally:
* gzip_file.close()
* data = bytes_out.getvalue() # <<<<<<<<<<<<<<
* if _isString(f):
* filename8 = _encodeFilename(f)
*/
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_bytes_out, __pyx_n_s_getvalue); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_bytes_out, __pyx_n_s_getvalue); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_6) {
- __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
- __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 457; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
}
__pyx_L4:;
- /* "src/lxml/serializer.pxi":458
+ /* "src/lxml/serializer.pxi":465
* gzip_file.close()
* data = bytes_out.getvalue()
* if _isString(f): # <<<<<<<<<<<<<<
__pyx_t_2 = (_isString(__pyx_v_f) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":459
+ /* "src/lxml/serializer.pxi":466
* data = bytes_out.getvalue()
* if _isString(f):
* filename8 = _encodeFilename(f) # <<<<<<<<<<<<<<
* f = open(filename8, 'wb')
* try:
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_f); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 459; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_f); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 466; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_filename8 = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":460
+ /* "src/lxml/serializer.pxi":467
* if _isString(f):
* filename8 = _encodeFilename(f)
* f = open(filename8, 'wb') # <<<<<<<<<<<<<<
* try:
* f.write(data)
*/
- __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(__pyx_v_filename8);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_filename8);
__Pyx_INCREF(__pyx_n_s_wb);
PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_n_s_wb);
__Pyx_GIVEREF(__pyx_n_s_wb);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_open, __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_open, __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF_SET(__pyx_v_f, __pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":461
+ /* "src/lxml/serializer.pxi":468
* filename8 = _encodeFilename(f)
* f = open(filename8, 'wb')
* try: # <<<<<<<<<<<<<<
*/
/*try:*/ {
- /* "src/lxml/serializer.pxi":462
+ /* "src/lxml/serializer.pxi":469
* f = open(filename8, 'wb')
* try:
* f.write(data) # <<<<<<<<<<<<<<
* finally:
* f.close()
*/
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_write); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 462; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_write); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 469; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_4))) {
}
}
if (!__pyx_t_6) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_data); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 462; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_data); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 469; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
__Pyx_GOTREF(__pyx_t_3);
} else {
- __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 462; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
+ __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 469; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
__Pyx_GOTREF(__pyx_t_5);
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_6); __Pyx_GIVEREF(__pyx_t_6); __pyx_t_6 = NULL;
__Pyx_INCREF(__pyx_v_data);
PyTuple_SET_ITEM(__pyx_t_5, 0+1, __pyx_v_data);
__Pyx_GIVEREF(__pyx_v_data);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 462; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 469; __pyx_clineno = __LINE__; goto __pyx_L12_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
}
- /* "src/lxml/serializer.pxi":464
+ /* "src/lxml/serializer.pxi":471
* f.write(data)
* finally:
* f.close() # <<<<<<<<<<<<<<
*/
/*finally:*/ {
/*normal exit:*/{
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_close); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_close); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_4))) {
}
}
if (__pyx_t_5) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 471; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_XGOTREF(__pyx_t_9);
__pyx_t_7 = __pyx_lineno; __pyx_t_1 = __pyx_clineno; __pyx_t_15 = __pyx_filename;
{
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_close); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L15_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_close); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 471; __pyx_clineno = __LINE__; goto __pyx_L15_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_4))) {
}
}
if (__pyx_t_5) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L15_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 471; __pyx_clineno = __LINE__; goto __pyx_L15_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L15_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 471; __pyx_clineno = __LINE__; goto __pyx_L15_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
}
/*else*/ {
- /* "src/lxml/serializer.pxi":466
+ /* "src/lxml/serializer.pxi":473
* f.close()
* else:
* f.write(data) # <<<<<<<<<<<<<<
* return
*
*/
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_write); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 466; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_f, __pyx_n_s_write); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_4))) {
}
}
if (!__pyx_t_5) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_data); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 466; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_data); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
} else {
- __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 466; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_data);
PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_v_data);
__Pyx_GIVEREF(__pyx_v_data);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 466; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 473; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
}
__pyx_L10:;
- /* "src/lxml/serializer.pxi":467
+ /* "src/lxml/serializer.pxi":474
* else:
* f.write(data)
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":469
+ /* "src/lxml/serializer.pxi":476
* return
*
* if encoding is None: # <<<<<<<<<<<<<<
__pyx_t_16 = (__pyx_t_2 != 0);
if (__pyx_t_16) {
- /* "src/lxml/serializer.pxi":470
+ /* "src/lxml/serializer.pxi":477
*
* if encoding is None:
* c_enc = NULL # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":472
+ /* "src/lxml/serializer.pxi":479
* c_enc = NULL
* else:
* encoding = _utf8(encoding) # <<<<<<<<<<<<<<
* c_enc = _cstr(encoding)
* if doctype is None:
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__utf8(__pyx_v_encoding); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 472; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__utf8(__pyx_v_encoding); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 479; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_encoding, __pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":473
+ /* "src/lxml/serializer.pxi":480
* else:
* encoding = _utf8(encoding)
* c_enc = _cstr(encoding) # <<<<<<<<<<<<<<
}
__pyx_L16:;
- /* "src/lxml/serializer.pxi":474
+ /* "src/lxml/serializer.pxi":481
* encoding = _utf8(encoding)
* c_enc = _cstr(encoding)
* if doctype is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_16 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":475
+ /* "src/lxml/serializer.pxi":482
* c_enc = _cstr(encoding)
* if doctype is None:
* c_doctype = NULL # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":477
+ /* "src/lxml/serializer.pxi":484
* c_doctype = NULL
* else:
* doctype = _utf8(doctype) # <<<<<<<<<<<<<<
* c_doctype = _xcstr(doctype)
*
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__utf8(__pyx_v_doctype); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 477; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__utf8(__pyx_v_doctype); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 484; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_doctype, __pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":478
+ /* "src/lxml/serializer.pxi":485
* else:
* doctype = _utf8(doctype)
* c_doctype = _xcstr(doctype) # <<<<<<<<<<<<<<
}
__pyx_L17:;
- /* "src/lxml/serializer.pxi":480
+ /* "src/lxml/serializer.pxi":487
* c_doctype = _xcstr(doctype)
*
* writer = _create_output_buffer(f, c_enc, compression, &c_buffer, close=False) # <<<<<<<<<<<<<<
* if writer is None:
* state = python.PyEval_SaveThread()
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__create_output_buffer(__pyx_v_f, __pyx_v_c_enc, __pyx_v_compression, (&__pyx_v_c_buffer), 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 480; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__create_output_buffer(__pyx_v_f, __pyx_v_c_enc, __pyx_v_compression, (&__pyx_v_c_buffer), 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 487; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_4lxml_5etree__FilelikeWriter))))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 480; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_4lxml_5etree__FilelikeWriter))))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 487; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF_SET(__pyx_v_writer, ((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)__pyx_t_3));
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":481
+ /* "src/lxml/serializer.pxi":488
*
* writer = _create_output_buffer(f, c_enc, compression, &c_buffer, close=False)
* if writer is None: # <<<<<<<<<<<<<<
__pyx_t_16 = (__pyx_t_2 != 0);
if (__pyx_t_16) {
- /* "src/lxml/serializer.pxi":482
+ /* "src/lxml/serializer.pxi":489
* writer = _create_output_buffer(f, c_enc, compression, &c_buffer, close=False)
* if writer is None:
* state = python.PyEval_SaveThread() # <<<<<<<<<<<<<<
}
__pyx_L18:;
- /* "src/lxml/serializer.pxi":484
+ /* "src/lxml/serializer.pxi":491
* state = python.PyEval_SaveThread()
*
* _writeNodeToBuffer(c_buffer, element._c_node, c_enc, c_doctype, c_method, # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__writeNodeToBuffer(__pyx_v_c_buffer, __pyx_v_element->_c_node, __pyx_v_c_enc, __pyx_v_c_doctype, __pyx_v_c_method, __pyx_v_write_xml_declaration, __pyx_v_write_doctype, __pyx_v_pretty_print, __pyx_v_with_tail, __pyx_v_standalone);
- /* "src/lxml/serializer.pxi":487
+ /* "src/lxml/serializer.pxi":494
* write_xml_declaration, write_doctype,
* pretty_print, with_tail, standalone)
* error_result = c_buffer.error # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_c_buffer->error;
__pyx_v_error_result = __pyx_t_1;
- /* "src/lxml/serializer.pxi":488
+ /* "src/lxml/serializer.pxi":495
* pretty_print, with_tail, standalone)
* error_result = c_buffer.error
* if error_result == xmlerror.XML_ERR_OK: # <<<<<<<<<<<<<<
__pyx_t_16 = ((__pyx_v_error_result == XML_ERR_OK) != 0);
if (__pyx_t_16) {
- /* "src/lxml/serializer.pxi":489
+ /* "src/lxml/serializer.pxi":496
* error_result = c_buffer.error
* if error_result == xmlerror.XML_ERR_OK:
* error_result = tree.xmlOutputBufferClose(c_buffer) # <<<<<<<<<<<<<<
*/
__pyx_v_error_result = xmlOutputBufferClose(__pyx_v_c_buffer);
- /* "src/lxml/serializer.pxi":490
+ /* "src/lxml/serializer.pxi":497
* if error_result == xmlerror.XML_ERR_OK:
* error_result = tree.xmlOutputBufferClose(c_buffer)
* if error_result > 0: # <<<<<<<<<<<<<<
__pyx_t_16 = ((__pyx_v_error_result > 0) != 0);
if (__pyx_t_16) {
- /* "src/lxml/serializer.pxi":491
+ /* "src/lxml/serializer.pxi":498
* error_result = tree.xmlOutputBufferClose(c_buffer)
* if error_result > 0:
* error_result = xmlerror.XML_ERR_OK # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":493
+ /* "src/lxml/serializer.pxi":500
* error_result = xmlerror.XML_ERR_OK
* else:
* tree.xmlOutputBufferClose(c_buffer) # <<<<<<<<<<<<<<
}
__pyx_L19:;
- /* "src/lxml/serializer.pxi":494
+ /* "src/lxml/serializer.pxi":501
* else:
* tree.xmlOutputBufferClose(c_buffer)
* if writer is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_16 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":495
+ /* "src/lxml/serializer.pxi":502
* tree.xmlOutputBufferClose(c_buffer)
* if writer is None:
* python.PyEval_RestoreThread(state) # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":497
+ /* "src/lxml/serializer.pxi":504
* python.PyEval_RestoreThread(state)
* else:
* writer._exc_context._raise_if_stored() # <<<<<<<<<<<<<<
* if error_result != xmlerror.XML_ERR_OK:
* _raiseSerialisationError(error_result)
*/
- __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree__ExceptionContext *)__pyx_v_writer->_exc_context->__pyx_vtab)->_raise_if_stored(__pyx_v_writer->_exc_context); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 497; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree__ExceptionContext *)__pyx_v_writer->_exc_context->__pyx_vtab)->_raise_if_stored(__pyx_v_writer->_exc_context); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 504; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L21:;
- /* "src/lxml/serializer.pxi":498
+ /* "src/lxml/serializer.pxi":505
* else:
* writer._exc_context._raise_if_stored()
* if error_result != xmlerror.XML_ERR_OK: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_error_result != XML_ERR_OK) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":499
+ /* "src/lxml/serializer.pxi":506
* writer._exc_context._raise_if_stored()
* if error_result != xmlerror.XML_ERR_OK:
* _raiseSerialisationError(error_result) # <<<<<<<<<<<<<<
*
* cdef _create_output_buffer(f, const_char* c_enc, int compression,
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree__raiseSerialisationError(__pyx_v_error_result); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 499; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree__raiseSerialisationError(__pyx_v_error_result); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 506; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
goto __pyx_L22;
}
__pyx_L22:;
- /* "src/lxml/serializer.pxi":434
+ /* "src/lxml/serializer.pxi":441
* return (<_FilelikeWriter>ctxt).close()
*
* cdef _tofilelike(f, _Element element, encoding, doctype, method, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":501
+/* "src/lxml/serializer.pxi":508
* _raiseSerialisationError(error_result)
*
* cdef _create_output_buffer(f, const_char* c_enc, int compression, # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_create_output_buffer", 0);
- /* "src/lxml/serializer.pxi":505
+ /* "src/lxml/serializer.pxi":512
* cdef tree.xmlOutputBuffer* c_buffer
* cdef _FilelikeWriter writer
* enchandler = tree.xmlFindCharEncodingHandler(c_enc) # <<<<<<<<<<<<<<
*/
__pyx_v_enchandler = xmlFindCharEncodingHandler(__pyx_v_c_enc);
- /* "src/lxml/serializer.pxi":506
+ /* "src/lxml/serializer.pxi":513
* cdef _FilelikeWriter writer
* enchandler = tree.xmlFindCharEncodingHandler(c_enc)
* if enchandler is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_enchandler == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":508
+ /* "src/lxml/serializer.pxi":515
* if enchandler is NULL:
* raise LookupError(u"unknown encoding: '%s'" %
* c_enc.decode(u'UTF-8') if c_enc is not NULL else u'') # <<<<<<<<<<<<<<
* if _isString(f):
*/
if (((__pyx_v_c_enc != NULL) != 0)) {
- __pyx_t_3 = __Pyx_decode_c_string(__pyx_v_c_enc, 0, strlen(__pyx_v_c_enc), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 508; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_decode_c_string(__pyx_v_c_enc, 0, strlen(__pyx_v_c_enc), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 515; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- /* "src/lxml/serializer.pxi":507
+ /* "src/lxml/serializer.pxi":514
* enchandler = tree.xmlFindCharEncodingHandler(c_enc)
* if enchandler is NULL:
* raise LookupError(u"unknown encoding: '%s'" % # <<<<<<<<<<<<<<
* c_enc.decode(u'UTF-8') if c_enc is not NULL else u'')
* try:
*/
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_unknown_encoding_s, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 507; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_unknown_encoding_s, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 514; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_2 = __pyx_t_4;
__Pyx_INCREF(__pyx_kp_u__15);
__pyx_t_2 = __pyx_kp_u__15;
}
- __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 507; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 514; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_2);
__Pyx_GIVEREF(__pyx_t_2);
__pyx_t_2 = 0;
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_LookupError, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 507; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_LookupError, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 514; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 507; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 514; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":509
+ /* "src/lxml/serializer.pxi":516
* raise LookupError(u"unknown encoding: '%s'" %
* c_enc.decode(u'UTF-8') if c_enc is not NULL else u'')
* try: # <<<<<<<<<<<<<<
__Pyx_XGOTREF(__pyx_t_7);
/*try:*/ {
- /* "src/lxml/serializer.pxi":510
+ /* "src/lxml/serializer.pxi":517
* c_enc.decode(u'UTF-8') if c_enc is not NULL else u'')
* try:
* if _isString(f): # <<<<<<<<<<<<<<
__pyx_t_1 = (_isString(__pyx_v_f) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":511
+ /* "src/lxml/serializer.pxi":518
* try:
* if _isString(f):
* filename8 = _encodeFilename(f) # <<<<<<<<<<<<<<
* c_buffer = tree.xmlOutputBufferCreateFilename(
* _cstr(filename8), enchandler, compression)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_f); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 511; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_f); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_v_filename8 = __pyx_t_2;
__pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":512
+ /* "src/lxml/serializer.pxi":519
* if _isString(f):
* filename8 = _encodeFilename(f)
* c_buffer = tree.xmlOutputBufferCreateFilename( # <<<<<<<<<<<<<<
*/
__pyx_v_c_buffer = xmlOutputBufferCreateFilename(PyBytes_AS_STRING(__pyx_v_filename8), __pyx_v_enchandler, __pyx_v_compression);
- /* "src/lxml/serializer.pxi":514
+ /* "src/lxml/serializer.pxi":521
* c_buffer = tree.xmlOutputBufferCreateFilename(
* _cstr(filename8), enchandler, compression)
* if c_buffer is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_c_buffer == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":515
+ /* "src/lxml/serializer.pxi":522
* _cstr(filename8), enchandler, compression)
* if c_buffer is NULL:
* return python.PyErr_SetFromErrno(IOError) # raises IOError # <<<<<<<<<<<<<<
* elif hasattr(f, 'write'):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = PyErr_SetFromErrno(__pyx_builtin_IOError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 515; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_2 = PyErr_SetFromErrno(__pyx_builtin_IOError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 522; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L8_try_return;
}
- /* "src/lxml/serializer.pxi":516
+ /* "src/lxml/serializer.pxi":523
* if c_buffer is NULL:
* return python.PyErr_SetFromErrno(IOError) # raises IOError
* writer = None # <<<<<<<<<<<<<<
goto __pyx_L12;
}
- /* "src/lxml/serializer.pxi":517
+ /* "src/lxml/serializer.pxi":524
* return python.PyErr_SetFromErrno(IOError) # raises IOError
* writer = None
* elif hasattr(f, 'write'): # <<<<<<<<<<<<<<
* writer = _FilelikeWriter(f, compression=compression, close=close)
* c_buffer = writer._createOutputBuffer(enchandler)
*/
- __pyx_t_1 = PyObject_HasAttr(__pyx_v_f, __pyx_n_s_write); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 517; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_1 = PyObject_HasAttr(__pyx_v_f, __pyx_n_s_write); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 524; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__pyx_t_8 = (__pyx_t_1 != 0);
if (__pyx_t_8) {
- /* "src/lxml/serializer.pxi":518
+ /* "src/lxml/serializer.pxi":525
* writer = None
* elif hasattr(f, 'write'):
* writer = _FilelikeWriter(f, compression=compression, close=close) # <<<<<<<<<<<<<<
* c_buffer = writer._createOutputBuffer(enchandler)
* else:
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_INCREF(__pyx_v_f);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_f);
__Pyx_GIVEREF(__pyx_v_f);
- __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_compression); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_compression); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_compression, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_compression, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_close, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_close, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__FilelikeWriter)), __pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 518; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__FilelikeWriter)), __pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 525; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_v_writer = ((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":519
+ /* "src/lxml/serializer.pxi":526
* elif hasattr(f, 'write'):
* writer = _FilelikeWriter(f, compression=compression, close=close)
* c_buffer = writer._createOutputBuffer(enchandler) # <<<<<<<<<<<<<<
* else:
* raise TypeError(
*/
- __pyx_t_9 = __pyx_f_4lxml_5etree_15_FilelikeWriter__createOutputBuffer(__pyx_v_writer, __pyx_v_enchandler); if (unlikely(__pyx_t_9 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 519; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_9 = __pyx_f_4lxml_5etree_15_FilelikeWriter__createOutputBuffer(__pyx_v_writer, __pyx_v_enchandler); if (unlikely(__pyx_t_9 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 526; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__pyx_v_c_buffer = __pyx_t_9;
goto __pyx_L12;
}
/*else*/ {
- /* "src/lxml/serializer.pxi":523
+ /* "src/lxml/serializer.pxi":530
* raise TypeError(
* u"File or filename expected, got '%s'" %
* python._fqtypename(f).decode('UTF-8')) # <<<<<<<<<<<<<<
* tree.xmlCharEncCloseFunc(enchandler)
*/
__pyx_t_10 = _fqtypename(__pyx_v_f);
- __pyx_t_3 = __Pyx_decode_c_string(__pyx_t_10, 0, strlen(__pyx_t_10), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = __Pyx_decode_c_string(__pyx_t_10, 0, strlen(__pyx_t_10), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 530; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_3);
- /* "src/lxml/serializer.pxi":522
+ /* "src/lxml/serializer.pxi":529
* else:
* raise TypeError(
* u"File or filename expected, got '%s'" % # <<<<<<<<<<<<<<
* python._fqtypename(f).decode('UTF-8'))
* except:
*/
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_File_or_filename_expected_got_s, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 522; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_File_or_filename_expected_got_s, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 529; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":521
+ /* "src/lxml/serializer.pxi":528
* c_buffer = writer._createOutputBuffer(enchandler)
* else:
* raise TypeError( # <<<<<<<<<<<<<<
* u"File or filename expected, got '%s'" %
* python._fqtypename(f).decode('UTF-8'))
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 528; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_3);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4);
__Pyx_GIVEREF(__pyx_t_4);
__pyx_t_4 = 0;
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 528; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_Raise(__pyx_t_4, 0, 0, 0);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 528; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
}
__pyx_L12:;
}
__Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":524
+ /* "src/lxml/serializer.pxi":531
* u"File or filename expected, got '%s'" %
* python._fqtypename(f).decode('UTF-8'))
* except: # <<<<<<<<<<<<<<
*/
/*except:*/ {
__Pyx_AddTraceback("lxml.etree._create_output_buffer", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_3, &__pyx_t_2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 524; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_3, &__pyx_t_2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 531; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_GOTREF(__pyx_t_3);
__Pyx_GOTREF(__pyx_t_2);
- /* "src/lxml/serializer.pxi":525
+ /* "src/lxml/serializer.pxi":532
* python._fqtypename(f).decode('UTF-8'))
* except:
* tree.xmlCharEncCloseFunc(enchandler) # <<<<<<<<<<<<<<
*/
xmlCharEncCloseFunc(__pyx_v_enchandler);
- /* "src/lxml/serializer.pxi":526
+ /* "src/lxml/serializer.pxi":533
* except:
* tree.xmlCharEncCloseFunc(enchandler)
* raise # <<<<<<<<<<<<<<
__Pyx_XGIVEREF(__pyx_t_2);
__Pyx_ErrRestore(__pyx_t_4, __pyx_t_3, __pyx_t_2);
__pyx_t_4 = 0; __pyx_t_3 = 0; __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 526; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 533; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
}
__pyx_L6_except_error:;
__Pyx_XGIVEREF(__pyx_t_5);
__pyx_L11_try_end:;
}
- /* "src/lxml/serializer.pxi":527
+ /* "src/lxml/serializer.pxi":534
* tree.xmlCharEncCloseFunc(enchandler)
* raise
* c_buffer_ret[0] = c_buffer # <<<<<<<<<<<<<<
*/
(__pyx_v_c_buffer_ret[0]) = __pyx_v_c_buffer;
- /* "src/lxml/serializer.pxi":528
+ /* "src/lxml/serializer.pxi":535
* raise
* c_buffer_ret[0] = c_buffer
* return writer # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_writer);
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":501
+ /* "src/lxml/serializer.pxi":508
* _raiseSerialisationError(error_result)
*
* cdef _create_output_buffer(f, const_char* c_enc, int compression, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":530
+/* "src/lxml/serializer.pxi":537
* return writer
*
* cdef xmlChar **_convert_ns_prefixes(tree.xmlDict* c_dict, ns_prefixes) except NULL: # <<<<<<<<<<<<<<
xmlChar **__pyx_r;
__Pyx_RefNannyDeclarations
Py_ssize_t __pyx_t_1;
- PyObject *__pyx_t_2 = NULL;
+ int __pyx_t_2;
PyObject *__pyx_t_3 = NULL;
PyObject *__pyx_t_4 = NULL;
PyObject *__pyx_t_5 = NULL;
- PyObject *(*__pyx_t_6)(PyObject *);
- PyObject *__pyx_t_7 = NULL;
- Py_ssize_t __pyx_t_8;
- int __pyx_t_9;
+ PyObject *__pyx_t_6 = NULL;
+ PyObject *(*__pyx_t_7)(PyObject *);
+ PyObject *__pyx_t_8 = NULL;
+ Py_ssize_t __pyx_t_9;
PyObject *__pyx_t_10 = NULL;
int __pyx_lineno = 0;
const char *__pyx_filename = NULL;
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_convert_ns_prefixes", 0);
- /* "src/lxml/serializer.pxi":531
+ /* "src/lxml/serializer.pxi":538
*
* cdef xmlChar **_convert_ns_prefixes(tree.xmlDict* c_dict, ns_prefixes) except NULL:
* cdef size_t i, num_ns_prefixes = len(ns_prefixes) # <<<<<<<<<<<<<<
* # Need to allocate one extra memory block to handle last NULL entry
* c_ns_prefixes = <xmlChar **>python.PyMem_Malloc(sizeof(xmlChar*) * (num_ns_prefixes + 1))
*/
- __pyx_t_1 = PyObject_Length(__pyx_v_ns_prefixes); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_Length(__pyx_v_ns_prefixes); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 538; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_num_ns_prefixes = __pyx_t_1;
- /* "src/lxml/serializer.pxi":533
+ /* "src/lxml/serializer.pxi":540
* cdef size_t i, num_ns_prefixes = len(ns_prefixes)
* # Need to allocate one extra memory block to handle last NULL entry
* c_ns_prefixes = <xmlChar **>python.PyMem_Malloc(sizeof(xmlChar*) * (num_ns_prefixes + 1)) # <<<<<<<<<<<<<<
- * i = 0
- * try:
+ * if not c_ns_prefixes:
+ * raise MemoryError()
*/
__pyx_v_c_ns_prefixes = ((xmlChar **)PyMem_Malloc(((sizeof(xmlChar *)) * (__pyx_v_num_ns_prefixes + 1))));
- /* "src/lxml/serializer.pxi":534
+ /* "src/lxml/serializer.pxi":541
* # Need to allocate one extra memory block to handle last NULL entry
* c_ns_prefixes = <xmlChar **>python.PyMem_Malloc(sizeof(xmlChar*) * (num_ns_prefixes + 1))
+ * if not c_ns_prefixes: # <<<<<<<<<<<<<<
+ * raise MemoryError()
+ * i = 0
+ */
+ __pyx_t_2 = ((!(__pyx_v_c_ns_prefixes != 0)) != 0);
+ if (__pyx_t_2) {
+
+ /* "src/lxml/serializer.pxi":542
+ * c_ns_prefixes = <xmlChar **>python.PyMem_Malloc(sizeof(xmlChar*) * (num_ns_prefixes + 1))
+ * if not c_ns_prefixes:
+ * raise MemoryError() # <<<<<<<<<<<<<<
+ * i = 0
+ * try:
+ */
+ PyErr_NoMemory(); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 542; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+
+ /* "src/lxml/serializer.pxi":543
+ * if not c_ns_prefixes:
+ * raise MemoryError()
* i = 0 # <<<<<<<<<<<<<<
* try:
* for prefix in ns_prefixes:
*/
__pyx_v_i = 0;
- /* "src/lxml/serializer.pxi":535
- * c_ns_prefixes = <xmlChar **>python.PyMem_Malloc(sizeof(xmlChar*) * (num_ns_prefixes + 1))
+ /* "src/lxml/serializer.pxi":544
+ * raise MemoryError()
* i = 0
* try: # <<<<<<<<<<<<<<
* for prefix in ns_prefixes:
* prefix_utf = _utf8(prefix)
*/
{
- __Pyx_ExceptionSave(&__pyx_t_2, &__pyx_t_3, &__pyx_t_4);
- __Pyx_XGOTREF(__pyx_t_2);
+ __Pyx_ExceptionSave(&__pyx_t_3, &__pyx_t_4, &__pyx_t_5);
__Pyx_XGOTREF(__pyx_t_3);
__Pyx_XGOTREF(__pyx_t_4);
+ __Pyx_XGOTREF(__pyx_t_5);
/*try:*/ {
- /* "src/lxml/serializer.pxi":536
+ /* "src/lxml/serializer.pxi":545
* i = 0
* try:
* for prefix in ns_prefixes: # <<<<<<<<<<<<<<
* c_prefix = tree.xmlDictExists(c_dict, _xcstr(prefix_utf), len(prefix_utf))
*/
if (likely(PyList_CheckExact(__pyx_v_ns_prefixes)) || PyTuple_CheckExact(__pyx_v_ns_prefixes)) {
- __pyx_t_5 = __pyx_v_ns_prefixes; __Pyx_INCREF(__pyx_t_5); __pyx_t_1 = 0;
- __pyx_t_6 = NULL;
+ __pyx_t_6 = __pyx_v_ns_prefixes; __Pyx_INCREF(__pyx_t_6); __pyx_t_1 = 0;
+ __pyx_t_7 = NULL;
} else {
- __pyx_t_1 = -1; __pyx_t_5 = PyObject_GetIter(__pyx_v_ns_prefixes); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 536; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = Py_TYPE(__pyx_t_5)->tp_iternext; if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 536; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_1 = -1; __pyx_t_6 = PyObject_GetIter(__pyx_v_ns_prefixes); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __Pyx_GOTREF(__pyx_t_6);
+ __pyx_t_7 = Py_TYPE(__pyx_t_6)->tp_iternext; if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
}
for (;;) {
- if (likely(!__pyx_t_6)) {
- if (likely(PyList_CheckExact(__pyx_t_5))) {
- if (__pyx_t_1 >= PyList_GET_SIZE(__pyx_t_5)) break;
+ if (likely(!__pyx_t_7)) {
+ if (likely(PyList_CheckExact(__pyx_t_6))) {
+ if (__pyx_t_1 >= PyList_GET_SIZE(__pyx_t_6)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_7 = PyList_GET_ITEM(__pyx_t_5, __pyx_t_1); __Pyx_INCREF(__pyx_t_7); __pyx_t_1++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 536; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_8 = PyList_GET_ITEM(__pyx_t_6, __pyx_t_1); __Pyx_INCREF(__pyx_t_8); __pyx_t_1++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
#else
- __pyx_t_7 = PySequence_ITEM(__pyx_t_5, __pyx_t_1); __pyx_t_1++; if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 536; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_8 = PySequence_ITEM(__pyx_t_6, __pyx_t_1); __pyx_t_1++; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
#endif
} else {
- if (__pyx_t_1 >= PyTuple_GET_SIZE(__pyx_t_5)) break;
+ if (__pyx_t_1 >= PyTuple_GET_SIZE(__pyx_t_6)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_7 = PyTuple_GET_ITEM(__pyx_t_5, __pyx_t_1); __Pyx_INCREF(__pyx_t_7); __pyx_t_1++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 536; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_8 = PyTuple_GET_ITEM(__pyx_t_6, __pyx_t_1); __Pyx_INCREF(__pyx_t_8); __pyx_t_1++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
#else
- __pyx_t_7 = PySequence_ITEM(__pyx_t_5, __pyx_t_1); __pyx_t_1++; if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 536; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_t_8 = PySequence_ITEM(__pyx_t_6, __pyx_t_1); __pyx_t_1++; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
#endif
}
} else {
- __pyx_t_7 = __pyx_t_6(__pyx_t_5);
- if (unlikely(!__pyx_t_7)) {
+ __pyx_t_8 = __pyx_t_7(__pyx_t_6);
+ if (unlikely(!__pyx_t_8)) {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[7]; __pyx_lineno = 536; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ else {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
}
break;
}
- __Pyx_GOTREF(__pyx_t_7);
+ __Pyx_GOTREF(__pyx_t_8);
}
- __Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_7);
- __pyx_t_7 = 0;
+ __Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_8);
+ __pyx_t_8 = 0;
- /* "src/lxml/serializer.pxi":537
+ /* "src/lxml/serializer.pxi":546
* try:
* for prefix in ns_prefixes:
* prefix_utf = _utf8(prefix) # <<<<<<<<<<<<<<
* c_prefix = tree.xmlDictExists(c_dict, _xcstr(prefix_utf), len(prefix_utf))
* if c_prefix:
*/
- __pyx_t_7 = __pyx_f_4lxml_5etree__utf8(__pyx_v_prefix); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 537; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __Pyx_GOTREF(__pyx_t_7);
- __Pyx_XDECREF_SET(__pyx_v_prefix_utf, ((PyObject*)__pyx_t_7));
- __pyx_t_7 = 0;
+ __pyx_t_8 = __pyx_f_4lxml_5etree__utf8(__pyx_v_prefix); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 546; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __Pyx_XDECREF_SET(__pyx_v_prefix_utf, ((PyObject*)__pyx_t_8));
+ __pyx_t_8 = 0;
- /* "src/lxml/serializer.pxi":538
+ /* "src/lxml/serializer.pxi":547
* for prefix in ns_prefixes:
* prefix_utf = _utf8(prefix)
* c_prefix = tree.xmlDictExists(c_dict, _xcstr(prefix_utf), len(prefix_utf)) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_prefix_utf == Py_None)) {
PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 538; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 547; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
}
- __pyx_t_8 = PyBytes_GET_SIZE(__pyx_v_prefix_utf); if (unlikely(__pyx_t_8 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 538; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_c_prefix = xmlDictExists(__pyx_v_c_dict, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_prefix_utf), __pyx_t_8);
+ __pyx_t_9 = PyBytes_GET_SIZE(__pyx_v_prefix_utf); if (unlikely(__pyx_t_9 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 547; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_v_c_prefix = xmlDictExists(__pyx_v_c_dict, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_prefix_utf), __pyx_t_9);
- /* "src/lxml/serializer.pxi":539
+ /* "src/lxml/serializer.pxi":548
* prefix_utf = _utf8(prefix)
* c_prefix = tree.xmlDictExists(c_dict, _xcstr(prefix_utf), len(prefix_utf))
* if c_prefix: # <<<<<<<<<<<<<<
* # unknown prefixes do not need to get serialised
* c_ns_prefixes[i] = <xmlChar*>c_prefix
*/
- __pyx_t_9 = (__pyx_v_c_prefix != 0);
- if (__pyx_t_9) {
+ __pyx_t_2 = (__pyx_v_c_prefix != 0);
+ if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":541
+ /* "src/lxml/serializer.pxi":550
* if c_prefix:
* # unknown prefixes do not need to get serialised
* c_ns_prefixes[i] = <xmlChar*>c_prefix # <<<<<<<<<<<<<<
*/
(__pyx_v_c_ns_prefixes[__pyx_v_i]) = ((xmlChar *)__pyx_v_c_prefix);
- /* "src/lxml/serializer.pxi":542
+ /* "src/lxml/serializer.pxi":551
* # unknown prefixes do not need to get serialised
* c_ns_prefixes[i] = <xmlChar*>c_prefix
* i += 1 # <<<<<<<<<<<<<<
* python.PyMem_Free(c_ns_prefixes)
*/
__pyx_v_i = (__pyx_v_i + 1);
- goto __pyx_L13;
+ goto __pyx_L14;
}
- __pyx_L13:;
+ __pyx_L14:;
- /* "src/lxml/serializer.pxi":536
+ /* "src/lxml/serializer.pxi":545
* i = 0
* try:
* for prefix in ns_prefixes: # <<<<<<<<<<<<<<
* c_prefix = tree.xmlDictExists(c_dict, _xcstr(prefix_utf), len(prefix_utf))
*/
}
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
- __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
- goto __pyx_L10_try_end;
- __pyx_L3_error:;
- __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
+ goto __pyx_L11_try_end;
+ __pyx_L4_error:;
+ __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
+ __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":543
+ /* "src/lxml/serializer.pxi":552
* c_ns_prefixes[i] = <xmlChar*>c_prefix
* i += 1
* except: # <<<<<<<<<<<<<<
*/
/*except:*/ {
__Pyx_AddTraceback("lxml.etree._convert_ns_prefixes", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_7, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 543; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __Pyx_GOTREF(__pyx_t_7);
+ if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_8, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 552; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ __Pyx_GOTREF(__pyx_t_6);
+ __Pyx_GOTREF(__pyx_t_8);
__Pyx_GOTREF(__pyx_t_10);
- /* "src/lxml/serializer.pxi":544
+ /* "src/lxml/serializer.pxi":553
* i += 1
* except:
* python.PyMem_Free(c_ns_prefixes) # <<<<<<<<<<<<<<
*/
PyMem_Free(__pyx_v_c_ns_prefixes);
- /* "src/lxml/serializer.pxi":545
+ /* "src/lxml/serializer.pxi":554
* except:
* python.PyMem_Free(c_ns_prefixes)
* raise # <<<<<<<<<<<<<<
*
* c_ns_prefixes[i] = NULL # append end marker
*/
- __Pyx_GIVEREF(__pyx_t_5);
- __Pyx_GIVEREF(__pyx_t_7);
+ __Pyx_GIVEREF(__pyx_t_6);
+ __Pyx_GIVEREF(__pyx_t_8);
__Pyx_XGIVEREF(__pyx_t_10);
- __Pyx_ErrRestore(__pyx_t_5, __pyx_t_7, __pyx_t_10);
- __pyx_t_5 = 0; __pyx_t_7 = 0; __pyx_t_10 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L5_except_error;}
+ __Pyx_ErrRestore(__pyx_t_6, __pyx_t_8, __pyx_t_10);
+ __pyx_t_6 = 0; __pyx_t_8 = 0; __pyx_t_10 = 0;
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 554; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
}
- __pyx_L5_except_error:;
- __Pyx_XGIVEREF(__pyx_t_2);
+ __pyx_L6_except_error:;
__Pyx_XGIVEREF(__pyx_t_3);
__Pyx_XGIVEREF(__pyx_t_4);
- __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
+ __Pyx_XGIVEREF(__pyx_t_5);
+ __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_4, __pyx_t_5);
goto __pyx_L1_error;
- __pyx_L10_try_end:;
+ __pyx_L11_try_end:;
}
- /* "src/lxml/serializer.pxi":547
+ /* "src/lxml/serializer.pxi":556
* raise
*
* c_ns_prefixes[i] = NULL # append end marker # <<<<<<<<<<<<<<
*/
(__pyx_v_c_ns_prefixes[__pyx_v_i]) = NULL;
- /* "src/lxml/serializer.pxi":548
+ /* "src/lxml/serializer.pxi":557
*
* c_ns_prefixes[i] = NULL # append end marker
* return c_ns_prefixes # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_c_ns_prefixes;
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":530
+ /* "src/lxml/serializer.pxi":537
* return writer
*
* cdef xmlChar **_convert_ns_prefixes(tree.xmlDict* c_dict, ns_prefixes) except NULL: # <<<<<<<<<<<<<<
/* function exit code */
__pyx_L1_error:;
- __Pyx_XDECREF(__pyx_t_5);
- __Pyx_XDECREF(__pyx_t_7);
+ __Pyx_XDECREF(__pyx_t_6);
+ __Pyx_XDECREF(__pyx_t_8);
__Pyx_XDECREF(__pyx_t_10);
__Pyx_AddTraceback("lxml.etree._convert_ns_prefixes", __pyx_clineno, __pyx_lineno, __pyx_filename);
__pyx_r = NULL;
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":550
+/* "src/lxml/serializer.pxi":559
* return c_ns_prefixes
*
* cdef _tofilelikeC14N(f, _Element element, bint exclusive, bint with_comments, # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_tofilelikeC14N", 0);
- /* "src/lxml/serializer.pxi":552
+ /* "src/lxml/serializer.pxi":561
* cdef _tofilelikeC14N(f, _Element element, bint exclusive, bint with_comments,
* int compression, inclusive_ns_prefixes):
* cdef _FilelikeWriter writer = None # <<<<<<<<<<<<<<
__Pyx_INCREF(Py_None);
__pyx_v_writer = ((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)Py_None);
- /* "src/lxml/serializer.pxi":554
+ /* "src/lxml/serializer.pxi":563
* cdef _FilelikeWriter writer = None
* cdef tree.xmlOutputBuffer* c_buffer
* cdef xmlChar **c_inclusive_ns_prefixes = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_c_inclusive_ns_prefixes = NULL;
- /* "src/lxml/serializer.pxi":558
+ /* "src/lxml/serializer.pxi":567
* cdef xmlDoc* c_base_doc
* cdef xmlDoc* c_doc
* cdef int bytes_count, error = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_error = 0;
- /* "src/lxml/serializer.pxi":560
+ /* "src/lxml/serializer.pxi":569
* cdef int bytes_count, error = 0
*
* c_base_doc = element._c_node.doc # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_element->_c_node->doc;
__pyx_v_c_base_doc = __pyx_t_1;
- /* "src/lxml/serializer.pxi":561
+ /* "src/lxml/serializer.pxi":570
*
* c_base_doc = element._c_node.doc
* c_doc = _fakeRootDoc(c_base_doc, element._c_node) # <<<<<<<<<<<<<<
* try:
* c_inclusive_ns_prefixes = (
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__fakeRootDoc(__pyx_v_c_base_doc, __pyx_v_element->_c_node); if (unlikely(__pyx_t_1 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 561; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__fakeRootDoc(__pyx_v_c_base_doc, __pyx_v_element->_c_node); if (unlikely(__pyx_t_1 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 570; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_1;
- /* "src/lxml/serializer.pxi":562
+ /* "src/lxml/serializer.pxi":571
* c_base_doc = element._c_node.doc
* c_doc = _fakeRootDoc(c_base_doc, element._c_node)
* try: # <<<<<<<<<<<<<<
*/
/*try:*/ {
- /* "src/lxml/serializer.pxi":565
+ /* "src/lxml/serializer.pxi":574
* c_inclusive_ns_prefixes = (
* _convert_ns_prefixes(c_doc.dict, inclusive_ns_prefixes)
* if inclusive_ns_prefixes else NULL) # <<<<<<<<<<<<<<
*
* if _isString(f):
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_inclusive_ns_prefixes); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 565; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_inclusive_ns_prefixes); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":564
+ /* "src/lxml/serializer.pxi":573
* try:
* c_inclusive_ns_prefixes = (
* _convert_ns_prefixes(c_doc.dict, inclusive_ns_prefixes) # <<<<<<<<<<<<<<
* if inclusive_ns_prefixes else NULL)
*
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__convert_ns_prefixes(__pyx_v_c_doc->dict, __pyx_v_inclusive_ns_prefixes); if (unlikely(__pyx_t_4 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 564; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__convert_ns_prefixes(__pyx_v_c_doc->dict, __pyx_v_inclusive_ns_prefixes); if (unlikely(__pyx_t_4 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 573; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__pyx_t_2 = __pyx_t_4;
} else {
- /* "src/lxml/serializer.pxi":565
+ /* "src/lxml/serializer.pxi":574
* c_inclusive_ns_prefixes = (
* _convert_ns_prefixes(c_doc.dict, inclusive_ns_prefixes)
* if inclusive_ns_prefixes else NULL) # <<<<<<<<<<<<<<
}
__pyx_v_c_inclusive_ns_prefixes = __pyx_t_2;
- /* "src/lxml/serializer.pxi":567
+ /* "src/lxml/serializer.pxi":576
* if inclusive_ns_prefixes else NULL)
*
* if _isString(f): # <<<<<<<<<<<<<<
__pyx_t_3 = (_isString(__pyx_v_f) != 0);
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":568
+ /* "src/lxml/serializer.pxi":577
*
* if _isString(f):
* filename8 = _encodeFilename(f) # <<<<<<<<<<<<<<
* c_filename = _cstr(filename8)
* with nogil:
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_f); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 568; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__encodeFilename(__pyx_v_f); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_v_filename8 = __pyx_t_5;
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":569
+ /* "src/lxml/serializer.pxi":578
* if _isString(f):
* filename8 = _encodeFilename(f)
* c_filename = _cstr(filename8) # <<<<<<<<<<<<<<
*/
__pyx_v_c_filename = PyBytes_AS_STRING(__pyx_v_filename8);
- /* "src/lxml/serializer.pxi":570
+ /* "src/lxml/serializer.pxi":579
* filename8 = _encodeFilename(f)
* c_filename = _cstr(filename8)
* with nogil: # <<<<<<<<<<<<<<
#endif
/*try:*/ {
- /* "src/lxml/serializer.pxi":571
+ /* "src/lxml/serializer.pxi":580
* c_filename = _cstr(filename8)
* with nogil:
* error = c14n.xmlC14NDocSave( # <<<<<<<<<<<<<<
__pyx_v_error = xmlC14NDocSave(__pyx_v_c_doc, NULL, __pyx_v_exclusive, __pyx_v_c_inclusive_ns_prefixes, __pyx_v_with_comments, __pyx_v_c_filename, __pyx_v_compression);
}
- /* "src/lxml/serializer.pxi":570
+ /* "src/lxml/serializer.pxi":579
* filename8 = _encodeFilename(f)
* c_filename = _cstr(filename8)
* with nogil: # <<<<<<<<<<<<<<
goto __pyx_L6;
}
- /* "src/lxml/serializer.pxi":574
+ /* "src/lxml/serializer.pxi":583
* c_doc, NULL, exclusive, c_inclusive_ns_prefixes,
* with_comments, c_filename, compression)
* elif hasattr(f, 'write'): # <<<<<<<<<<<<<<
* writer = _FilelikeWriter(f, compression=compression)
* c_buffer = writer._createOutputBuffer(NULL)
*/
- __pyx_t_3 = PyObject_HasAttr(__pyx_v_f, __pyx_n_s_write); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_3 = PyObject_HasAttr(__pyx_v_f, __pyx_n_s_write); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 583; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__pyx_t_6 = (__pyx_t_3 != 0);
if (__pyx_t_6) {
- /* "src/lxml/serializer.pxi":575
+ /* "src/lxml/serializer.pxi":584
* with_comments, c_filename, compression)
* elif hasattr(f, 'write'):
* writer = _FilelikeWriter(f, compression=compression) # <<<<<<<<<<<<<<
* c_buffer = writer._createOutputBuffer(NULL)
* with writer.error_log:
*/
- __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_INCREF(__pyx_v_f);
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_f);
__Pyx_GIVEREF(__pyx_v_f);
- __pyx_t_7 = PyDict_New(); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_7 = PyDict_New(); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_7);
- __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_compression); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_compression); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_8);
- if (PyDict_SetItem(__pyx_t_7, __pyx_n_s_compression, __pyx_t_8) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ if (PyDict_SetItem(__pyx_t_7, __pyx_n_s_compression, __pyx_t_8) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
- __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__FilelikeWriter)), __pyx_t_5, __pyx_t_7); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 575; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__FilelikeWriter)), __pyx_t_5, __pyx_t_7); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 584; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_8);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF_SET(__pyx_v_writer, ((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)__pyx_t_8));
__pyx_t_8 = 0;
- /* "src/lxml/serializer.pxi":576
+ /* "src/lxml/serializer.pxi":585
* elif hasattr(f, 'write'):
* writer = _FilelikeWriter(f, compression=compression)
* c_buffer = writer._createOutputBuffer(NULL) # <<<<<<<<<<<<<<
* with writer.error_log:
* bytes_count = c14n.xmlC14NDocSaveTo(
*/
- __pyx_t_9 = __pyx_f_4lxml_5etree_15_FilelikeWriter__createOutputBuffer(__pyx_v_writer, NULL); if (unlikely(__pyx_t_9 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 576; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_9 = __pyx_f_4lxml_5etree_15_FilelikeWriter__createOutputBuffer(__pyx_v_writer, NULL); if (unlikely(__pyx_t_9 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__pyx_v_c_buffer = __pyx_t_9;
- /* "src/lxml/serializer.pxi":577
+ /* "src/lxml/serializer.pxi":586
* writer = _FilelikeWriter(f, compression=compression)
* c_buffer = writer._createOutputBuffer(NULL)
* with writer.error_log: # <<<<<<<<<<<<<<
* c_doc, NULL, exclusive, c_inclusive_ns_prefixes,
*/
/*with:*/ {
- __pyx_t_10 = __Pyx_PyObject_LookupSpecial(((PyObject *)__pyx_v_writer->error_log), __pyx_n_s_exit); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_10 = __Pyx_PyObject_LookupSpecial(((PyObject *)__pyx_v_writer->error_log), __pyx_n_s_exit); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 586; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_10);
- __pyx_t_11 = __pyx_f_4lxml_5etree_9_ErrorLog___enter__(__pyx_v_writer->error_log); if (unlikely(__pyx_t_11 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L10_error;}
+ __pyx_t_11 = __pyx_f_4lxml_5etree_9_ErrorLog___enter__(__pyx_v_writer->error_log); if (unlikely(__pyx_t_11 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 586; __pyx_clineno = __LINE__; goto __pyx_L10_error;}
/*try:*/ {
{
if (__pyx_t_12||__pyx_t_13||__pyx_t_14); else {/*mark used*/};
/*try:*/ {
- /* "src/lxml/serializer.pxi":578
+ /* "src/lxml/serializer.pxi":587
* c_buffer = writer._createOutputBuffer(NULL)
* with writer.error_log:
* bytes_count = c14n.xmlC14NDocSaveTo( # <<<<<<<<<<<<<<
*/
__pyx_v_bytes_count = xmlC14NDocSaveTo(__pyx_v_c_doc, NULL, __pyx_v_exclusive, __pyx_v_c_inclusive_ns_prefixes, __pyx_v_with_comments, __pyx_v_c_buffer);
- /* "src/lxml/serializer.pxi":581
+ /* "src/lxml/serializer.pxi":590
* c_doc, NULL, exclusive, c_inclusive_ns_prefixes,
* with_comments, c_buffer)
* error = tree.xmlOutputBufferClose(c_buffer) # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/serializer.pxi":577
+ /* "src/lxml/serializer.pxi":586
* writer = _FilelikeWriter(f, compression=compression)
* c_buffer = writer._createOutputBuffer(NULL)
* with writer.error_log: # <<<<<<<<<<<<<<
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_10) {
- __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_tuple__58, NULL);
+ __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_tuple__59, NULL);
__Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
- if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ if (unlikely(!__pyx_t_14)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 586; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_14);
__Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0;
}
__pyx_L22:;
}
- /* "src/lxml/serializer.pxi":582
+ /* "src/lxml/serializer.pxi":591
* with_comments, c_buffer)
* error = tree.xmlOutputBufferClose(c_buffer)
* if bytes_count < 0: # <<<<<<<<<<<<<<
__pyx_t_6 = ((__pyx_v_bytes_count < 0) != 0);
if (__pyx_t_6) {
- /* "src/lxml/serializer.pxi":583
+ /* "src/lxml/serializer.pxi":592
* error = tree.xmlOutputBufferClose(c_buffer)
* if bytes_count < 0:
* error = bytes_count # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":586
+ /* "src/lxml/serializer.pxi":595
* else:
* raise TypeError(u"File or filename expected, got '%s'" %
* python._fqtypename(f).decode('UTF-8')) # <<<<<<<<<<<<<<
* _destroyFakeDoc(c_base_doc, c_doc)
*/
__pyx_t_15 = _fqtypename(__pyx_v_f);
- __pyx_t_8 = __Pyx_decode_c_string(__pyx_t_15, 0, strlen(__pyx_t_15), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 586; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_8 = __Pyx_decode_c_string(__pyx_t_15, 0, strlen(__pyx_t_15), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 595; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_8);
- /* "src/lxml/serializer.pxi":585
+ /* "src/lxml/serializer.pxi":594
* error = bytes_count
* else:
* raise TypeError(u"File or filename expected, got '%s'" % # <<<<<<<<<<<<<<
* python._fqtypename(f).decode('UTF-8'))
* finally:
*/
- __pyx_t_7 = PyUnicode_Format(__pyx_kp_u_File_or_filename_expected_got_s, __pyx_t_8); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_7 = PyUnicode_Format(__pyx_kp_u_File_or_filename_expected_got_s, __pyx_t_8); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 594; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
- __pyx_t_8 = PyTuple_New(1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_8 = PyTuple_New(1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 594; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_8);
PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7);
__Pyx_GIVEREF(__pyx_t_7);
__pyx_t_7 = 0;
- __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_8, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_8, NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 594; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
__Pyx_Raise(__pyx_t_7, 0, 0, 0);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 585; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 594; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
}
__pyx_L6:;
}
- /* "src/lxml/serializer.pxi":588
+ /* "src/lxml/serializer.pxi":597
* python._fqtypename(f).decode('UTF-8'))
* finally:
* _destroyFakeDoc(c_base_doc, c_doc) # <<<<<<<<<<<<<<
/*normal exit:*/{
__pyx_f_4lxml_5etree__destroyFakeDoc(__pyx_v_c_base_doc, __pyx_v_c_doc);
- /* "src/lxml/serializer.pxi":589
+ /* "src/lxml/serializer.pxi":598
* finally:
* _destroyFakeDoc(c_base_doc, c_doc)
* if c_inclusive_ns_prefixes is not NULL: # <<<<<<<<<<<<<<
__pyx_t_6 = ((__pyx_v_c_inclusive_ns_prefixes != NULL) != 0);
if (__pyx_t_6) {
- /* "src/lxml/serializer.pxi":590
+ /* "src/lxml/serializer.pxi":599
* _destroyFakeDoc(c_base_doc, c_doc)
* if c_inclusive_ns_prefixes is not NULL:
* python.PyMem_Free(c_inclusive_ns_prefixes) # <<<<<<<<<<<<<<
__pyx_t_11 = __pyx_lineno; __pyx_t_16 = __pyx_clineno; __pyx_t_17 = __pyx_filename;
{
- /* "src/lxml/serializer.pxi":588
+ /* "src/lxml/serializer.pxi":597
* python._fqtypename(f).decode('UTF-8'))
* finally:
* _destroyFakeDoc(c_base_doc, c_doc) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__destroyFakeDoc(__pyx_v_c_base_doc, __pyx_v_c_doc);
- /* "src/lxml/serializer.pxi":589
+ /* "src/lxml/serializer.pxi":598
* finally:
* _destroyFakeDoc(c_base_doc, c_doc)
* if c_inclusive_ns_prefixes is not NULL: # <<<<<<<<<<<<<<
__pyx_t_6 = ((__pyx_v_c_inclusive_ns_prefixes != NULL) != 0);
if (__pyx_t_6) {
- /* "src/lxml/serializer.pxi":590
+ /* "src/lxml/serializer.pxi":599
* _destroyFakeDoc(c_base_doc, c_doc)
* if c_inclusive_ns_prefixes is not NULL:
* python.PyMem_Free(c_inclusive_ns_prefixes) # <<<<<<<<<<<<<<
__pyx_L5:;
}
- /* "src/lxml/serializer.pxi":592
+ /* "src/lxml/serializer.pxi":601
* python.PyMem_Free(c_inclusive_ns_prefixes)
*
* if writer is not None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_6 != 0);
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":593
+ /* "src/lxml/serializer.pxi":602
*
* if writer is not None:
* writer._exc_context._raise_if_stored() # <<<<<<<<<<<<<<
*
* if error < 0:
*/
- __pyx_t_16 = ((struct __pyx_vtabstruct_4lxml_5etree__ExceptionContext *)__pyx_v_writer->_exc_context->__pyx_vtab)->_raise_if_stored(__pyx_v_writer->_exc_context); if (unlikely(__pyx_t_16 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 593; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_16 = ((struct __pyx_vtabstruct_4lxml_5etree__ExceptionContext *)__pyx_v_writer->_exc_context->__pyx_vtab)->_raise_if_stored(__pyx_v_writer->_exc_context); if (unlikely(__pyx_t_16 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 602; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L28;
}
__pyx_L28:;
- /* "src/lxml/serializer.pxi":595
+ /* "src/lxml/serializer.pxi":604
* writer._exc_context._raise_if_stored()
*
* if error < 0: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_error < 0) != 0);
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":596
+ /* "src/lxml/serializer.pxi":605
*
* if error < 0:
* message = u"C14N failed" # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_kp_u_C14N_failed);
__pyx_v_message = __pyx_kp_u_C14N_failed;
- /* "src/lxml/serializer.pxi":597
+ /* "src/lxml/serializer.pxi":606
* if error < 0:
* message = u"C14N failed"
* if writer is not None: # <<<<<<<<<<<<<<
__pyx_t_6 = (__pyx_t_3 != 0);
if (__pyx_t_6) {
- /* "src/lxml/serializer.pxi":598
+ /* "src/lxml/serializer.pxi":607
* message = u"C14N failed"
* if writer is not None:
* errors = writer.error_log # <<<<<<<<<<<<<<
__pyx_v_errors = ((struct __pyx_obj_4lxml_5etree__ErrorLog *)__pyx_t_7);
__pyx_t_7 = 0;
- /* "src/lxml/serializer.pxi":599
+ /* "src/lxml/serializer.pxi":608
* if writer is not None:
* errors = writer.error_log
* if len(errors): # <<<<<<<<<<<<<<
* message = errors[0].message
* raise C14NError(message)
*/
- __pyx_t_20 = PyObject_Length(((PyObject *)__pyx_v_errors)); if (unlikely(__pyx_t_20 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 599; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_20 = PyObject_Length(((PyObject *)__pyx_v_errors)); if (unlikely(__pyx_t_20 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 608; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_6 = (__pyx_t_20 != 0);
if (__pyx_t_6) {
- /* "src/lxml/serializer.pxi":600
+ /* "src/lxml/serializer.pxi":609
* errors = writer.error_log
* if len(errors):
* message = errors[0].message # <<<<<<<<<<<<<<
* raise C14NError(message)
*
*/
- __pyx_t_7 = __Pyx_GetItemInt(((PyObject *)__pyx_v_errors), 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_7 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 600; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_7 = __Pyx_GetItemInt(((PyObject *)__pyx_v_errors), 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_7 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 609; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_7);
- __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_message); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 600; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_message); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 609; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF_SET(__pyx_v_message, __pyx_t_8);
}
__pyx_L30:;
- /* "src/lxml/serializer.pxi":601
+ /* "src/lxml/serializer.pxi":610
* if len(errors):
* message = errors[0].message
* raise C14NError(message) # <<<<<<<<<<<<<<
*
* # incremental serialisation
*/
- __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_C14NError); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_C14NError); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_7))) {
}
}
if (!__pyx_t_5) {
- __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_v_message); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_v_message); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
} else {
- __pyx_t_21 = PyTuple_New(1+1); if (unlikely(!__pyx_t_21)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_21 = PyTuple_New(1+1); if (unlikely(!__pyx_t_21)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_21);
PyTuple_SET_ITEM(__pyx_t_21, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_message);
PyTuple_SET_ITEM(__pyx_t_21, 0+1, __pyx_v_message);
__Pyx_GIVEREF(__pyx_v_message);
- __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_21, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_21, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
__Pyx_DECREF(__pyx_t_21); __pyx_t_21 = 0;
}
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_Raise(__pyx_t_8, 0, 0, 0);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 601; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 610; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":550
+ /* "src/lxml/serializer.pxi":559
* return c_ns_prefixes
*
* cdef _tofilelikeC14N(f, _Element element, bint exclusive, bint with_comments, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":649
+/* "src/lxml/serializer.pxi":658
* cdef int method
*
* def __init__(self, output_file not None, encoding=None, compression=None, # <<<<<<<<<<<<<<
values[1] = ((PyObject *)Py_None);
values[2] = ((PyObject *)Py_None);
- /* "src/lxml/serializer.pxi":650
+ /* "src/lxml/serializer.pxi":659
*
* def __init__(self, output_file not None, encoding=None, compression=None,
* close=False, buffered=True): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 649; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 658; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 5, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 649; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 5, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 658; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.xmlfile.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
if (unlikely(((PyObject *)__pyx_v_output_file) == Py_None)) {
- PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "output_file"); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 649; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyErr_Format(PyExc_TypeError, "Argument '%.200s' must not be None", "output_file"); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 658; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_r = __pyx_pf_4lxml_5etree_7xmlfile___init__(((struct __pyx_obj_4lxml_5etree_xmlfile *)__pyx_v_self), __pyx_v_output_file, __pyx_v_encoding, __pyx_v_compression, __pyx_v_close, __pyx_v_buffered);
- /* "src/lxml/serializer.pxi":649
+ /* "src/lxml/serializer.pxi":658
* cdef int method
*
* def __init__(self, output_file not None, encoding=None, compression=None, # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__init__", 0);
- /* "src/lxml/serializer.pxi":651
+ /* "src/lxml/serializer.pxi":660
* def __init__(self, output_file not None, encoding=None, compression=None,
* close=False, buffered=True):
* self.output_file = output_file # <<<<<<<<<<<<<<
__Pyx_DECREF(__pyx_v_self->output_file);
__pyx_v_self->output_file = __pyx_v_output_file;
- /* "src/lxml/serializer.pxi":652
+ /* "src/lxml/serializer.pxi":661
* close=False, buffered=True):
* self.output_file = output_file
* self.encoding = _utf8orNone(encoding) # <<<<<<<<<<<<<<
* self.compresslevel = compression or 0
* self.close = close
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__utf8orNone(__pyx_v_encoding); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 652; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__utf8orNone(__pyx_v_encoding); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 661; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_self->encoding);
__pyx_v_self->encoding = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":653
+ /* "src/lxml/serializer.pxi":662
* self.output_file = output_file
* self.encoding = _utf8orNone(encoding)
* self.compresslevel = compression or 0 # <<<<<<<<<<<<<<
* self.close = close
* self.buffered = buffered
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_compression); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 653; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_compression); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 662; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (!__pyx_t_3) {
} else {
- __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 653; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_v_compression); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 662; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = __pyx_t_4;
goto __pyx_L3_bool_binop_done;
}
__pyx_L3_bool_binop_done:;
__pyx_v_self->compresslevel = __pyx_t_2;
- /* "src/lxml/serializer.pxi":654
+ /* "src/lxml/serializer.pxi":663
* self.encoding = _utf8orNone(encoding)
* self.compresslevel = compression or 0
* self.close = close # <<<<<<<<<<<<<<
* self.buffered = buffered
* self.method = OUTPUT_METHOD_XML
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_close); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_close); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 663; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_self->close = __pyx_t_3;
- /* "src/lxml/serializer.pxi":655
+ /* "src/lxml/serializer.pxi":664
* self.compresslevel = compression or 0
* self.close = close
* self.buffered = buffered # <<<<<<<<<<<<<<
* self.method = OUTPUT_METHOD_XML
*
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_buffered); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_buffered); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 664; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_self->buffered = __pyx_t_3;
- /* "src/lxml/serializer.pxi":656
+ /* "src/lxml/serializer.pxi":665
* self.close = close
* self.buffered = buffered
* self.method = OUTPUT_METHOD_XML # <<<<<<<<<<<<<<
*/
__pyx_v_self->method = __pyx_e_4lxml_5etree_OUTPUT_METHOD_XML;
- /* "src/lxml/serializer.pxi":649
+ /* "src/lxml/serializer.pxi":658
* cdef int method
*
* def __init__(self, output_file not None, encoding=None, compression=None, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":658
+/* "src/lxml/serializer.pxi":667
* self.method = OUTPUT_METHOD_XML
*
* def __enter__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__enter__", 0);
- /* "src/lxml/serializer.pxi":659
+ /* "src/lxml/serializer.pxi":668
*
* def __enter__(self):
* assert self.output_file is not None # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_self->output_file != Py_None);
if (unlikely(!(__pyx_t_1 != 0))) {
PyErr_SetNone(PyExc_AssertionError);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 659; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/serializer.pxi":661
+ /* "src/lxml/serializer.pxi":670
* assert self.output_file is not None
* self.writer = _IncrementalFileWriter(
* self.output_file, self.encoding, self.compresslevel, # <<<<<<<<<<<<<<
* self.close, self.buffered, self.method)
* return self.writer
*/
- __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->compresslevel); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 661; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->compresslevel); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- /* "src/lxml/serializer.pxi":662
+ /* "src/lxml/serializer.pxi":671
* self.writer = _IncrementalFileWriter(
* self.output_file, self.encoding, self.compresslevel,
* self.close, self.buffered, self.method) # <<<<<<<<<<<<<<
* return self.writer
*
*/
- __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_self->close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 662; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_self->close); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = __Pyx_PyBool_FromLong(__pyx_v_self->buffered); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 662; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyBool_FromLong(__pyx_v_self->buffered); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_self->method); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 662; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_self->method); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 671; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- /* "src/lxml/serializer.pxi":660
+ /* "src/lxml/serializer.pxi":669
* def __enter__(self):
* assert self.output_file is not None
* self.writer = _IncrementalFileWriter( # <<<<<<<<<<<<<<
* self.output_file, self.encoding, self.compresslevel,
* self.close, self.buffered, self.method)
*/
- __pyx_t_6 = PyTuple_New(6); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 660; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(6); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_INCREF(__pyx_v_self->output_file);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_v_self->output_file);
__pyx_t_3 = 0;
__pyx_t_4 = 0;
__pyx_t_5 = 0;
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__IncrementalFileWriter)), __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 660; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__IncrementalFileWriter)), __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_GIVEREF(__pyx_t_5);
__pyx_v_self->writer = ((struct __pyx_obj_4lxml_5etree__IncrementalFileWriter *)__pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":663
+ /* "src/lxml/serializer.pxi":672
* self.output_file, self.encoding, self.compresslevel,
* self.close, self.buffered, self.method)
* return self.writer # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_self->writer);
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":658
+ /* "src/lxml/serializer.pxi":667
* self.method = OUTPUT_METHOD_XML
*
* def __enter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":665
+/* "src/lxml/serializer.pxi":674
* return self.writer
*
* def __exit__(self, exc_type, exc_val, exc_tb): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_exc_val)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_exc_tb)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 2); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 2); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__exit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__exit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree.xmlfile.__exit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__exit__", 0);
- /* "src/lxml/serializer.pxi":666
+ /* "src/lxml/serializer.pxi":675
*
* def __exit__(self, exc_type, exc_val, exc_tb):
* if self.writer is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":667
+ /* "src/lxml/serializer.pxi":676
* def __exit__(self, exc_type, exc_val, exc_tb):
* if self.writer is not None:
* old_writer, self.writer = self.writer, None # <<<<<<<<<<<<<<
__pyx_v_self->writer = ((struct __pyx_obj_4lxml_5etree__IncrementalFileWriter *)__pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":668
+ /* "src/lxml/serializer.pxi":677
* if self.writer is not None:
* old_writer, self.writer = self.writer, None
* raise_on_error = exc_type is None # <<<<<<<<<<<<<<
* if self.close:
*/
__pyx_t_2 = (__pyx_v_exc_type == Py_None);
- __pyx_t_4 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyBool_FromLong(__pyx_t_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 677; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_raise_on_error = __pyx_t_4;
__pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":669
+ /* "src/lxml/serializer.pxi":678
* old_writer, self.writer = self.writer, None
* raise_on_error = exc_type is None
* old_writer._close(raise_on_error) # <<<<<<<<<<<<<<
* if self.close:
* self.output_file = None
*/
- __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_raise_on_error); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_4 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__close(__pyx_v_old_writer, __pyx_t_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 669; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_raise_on_error); if (unlikely((__pyx_t_2 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 678; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__close(__pyx_v_old_writer, __pyx_t_2); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 678; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":670
+ /* "src/lxml/serializer.pxi":679
* raise_on_error = exc_type is None
* old_writer._close(raise_on_error)
* if self.close: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_v_self->close != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":671
+ /* "src/lxml/serializer.pxi":680
* old_writer._close(raise_on_error)
* if self.close:
* self.output_file = None # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":665
+ /* "src/lxml/serializer.pxi":674
* return self.writer
*
* def __exit__(self, exc_type, exc_val, exc_tb): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":680
+/* "src/lxml/serializer.pxi":689
* xmlfile.
* """
* def __init__(self, *args, **kwargs): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__init__", 0);
- /* "src/lxml/serializer.pxi":681
+ /* "src/lxml/serializer.pxi":690
* """
* def __init__(self, *args, **kwargs):
* super().__init__(*args, **kwargs) # <<<<<<<<<<<<<<
* self.method = OUTPUT_METHOD_HTML
*
*/
- __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 681; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 690; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_htmlfile)));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_htmlfile)));
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_self));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self));
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 681; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_super, __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 690; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 681; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_init); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 690; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_2 = PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 681; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PySequence_Tuple(__pyx_v_args); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 690; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_3 = __pyx_v_kwargs;
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 681; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 690; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":682
+ /* "src/lxml/serializer.pxi":691
* def __init__(self, *args, **kwargs):
* super().__init__(*args, **kwargs)
* self.method = OUTPUT_METHOD_HTML # <<<<<<<<<<<<<<
*/
__pyx_v_self->__pyx_base.method = __pyx_e_4lxml_5etree_OUTPUT_METHOD_HTML;
- /* "src/lxml/serializer.pxi":680
+ /* "src/lxml/serializer.pxi":689
* xmlfile.
* """
* def __init__(self, *args, **kwargs): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":705
+/* "src/lxml/serializer.pxi":714
* cdef bint _buffered
*
* def __cinit__(self, outfile, bytes encoding, int compresslevel, bint close, # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_encoding)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_compresslevel)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 2); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 2); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_close)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 3); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 3); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_buffered)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 4); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 4); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
if (likely((values[5] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_method)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 5); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, 5); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
goto __pyx_L5_argtuple_error;
}
__pyx_v_outfile = values[0];
__pyx_v_encoding = ((PyObject*)values[1]);
- __pyx_v_compresslevel = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_compresslevel == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_close = __Pyx_PyObject_IsTrue(values[3]); if (unlikely((__pyx_v_close == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_buffered = __Pyx_PyObject_IsTrue(values[4]); if (unlikely((__pyx_v_buffered == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 706; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_method = __Pyx_PyInt_As_int(values[5]); if (unlikely((__pyx_v_method == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 706; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_compresslevel = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_compresslevel == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_close = __Pyx_PyObject_IsTrue(values[3]); if (unlikely((__pyx_v_close == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_buffered = __Pyx_PyObject_IsTrue(values[4]); if (unlikely((__pyx_v_buffered == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_method = __Pyx_PyInt_As_int(values[5]); if (unlikely((__pyx_v_method == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 715; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._IncrementalFileWriter.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_encoding), (&PyBytes_Type), 1, "encoding", 1))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 705; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_encoding), (&PyBytes_Type), 1, "encoding", 1))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_22_IncrementalFileWriter___cinit__(((struct __pyx_obj_4lxml_5etree__IncrementalFileWriter *)__pyx_v_self), __pyx_v_outfile, __pyx_v_encoding, __pyx_v_compresslevel, __pyx_v_close, __pyx_v_buffered, __pyx_v_method);
/* function exit code */
__Pyx_RefNannySetupContext("__cinit__", 0);
__Pyx_INCREF(__pyx_v_encoding);
- /* "src/lxml/serializer.pxi":707
+ /* "src/lxml/serializer.pxi":716
* def __cinit__(self, outfile, bytes encoding, int compresslevel, bint close,
* bint buffered, int method):
* self._status = WRITER_STARTING # <<<<<<<<<<<<<<
*/
__pyx_v_self->_status = __pyx_e_4lxml_5etree_WRITER_STARTING;
- /* "src/lxml/serializer.pxi":708
+ /* "src/lxml/serializer.pxi":717
* bint buffered, int method):
* self._status = WRITER_STARTING
* self._element_stack = [] # <<<<<<<<<<<<<<
* if encoding is None:
* encoding = b'ASCII'
*/
- __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 708; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 717; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_self->_element_stack);
__pyx_v_self->_element_stack = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":709
+ /* "src/lxml/serializer.pxi":718
* self._status = WRITER_STARTING
* self._element_stack = []
* if encoding is None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":710
+ /* "src/lxml/serializer.pxi":719
* self._element_stack = []
* if encoding is None:
* encoding = b'ASCII' # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":711
+ /* "src/lxml/serializer.pxi":720
* if encoding is None:
* encoding = b'ASCII'
* self._encoding = encoding # <<<<<<<<<<<<<<
__Pyx_DECREF(__pyx_v_self->_encoding);
__pyx_v_self->_encoding = __pyx_v_encoding;
- /* "src/lxml/serializer.pxi":712
+ /* "src/lxml/serializer.pxi":721
* encoding = b'ASCII'
* self._encoding = encoding
* self._c_encoding = _cstr(encoding) if encoding is not None else NULL # <<<<<<<<<<<<<<
}
__pyx_v_self->_c_encoding = __pyx_t_4;
- /* "src/lxml/serializer.pxi":713
+ /* "src/lxml/serializer.pxi":722
* self._encoding = encoding
* self._c_encoding = _cstr(encoding) if encoding is not None else NULL
* self._buffered = buffered # <<<<<<<<<<<<<<
*/
__pyx_v_self->_buffered = __pyx_v_buffered;
- /* "src/lxml/serializer.pxi":714
+ /* "src/lxml/serializer.pxi":723
* self._c_encoding = _cstr(encoding) if encoding is not None else NULL
* self._buffered = buffered
* self._target = _create_output_buffer( # <<<<<<<<<<<<<<
* outfile, self._c_encoding, compresslevel, &self._c_out, close)
* self._method = method
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__create_output_buffer(__pyx_v_outfile, __pyx_v_self->_c_encoding, __pyx_v_compresslevel, (&__pyx_v_self->_c_out), __pyx_v_close); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__create_output_buffer(__pyx_v_outfile, __pyx_v_self->_c_encoding, __pyx_v_compresslevel, (&__pyx_v_self->_c_out), __pyx_v_close); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 723; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__FilelikeWriter))))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 714; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__FilelikeWriter))))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 723; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_self->_target);
__Pyx_DECREF(((PyObject *)__pyx_v_self->_target));
__pyx_v_self->_target = ((struct __pyx_obj_4lxml_5etree__FilelikeWriter *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":716
+ /* "src/lxml/serializer.pxi":725
* self._target = _create_output_buffer(
* outfile, self._c_encoding, compresslevel, &self._c_out, close)
* self._method = method # <<<<<<<<<<<<<<
*/
__pyx_v_self->_method = __pyx_v_method;
- /* "src/lxml/serializer.pxi":705
+ /* "src/lxml/serializer.pxi":714
* cdef bint _buffered
*
* def __cinit__(self, outfile, bytes encoding, int compresslevel, bint close, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":718
+/* "src/lxml/serializer.pxi":727
* self._method = method
*
* def __dealloc__(self): # <<<<<<<<<<<<<<
int __pyx_t_1;
__Pyx_RefNannySetupContext("__dealloc__", 0);
- /* "src/lxml/serializer.pxi":719
+ /* "src/lxml/serializer.pxi":728
*
* def __dealloc__(self):
* if self._c_out is not NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_c_out != NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":720
+ /* "src/lxml/serializer.pxi":729
* def __dealloc__(self):
* if self._c_out is not NULL:
* tree.xmlOutputBufferClose(self._c_out) # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":718
+ /* "src/lxml/serializer.pxi":727
* self._method = method
*
* def __dealloc__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyFinishContext();
}
-/* "src/lxml/serializer.pxi":722
+/* "src/lxml/serializer.pxi":731
* tree.xmlOutputBufferClose(self._c_out)
*
* def write_declaration(self, version=None, standalone=None, doctype=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "write_declaration") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 722; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "write_declaration") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("write_declaration", 0, 0, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 722; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("write_declaration", 0, 0, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._IncrementalFileWriter.write_declaration", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
__Pyx_INCREF(__pyx_v_version);
__Pyx_INCREF(__pyx_v_doctype);
- /* "src/lxml/serializer.pxi":727
+ /* "src/lxml/serializer.pxi":736
* Write an XML declaration and (optionally) a doctype into the file.
* """
* assert self._c_out is not NULL # <<<<<<<<<<<<<<
if (unlikely(!Py_OptimizeFlag)) {
if (unlikely(!((__pyx_v_self->_c_out != NULL) != 0))) {
PyErr_SetNone(PyExc_AssertionError);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/serializer.pxi":730
+ /* "src/lxml/serializer.pxi":739
* cdef const_xmlChar* c_version
* cdef int c_standalone
* if self._method != OUTPUT_METHOD_XML: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_method != __pyx_e_4lxml_5etree_OUTPUT_METHOD_XML) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":731
+ /* "src/lxml/serializer.pxi":740
* cdef int c_standalone
* if self._method != OUTPUT_METHOD_XML:
* raise LxmlSyntaxError("only XML documents have declarations") # <<<<<<<<<<<<<<
* if self._status >= WRITER_DECL_WRITTEN:
* raise LxmlSyntaxError("XML declaration already written")
*/
- __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__59, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__60, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":732
+ /* "src/lxml/serializer.pxi":741
* if self._method != OUTPUT_METHOD_XML:
* raise LxmlSyntaxError("only XML documents have declarations")
* if self._status >= WRITER_DECL_WRITTEN: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_status >= __pyx_e_4lxml_5etree_WRITER_DECL_WRITTEN) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":733
+ /* "src/lxml/serializer.pxi":742
* raise LxmlSyntaxError("only XML documents have declarations")
* if self._status >= WRITER_DECL_WRITTEN:
* raise LxmlSyntaxError("XML declaration already written") # <<<<<<<<<<<<<<
* version = _utf8orNone(version)
* c_version = _xcstr(version) if version is not None else NULL
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__60, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__61, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":734
+ /* "src/lxml/serializer.pxi":743
* if self._status >= WRITER_DECL_WRITTEN:
* raise LxmlSyntaxError("XML declaration already written")
* version = _utf8orNone(version) # <<<<<<<<<<<<<<
* c_version = _xcstr(version) if version is not None else NULL
* doctype = _utf8orNone(doctype)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__utf8orNone(__pyx_v_version); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__utf8orNone(__pyx_v_version); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF_SET(__pyx_v_version, __pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":735
+ /* "src/lxml/serializer.pxi":744
* raise LxmlSyntaxError("XML declaration already written")
* version = _utf8orNone(version)
* c_version = _xcstr(version) if version is not None else NULL # <<<<<<<<<<<<<<
}
__pyx_v_c_version = __pyx_t_4;
- /* "src/lxml/serializer.pxi":736
+ /* "src/lxml/serializer.pxi":745
* version = _utf8orNone(version)
* c_version = _xcstr(version) if version is not None else NULL
* doctype = _utf8orNone(doctype) # <<<<<<<<<<<<<<
* if standalone is None:
* c_standalone = -1
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__utf8orNone(__pyx_v_doctype); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__utf8orNone(__pyx_v_doctype); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF_SET(__pyx_v_doctype, __pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":737
+ /* "src/lxml/serializer.pxi":746
* c_version = _xcstr(version) if version is not None else NULL
* doctype = _utf8orNone(doctype)
* if standalone is None: # <<<<<<<<<<<<<<
__pyx_t_5 = (__pyx_t_1 != 0);
if (__pyx_t_5) {
- /* "src/lxml/serializer.pxi":738
+ /* "src/lxml/serializer.pxi":747
* doctype = _utf8orNone(doctype)
* if standalone is None:
* c_standalone = -1 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":740
+ /* "src/lxml/serializer.pxi":749
* c_standalone = -1
* else:
* c_standalone = 1 if standalone else 0 # <<<<<<<<<<<<<<
* _writeDeclarationToBuffer(self._c_out, c_version, self._c_encoding, c_standalone)
* if doctype is not None:
*/
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_standalone); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_standalone); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_5) {
__pyx_t_6 = 1;
} else {
}
__pyx_L5:;
- /* "src/lxml/serializer.pxi":741
+ /* "src/lxml/serializer.pxi":750
* else:
* c_standalone = 1 if standalone else 0
* _writeDeclarationToBuffer(self._c_out, c_version, self._c_encoding, c_standalone) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__writeDeclarationToBuffer(__pyx_v_self->_c_out, __pyx_v_c_version, __pyx_v_self->_c_encoding, __pyx_v_c_standalone);
- /* "src/lxml/serializer.pxi":742
+ /* "src/lxml/serializer.pxi":751
* c_standalone = 1 if standalone else 0
* _writeDeclarationToBuffer(self._c_out, c_version, self._c_encoding, c_standalone)
* if doctype is not None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_5 != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":743
+ /* "src/lxml/serializer.pxi":752
* _writeDeclarationToBuffer(self._c_out, c_version, self._c_encoding, c_standalone)
* if doctype is not None:
* _writeDoctype(self._c_out, _xcstr(doctype)) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__writeDoctype(__pyx_v_self->_c_out, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_doctype));
- /* "src/lxml/serializer.pxi":744
+ /* "src/lxml/serializer.pxi":753
* if doctype is not None:
* _writeDoctype(self._c_out, _xcstr(doctype))
* self._status = WRITER_DTD_WRITTEN # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":746
+ /* "src/lxml/serializer.pxi":755
* self._status = WRITER_DTD_WRITTEN
* else:
* self._status = WRITER_DECL_WRITTEN # <<<<<<<<<<<<<<
}
__pyx_L6:;
- /* "src/lxml/serializer.pxi":747
+ /* "src/lxml/serializer.pxi":756
* else:
* self._status = WRITER_DECL_WRITTEN
* if not self._buffered: # <<<<<<<<<<<<<<
__pyx_t_1 = ((!(__pyx_v_self->_buffered != 0)) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":748
+ /* "src/lxml/serializer.pxi":757
* self._status = WRITER_DECL_WRITTEN
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out) # <<<<<<<<<<<<<<
}
__pyx_L7:;
- /* "src/lxml/serializer.pxi":749
+ /* "src/lxml/serializer.pxi":758
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out)
* self._handle_error(self._c_out.error) # <<<<<<<<<<<<<<
*
* def write_doctype(self, doctype):
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 758; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":722
+ /* "src/lxml/serializer.pxi":731
* tree.xmlOutputBufferClose(self._c_out)
*
* def write_declaration(self, version=None, standalone=None, doctype=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":751
+/* "src/lxml/serializer.pxi":760
* self._handle_error(self._c_out.error)
*
* def write_doctype(self, doctype): # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("write_doctype", 0);
__Pyx_INCREF(__pyx_v_doctype);
- /* "src/lxml/serializer.pxi":756
+ /* "src/lxml/serializer.pxi":765
* Writes the given doctype declaration verbatimly into the file.
* """
* assert self._c_out is not NULL # <<<<<<<<<<<<<<
if (unlikely(!Py_OptimizeFlag)) {
if (unlikely(!((__pyx_v_self->_c_out != NULL) != 0))) {
PyErr_SetNone(PyExc_AssertionError);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 756; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 765; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/serializer.pxi":757
+ /* "src/lxml/serializer.pxi":766
* """
* assert self._c_out is not NULL
* if doctype is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":758
+ /* "src/lxml/serializer.pxi":767
* assert self._c_out is not NULL
* if doctype is None:
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":759
+ /* "src/lxml/serializer.pxi":768
* if doctype is None:
* return
* if self._status >= WRITER_DTD_WRITTEN: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_self->_status >= __pyx_e_4lxml_5etree_WRITER_DTD_WRITTEN) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":760
+ /* "src/lxml/serializer.pxi":769
* return
* if self._status >= WRITER_DTD_WRITTEN:
* raise LxmlSyntaxError("DOCTYPE already written or cannot write it here") # <<<<<<<<<<<<<<
* doctype = _utf8(doctype)
* _writeDoctype(self._c_out, _xcstr(doctype))
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__61, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__62, NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_Raise(__pyx_t_4, 0, 0, 0);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":761
+ /* "src/lxml/serializer.pxi":770
* if self._status >= WRITER_DTD_WRITTEN:
* raise LxmlSyntaxError("DOCTYPE already written or cannot write it here")
* doctype = _utf8(doctype) # <<<<<<<<<<<<<<
* _writeDoctype(self._c_out, _xcstr(doctype))
* self._status = WRITER_DTD_WRITTEN
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_v_doctype); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 761; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_v_doctype); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 770; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_doctype, __pyx_t_4);
__pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":762
+ /* "src/lxml/serializer.pxi":771
* raise LxmlSyntaxError("DOCTYPE already written or cannot write it here")
* doctype = _utf8(doctype)
* _writeDoctype(self._c_out, _xcstr(doctype)) # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__writeDoctype(__pyx_v_self->_c_out, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_doctype));
- /* "src/lxml/serializer.pxi":763
+ /* "src/lxml/serializer.pxi":772
* doctype = _utf8(doctype)
* _writeDoctype(self._c_out, _xcstr(doctype))
* self._status = WRITER_DTD_WRITTEN # <<<<<<<<<<<<<<
*/
__pyx_v_self->_status = __pyx_e_4lxml_5etree_WRITER_DTD_WRITTEN;
- /* "src/lxml/serializer.pxi":764
+ /* "src/lxml/serializer.pxi":773
* _writeDoctype(self._c_out, _xcstr(doctype))
* self._status = WRITER_DTD_WRITTEN
* if not self._buffered: # <<<<<<<<<<<<<<
__pyx_t_2 = ((!(__pyx_v_self->_buffered != 0)) != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":765
+ /* "src/lxml/serializer.pxi":774
* self._status = WRITER_DTD_WRITTEN
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out) # <<<<<<<<<<<<<<
}
__pyx_L5:;
- /* "src/lxml/serializer.pxi":766
+ /* "src/lxml/serializer.pxi":775
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out)
* self._handle_error(self._c_out.error) # <<<<<<<<<<<<<<
*
* def element(self, tag, attrib=None, nsmap=None, **_extra):
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 766; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 775; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":751
+ /* "src/lxml/serializer.pxi":760
* self._handle_error(self._c_out.error)
*
* def write_doctype(self, doctype): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":768
+/* "src/lxml/serializer.pxi":777
* self._handle_error(self._c_out.error)
*
* def element(self, tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "element") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 768; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, __pyx_v__extra, values, pos_args, "element") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 777; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("element", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 768; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("element", 0, 1, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 777; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v__extra); __pyx_v__extra = 0;
__Pyx_AddTraceback("lxml.etree._IncrementalFileWriter.element", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannySetupContext("element", 0);
__Pyx_INCREF(__pyx_v_attrib);
- /* "src/lxml/serializer.pxi":773
+ /* "src/lxml/serializer.pxi":782
* Returns a context manager that writes an opening and closing tag.
* """
* assert self._c_out is not NULL # <<<<<<<<<<<<<<
if (unlikely(!Py_OptimizeFlag)) {
if (unlikely(!((__pyx_v_self->_c_out != NULL) != 0))) {
PyErr_SetNone(PyExc_AssertionError);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 773; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 782; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/serializer.pxi":774
+ /* "src/lxml/serializer.pxi":783
* """
* assert self._c_out is not NULL
* attributes = [] # <<<<<<<<<<<<<<
* if attrib is not None:
* if isinstance(attrib, (dict, _Attrib)):
*/
- __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 774; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 783; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_attributes = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":775
+ /* "src/lxml/serializer.pxi":784
* assert self._c_out is not NULL
* attributes = []
* if attrib is not None: # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":776
+ /* "src/lxml/serializer.pxi":785
* attributes = []
* if attrib is not None:
* if isinstance(attrib, (dict, _Attrib)): # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":777
+ /* "src/lxml/serializer.pxi":786
* if attrib is not None:
* if isinstance(attrib, (dict, _Attrib)):
* attrib = attrib.items() # <<<<<<<<<<<<<<
* for name, value in attrib:
* if name not in _extra:
*/
- __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_attrib, __pyx_n_s_items); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 777; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_attrib, __pyx_n_s_items); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 786; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_t_6 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_5))) {
}
}
if (__pyx_t_6) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 777; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 786; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
- __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_5); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 777; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_5); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 786; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__pyx_L4:;
- /* "src/lxml/serializer.pxi":778
+ /* "src/lxml/serializer.pxi":787
* if isinstance(attrib, (dict, _Attrib)):
* attrib = attrib.items()
* for name, value in attrib: # <<<<<<<<<<<<<<
__pyx_t_1 = __pyx_v_attrib; __Pyx_INCREF(__pyx_t_1); __pyx_t_7 = 0;
__pyx_t_8 = NULL;
} else {
- __pyx_t_7 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_attrib); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_attrib); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_8 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
for (;;) {
if (likely(!__pyx_t_8)) {
if (likely(PyList_CheckExact(__pyx_t_1))) {
if (__pyx_t_7 >= PyList_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_5 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_5); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_5); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
} else {
if (__pyx_t_7 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_5); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_7); __Pyx_INCREF(__pyx_t_5); __pyx_t_7++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_7); __pyx_t_7++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
}
} else {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ else {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
break;
}
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_6);
__Pyx_INCREF(__pyx_t_9);
#else
- __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
#endif
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_10 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_10);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_t_11 = Py_TYPE(__pyx_t_10)->tp_iternext;
__Pyx_GOTREF(__pyx_t_6);
index = 1; __pyx_t_9 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_9)) goto __pyx_L9_unpacking_failed;
__Pyx_GOTREF(__pyx_t_9);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_11 = NULL;
__Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
goto __pyx_L10_unpacking_done;
__Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
__pyx_t_11 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 778; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L10_unpacking_done:;
}
__Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_6);
__Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_9);
__pyx_t_9 = 0;
- /* "src/lxml/serializer.pxi":779
+ /* "src/lxml/serializer.pxi":788
* attrib = attrib.items()
* for name, value in attrib:
* if name not in _extra: # <<<<<<<<<<<<<<
* ns, name = _getNsTag(name)
* attributes.append((ns, name, _utf8(value)))
*/
- __pyx_t_2 = (__Pyx_PyDict_Contains(__pyx_v_name, __pyx_v__extra, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 779; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyDict_Contains(__pyx_v_name, __pyx_v__extra, Py_NE)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = (__pyx_t_2 != 0);
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":780
+ /* "src/lxml/serializer.pxi":789
* for name, value in attrib:
* if name not in _extra:
* ns, name = _getNsTag(name) # <<<<<<<<<<<<<<
* attributes.append((ns, name, _utf8(value)))
* if _extra:
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_name); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_name); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
if (likely(__pyx_t_5 != Py_None)) {
PyObject* sequence = __pyx_t_5;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
__pyx_t_9 = PyTuple_GET_ITEM(sequence, 0);
__Pyx_INCREF(__pyx_t_9);
__Pyx_INCREF(__pyx_t_6);
#else
- __pyx_t_9 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
- __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
#endif
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 789; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_XDECREF_SET(__pyx_v_ns, __pyx_t_9);
__pyx_t_9 = 0;
__Pyx_DECREF_SET(__pyx_v_name, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":781
+ /* "src/lxml/serializer.pxi":790
* if name not in _extra:
* ns, name = _getNsTag(name)
* attributes.append((ns, name, _utf8(value))) # <<<<<<<<<<<<<<
* if _extra:
* for name, value in _extra.iteritems():
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 781; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 781; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_INCREF(__pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
__pyx_t_5 = 0;
- __pyx_t_12 = __Pyx_PyList_Append(__pyx_v_attributes, __pyx_t_6); if (unlikely(__pyx_t_12 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 781; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_12 = __Pyx_PyList_Append(__pyx_v_attributes, __pyx_t_6); if (unlikely(__pyx_t_12 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
goto __pyx_L11;
}
__pyx_L11:;
- /* "src/lxml/serializer.pxi":778
+ /* "src/lxml/serializer.pxi":787
* if isinstance(attrib, (dict, _Attrib)):
* attrib = attrib.items()
* for name, value in attrib: # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":782
+ /* "src/lxml/serializer.pxi":791
* ns, name = _getNsTag(name)
* attributes.append((ns, name, _utf8(value)))
* if _extra: # <<<<<<<<<<<<<<
* for name, value in _extra.iteritems():
* ns, name = _getNsTag(name)
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v__extra); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 782; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v__extra); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":783
+ /* "src/lxml/serializer.pxi":792
* attributes.append((ns, name, _utf8(value)))
* if _extra:
* for name, value in _extra.iteritems(): # <<<<<<<<<<<<<<
* attributes.append((ns, name, _utf8(value)))
*/
__pyx_t_7 = 0;
- __pyx_t_6 = __Pyx_dict_iterator(__pyx_v__extra, 1, __pyx_n_s_iteritems, (&__pyx_t_13), (&__pyx_t_14)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 783; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_dict_iterator(__pyx_v__extra, 1, __pyx_n_s_iteritems, (&__pyx_t_13), (&__pyx_t_14)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 792; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_XDECREF(__pyx_t_1);
__pyx_t_1 = __pyx_t_6;
while (1) {
__pyx_t_15 = __Pyx_dict_iter_next(__pyx_t_1, __pyx_t_13, &__pyx_t_7, &__pyx_t_6, &__pyx_t_5, NULL, __pyx_t_14);
if (unlikely(__pyx_t_15 == 0)) break;
- if (unlikely(__pyx_t_15 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 783; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_15 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 792; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_5);
__Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_6);
__Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":784
+ /* "src/lxml/serializer.pxi":793
* if _extra:
* for name, value in _extra.iteritems():
* ns, name = _getNsTag(name) # <<<<<<<<<<<<<<
* attributes.append((ns, name, _utf8(value)))
* reversed_nsmap = {}
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_name); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 784; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_name); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
if (likely(__pyx_t_5 != Py_None)) {
PyObject* sequence = __pyx_t_5;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 784; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
__pyx_t_6 = PyTuple_GET_ITEM(sequence, 0);
__Pyx_INCREF(__pyx_t_6);
__Pyx_INCREF(__pyx_t_9);
#else
- __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 784; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 784; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
#endif
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 784; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_XDECREF_SET(__pyx_v_ns, __pyx_t_6);
__pyx_t_6 = 0;
__Pyx_DECREF_SET(__pyx_v_name, __pyx_t_9);
__pyx_t_9 = 0;
- /* "src/lxml/serializer.pxi":785
+ /* "src/lxml/serializer.pxi":794
* for name, value in _extra.iteritems():
* ns, name = _getNsTag(name)
* attributes.append((ns, name, _utf8(value))) # <<<<<<<<<<<<<<
* reversed_nsmap = {}
* if nsmap:
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 785; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_9 = PyTuple_New(3); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 785; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyTuple_New(3); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__Pyx_INCREF(__pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_9, 2, __pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
__pyx_t_5 = 0;
- __pyx_t_12 = __Pyx_PyList_Append(__pyx_v_attributes, __pyx_t_9); if (unlikely(__pyx_t_12 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 785; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_12 = __Pyx_PyList_Append(__pyx_v_attributes, __pyx_t_9); if (unlikely(__pyx_t_12 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
}
__pyx_L12:;
- /* "src/lxml/serializer.pxi":786
+ /* "src/lxml/serializer.pxi":795
* ns, name = _getNsTag(name)
* attributes.append((ns, name, _utf8(value)))
* reversed_nsmap = {} # <<<<<<<<<<<<<<
* if nsmap:
* for prefix, ns in nsmap.items():
*/
- __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 786; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 795; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_reversed_nsmap = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":787
+ /* "src/lxml/serializer.pxi":796
* attributes.append((ns, name, _utf8(value)))
* reversed_nsmap = {}
* if nsmap: # <<<<<<<<<<<<<<
* for prefix, ns in nsmap.items():
* if prefix is not None:
*/
- __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_nsmap); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 787; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_nsmap); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 796; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_3) {
- /* "src/lxml/serializer.pxi":788
+ /* "src/lxml/serializer.pxi":797
* reversed_nsmap = {}
* if nsmap:
* for prefix, ns in nsmap.items(): # <<<<<<<<<<<<<<
* if prefix is not None:
* prefix = _utf8(prefix)
*/
- __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_nsmap, __pyx_n_s_items); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_nsmap, __pyx_n_s_items); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_9))) {
}
}
if (__pyx_t_5) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_t_5); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_9, __pyx_t_5); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
- __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_9); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_9); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
__pyx_t_9 = __pyx_t_1; __Pyx_INCREF(__pyx_t_9); __pyx_t_13 = 0;
__pyx_t_8 = NULL;
} else {
- __pyx_t_13 = -1; __pyx_t_9 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_13 = -1; __pyx_t_9 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
- __pyx_t_8 = Py_TYPE(__pyx_t_9)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = Py_TYPE(__pyx_t_9)->tp_iternext; if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
for (;;) {
if (likely(PyList_CheckExact(__pyx_t_9))) {
if (__pyx_t_13 >= PyList_GET_SIZE(__pyx_t_9)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_1 = PyList_GET_ITEM(__pyx_t_9, __pyx_t_13); __Pyx_INCREF(__pyx_t_1); __pyx_t_13++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_GET_ITEM(__pyx_t_9, __pyx_t_13); __Pyx_INCREF(__pyx_t_1); __pyx_t_13++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_1 = PySequence_ITEM(__pyx_t_9, __pyx_t_13); __pyx_t_13++; if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PySequence_ITEM(__pyx_t_9, __pyx_t_13); __pyx_t_13++; if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
} else {
if (__pyx_t_13 >= PyTuple_GET_SIZE(__pyx_t_9)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_9, __pyx_t_13); __Pyx_INCREF(__pyx_t_1); __pyx_t_13++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_9, __pyx_t_13); __Pyx_INCREF(__pyx_t_1); __pyx_t_13++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_1 = PySequence_ITEM(__pyx_t_9, __pyx_t_13); __pyx_t_13++; if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PySequence_ITEM(__pyx_t_9, __pyx_t_13); __pyx_t_13++; if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
}
} else {
PyObject* exc_type = PyErr_Occurred();
if (exc_type) {
if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
- else {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ else {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
break;
}
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_5);
__Pyx_INCREF(__pyx_t_6);
#else
- __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
#endif
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_10 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_10);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_11 = Py_TYPE(__pyx_t_10)->tp_iternext;
__Pyx_GOTREF(__pyx_t_5);
index = 1; __pyx_t_6 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_6)) goto __pyx_L18_unpacking_failed;
__Pyx_GOTREF(__pyx_t_6);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_11 = NULL;
__Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
goto __pyx_L19_unpacking_done;
__Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
__pyx_t_11 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 788; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 797; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L19_unpacking_done:;
}
__Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_5);
__Pyx_XDECREF_SET(__pyx_v_ns, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":789
+ /* "src/lxml/serializer.pxi":798
* if nsmap:
* for prefix, ns in nsmap.items():
* if prefix is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_3 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":790
+ /* "src/lxml/serializer.pxi":799
* for prefix, ns in nsmap.items():
* if prefix is not None:
* prefix = _utf8(prefix) # <<<<<<<<<<<<<<
* _prefixValidOrRaise(prefix)
* reversed_nsmap[_utf8(ns)] = prefix
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_prefix); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 790; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_prefix); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 799; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF_SET(__pyx_v_prefix, __pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":791
+ /* "src/lxml/serializer.pxi":800
* if prefix is not None:
* prefix = _utf8(prefix)
* _prefixValidOrRaise(prefix) # <<<<<<<<<<<<<<
* reversed_nsmap[_utf8(ns)] = prefix
* ns, name = _getNsTag(tag)
*/
- __pyx_t_14 = __pyx_f_4lxml_5etree__prefixValidOrRaise(__pyx_v_prefix); if (unlikely(__pyx_t_14 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 791; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_14 = __pyx_f_4lxml_5etree__prefixValidOrRaise(__pyx_v_prefix); if (unlikely(__pyx_t_14 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L20;
}
__pyx_L20:;
- /* "src/lxml/serializer.pxi":792
+ /* "src/lxml/serializer.pxi":801
* prefix = _utf8(prefix)
* _prefixValidOrRaise(prefix)
* reversed_nsmap[_utf8(ns)] = prefix # <<<<<<<<<<<<<<
* ns, name = _getNsTag(tag)
* return _FileWriterElement(self, (ns, name, attributes, reversed_nsmap))
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_ns); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 792; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__utf8(__pyx_v_ns); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 801; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (unlikely(PyDict_SetItem(__pyx_v_reversed_nsmap, __pyx_t_1, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 792; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(PyDict_SetItem(__pyx_v_reversed_nsmap, __pyx_t_1, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 801; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":788
+ /* "src/lxml/serializer.pxi":797
* reversed_nsmap = {}
* if nsmap:
* for prefix, ns in nsmap.items(): # <<<<<<<<<<<<<<
}
__pyx_L15:;
- /* "src/lxml/serializer.pxi":793
+ /* "src/lxml/serializer.pxi":802
* _prefixValidOrRaise(prefix)
* reversed_nsmap[_utf8(ns)] = prefix
* ns, name = _getNsTag(tag) # <<<<<<<<<<<<<<
* return _FileWriterElement(self, (ns, name, attributes, reversed_nsmap))
*
*/
- __pyx_t_9 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_tag); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __pyx_f_4lxml_5etree__getNsTag(__pyx_v_tag); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (likely(__pyx_t_9 != Py_None)) {
PyObject* sequence = __pyx_t_9;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
__pyx_t_1 = PyTuple_GET_ITEM(sequence, 0);
__Pyx_INCREF(__pyx_t_1);
__Pyx_INCREF(__pyx_t_6);
#else
- __pyx_t_1 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
#endif
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
} else {
- __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 793; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_RaiseNoneNotIterableError(); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_XDECREF_SET(__pyx_v_ns, __pyx_t_1);
__pyx_t_1 = 0;
__Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":794
+ /* "src/lxml/serializer.pxi":803
* reversed_nsmap[_utf8(ns)] = prefix
* ns, name = _getNsTag(tag)
* return _FileWriterElement(self, (ns, name, attributes, reversed_nsmap)) # <<<<<<<<<<<<<<
* cdef _write_qname(self, bytes name, bytes prefix):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_9 = PyTuple_New(4); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyTuple_New(4); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 803; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__Pyx_INCREF(__pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_ns);
__Pyx_INCREF(__pyx_v_reversed_nsmap);
PyTuple_SET_ITEM(__pyx_t_9, 3, __pyx_v_reversed_nsmap);
__Pyx_GIVEREF(__pyx_v_reversed_nsmap);
- __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 803; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_INCREF(((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_6, 0, ((PyObject *)__pyx_v_self));
PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_9);
__Pyx_GIVEREF(__pyx_t_9);
__pyx_t_9 = 0;
- __pyx_t_9 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__FileWriterElement)), __pyx_t_6, NULL); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 794; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__FileWriterElement)), __pyx_t_6, NULL); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 803; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_r = __pyx_t_9;
__pyx_t_9 = 0;
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":768
+ /* "src/lxml/serializer.pxi":777
* self._handle_error(self._c_out.error)
*
* def element(self, tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":796
+/* "src/lxml/serializer.pxi":805
* return _FileWriterElement(self, (ns, name, attributes, reversed_nsmap))
*
* cdef _write_qname(self, bytes name, bytes prefix): # <<<<<<<<<<<<<<
- * if prefix is not None:
+ * if prefix: # empty bytes for no prefix (not None to allow sorting)
* tree.xmlOutputBufferWrite(self._c_out, len(prefix), _cstr(prefix))
*/
PyObject *__pyx_r = NULL;
__Pyx_RefNannyDeclarations
int __pyx_t_1;
- int __pyx_t_2;
- Py_ssize_t __pyx_t_3;
+ Py_ssize_t __pyx_t_2;
int __pyx_lineno = 0;
const char *__pyx_filename = NULL;
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_write_qname", 0);
- /* "src/lxml/serializer.pxi":797
+ /* "src/lxml/serializer.pxi":806
*
* cdef _write_qname(self, bytes name, bytes prefix):
- * if prefix is not None: # <<<<<<<<<<<<<<
+ * if prefix: # empty bytes for no prefix (not None to allow sorting) # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWrite(self._c_out, len(prefix), _cstr(prefix))
* tree.xmlOutputBufferWrite(self._c_out, 1, ':')
*/
- __pyx_t_1 = (__pyx_v_prefix != ((PyObject*)Py_None));
- __pyx_t_2 = (__pyx_t_1 != 0);
- if (__pyx_t_2) {
+ __pyx_t_1 = (__pyx_v_prefix != Py_None) && (PyBytes_GET_SIZE(__pyx_v_prefix) != 0);
+ if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":798
+ /* "src/lxml/serializer.pxi":807
* cdef _write_qname(self, bytes name, bytes prefix):
- * if prefix is not None:
+ * if prefix: # empty bytes for no prefix (not None to allow sorting)
* tree.xmlOutputBufferWrite(self._c_out, len(prefix), _cstr(prefix)) # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWrite(self._c_out, 1, ':')
* tree.xmlOutputBufferWrite(self._c_out, len(name), _cstr(name))
*/
if (unlikely(__pyx_v_prefix == Py_None)) {
PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 798; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 807; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_3 = PyBytes_GET_SIZE(__pyx_v_prefix); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 798; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- xmlOutputBufferWrite(__pyx_v_self->_c_out, __pyx_t_3, PyBytes_AS_STRING(__pyx_v_prefix));
+ __pyx_t_2 = PyBytes_GET_SIZE(__pyx_v_prefix); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 807; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, __pyx_t_2, PyBytes_AS_STRING(__pyx_v_prefix));
- /* "src/lxml/serializer.pxi":799
- * if prefix is not None:
+ /* "src/lxml/serializer.pxi":808
+ * if prefix: # empty bytes for no prefix (not None to allow sorting)
* tree.xmlOutputBufferWrite(self._c_out, len(prefix), _cstr(prefix))
* tree.xmlOutputBufferWrite(self._c_out, 1, ':') # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWrite(self._c_out, len(name), _cstr(name))
*
*/
- xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__62);
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__63);
goto __pyx_L3;
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":800
+ /* "src/lxml/serializer.pxi":809
* tree.xmlOutputBufferWrite(self._c_out, len(prefix), _cstr(prefix))
* tree.xmlOutputBufferWrite(self._c_out, 1, ':')
* tree.xmlOutputBufferWrite(self._c_out, len(name), _cstr(name)) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_name == Py_None)) {
PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 809; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_3 = PyBytes_GET_SIZE(__pyx_v_name); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 800; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- xmlOutputBufferWrite(__pyx_v_self->_c_out, __pyx_t_3, PyBytes_AS_STRING(__pyx_v_name));
+ __pyx_t_2 = PyBytes_GET_SIZE(__pyx_v_name); if (unlikely(__pyx_t_2 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 809; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, __pyx_t_2, PyBytes_AS_STRING(__pyx_v_name));
- /* "src/lxml/serializer.pxi":796
+ /* "src/lxml/serializer.pxi":805
* return _FileWriterElement(self, (ns, name, attributes, reversed_nsmap))
*
* cdef _write_qname(self, bytes name, bytes prefix): # <<<<<<<<<<<<<<
- * if prefix is not None:
+ * if prefix: # empty bytes for no prefix (not None to allow sorting)
* tree.xmlOutputBufferWrite(self._c_out, len(prefix), _cstr(prefix))
*/
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":802
+/* "src/lxml/serializer.pxi":811
* tree.xmlOutputBufferWrite(self._c_out, len(name), _cstr(name))
*
* cdef _write_start_element(self, element_config): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_write_start_element", 0);
- /* "src/lxml/serializer.pxi":803
+ /* "src/lxml/serializer.pxi":812
*
* cdef _write_start_element(self, element_config):
* if self._status > WRITER_IN_ELEMENT: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_status > __pyx_e_4lxml_5etree_WRITER_IN_ELEMENT) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":804
+ /* "src/lxml/serializer.pxi":813
* cdef _write_start_element(self, element_config):
* if self._status > WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("cannot append trailing element to complete XML document") # <<<<<<<<<<<<<<
* ns, name, attributes, nsmap = element_config
* flat_namespace_map, new_namespaces = self._collect_namespaces(nsmap)
*/
- __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__63, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__64, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":805
+ /* "src/lxml/serializer.pxi":814
* if self._status > WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("cannot append trailing element to complete XML document")
* ns, name, attributes, nsmap = element_config # <<<<<<<<<<<<<<
if (unlikely(size != 4)) {
if (size > 4) __Pyx_RaiseTooManyValuesError(4);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 805; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 814; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
Py_ssize_t i;
PyObject** temps[4] = {&__pyx_t_3,&__pyx_t_2,&__pyx_t_4,&__pyx_t_5};
for (i=0; i < 4; i++) {
- PyObject* item = PySequence_ITEM(sequence, i); if (unlikely(!item)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 805; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject* item = PySequence_ITEM(sequence, i); if (unlikely(!item)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 814; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(item);
*(temps[i]) = item;
}
} else {
Py_ssize_t index = -1;
PyObject** temps[4] = {&__pyx_t_3,&__pyx_t_2,&__pyx_t_4,&__pyx_t_5};
- __pyx_t_6 = PyObject_GetIter(__pyx_v_element_config); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 805; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyObject_GetIter(__pyx_v_element_config); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 814; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_t_7 = Py_TYPE(__pyx_t_6)->tp_iternext;
for (index=0; index < 4; index++) {
__Pyx_GOTREF(item);
*(temps[index]) = item;
}
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_6), 4) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 805; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_6), 4) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 814; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_7 = NULL;
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
goto __pyx_L5_unpacking_done;
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_t_7 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 805; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 814; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L5_unpacking_done:;
}
__pyx_v_ns = __pyx_t_3;
__pyx_v_nsmap = __pyx_t_5;
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":806
+ /* "src/lxml/serializer.pxi":815
* raise LxmlSyntaxError("cannot append trailing element to complete XML document")
* ns, name, attributes, nsmap = element_config
* flat_namespace_map, new_namespaces = self._collect_namespaces(nsmap) # <<<<<<<<<<<<<<
* prefix = self._find_prefix(ns, flat_namespace_map, new_namespaces)
* tree.xmlOutputBufferWrite(self._c_out, 1, '<')
*/
- if (!(likely(PyDict_CheckExact(__pyx_v_nsmap))||((__pyx_v_nsmap) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_nsmap)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__collect_namespaces(__pyx_v_self, ((PyObject*)__pyx_v_nsmap)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyDict_CheckExact(__pyx_v_nsmap))||((__pyx_v_nsmap) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_nsmap)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__collect_namespaces(__pyx_v_self, ((PyObject*)__pyx_v_nsmap)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
if ((likely(PyTuple_CheckExact(__pyx_t_5))) || (PyList_CheckExact(__pyx_t_5))) {
PyObject* sequence = __pyx_t_5;
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_4);
__Pyx_INCREF(__pyx_t_2);
#else
- __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_2 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
#endif
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_3 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_t_7 = Py_TYPE(__pyx_t_3)->tp_iternext;
__Pyx_GOTREF(__pyx_t_4);
index = 1; __pyx_t_2 = __pyx_t_7(__pyx_t_3); if (unlikely(!__pyx_t_2)) goto __pyx_L6_unpacking_failed;
__Pyx_GOTREF(__pyx_t_2);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_3), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_7(__pyx_t_3), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_7 = NULL;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
goto __pyx_L7_unpacking_done;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_7 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 806; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L7_unpacking_done:;
}
__pyx_v_flat_namespace_map = __pyx_t_4;
__pyx_v_new_namespaces = __pyx_t_2;
__pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":807
+ /* "src/lxml/serializer.pxi":816
* ns, name, attributes, nsmap = element_config
* flat_namespace_map, new_namespaces = self._collect_namespaces(nsmap)
* prefix = self._find_prefix(ns, flat_namespace_map, new_namespaces) # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWrite(self._c_out, 1, '<')
* self._write_qname(name, prefix)
*/
- if (!(likely(PyBytes_CheckExact(__pyx_v_ns))||((__pyx_v_ns) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_ns)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 807; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (!(likely(PyDict_CheckExact(__pyx_v_flat_namespace_map))||((__pyx_v_flat_namespace_map) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_flat_namespace_map)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 807; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (!(likely(PyList_CheckExact(__pyx_v_new_namespaces))||((__pyx_v_new_namespaces) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_new_namespaces)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 807; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__find_prefix(__pyx_v_self, ((PyObject*)__pyx_v_ns), ((PyObject*)__pyx_v_flat_namespace_map), ((PyObject*)__pyx_v_new_namespaces)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 807; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_ns))||((__pyx_v_ns) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_ns)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 816; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyDict_CheckExact(__pyx_v_flat_namespace_map))||((__pyx_v_flat_namespace_map) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_flat_namespace_map)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 816; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyList_CheckExact(__pyx_v_new_namespaces))||((__pyx_v_new_namespaces) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_new_namespaces)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 816; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__find_prefix(__pyx_v_self, ((PyObject*)__pyx_v_ns), ((PyObject*)__pyx_v_flat_namespace_map), ((PyObject*)__pyx_v_new_namespaces)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 816; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_v_prefix = __pyx_t_5;
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":808
+ /* "src/lxml/serializer.pxi":817
* flat_namespace_map, new_namespaces = self._collect_namespaces(nsmap)
* prefix = self._find_prefix(ns, flat_namespace_map, new_namespaces)
* tree.xmlOutputBufferWrite(self._c_out, 1, '<') # <<<<<<<<<<<<<<
* self._write_qname(name, prefix)
*
*/
- xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__64);
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__65);
- /* "src/lxml/serializer.pxi":809
+ /* "src/lxml/serializer.pxi":818
* prefix = self._find_prefix(ns, flat_namespace_map, new_namespaces)
* tree.xmlOutputBufferWrite(self._c_out, 1, '<')
* self._write_qname(name, prefix) # <<<<<<<<<<<<<<
*
* self._write_attributes_and_namespaces(
*/
- if (!(likely(PyBytes_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_name)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 809; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (!(likely(PyBytes_CheckExact(__pyx_v_prefix))||((__pyx_v_prefix) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_prefix)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 809; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_qname(__pyx_v_self, ((PyObject*)__pyx_v_name), ((PyObject*)__pyx_v_prefix)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 809; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_name)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_prefix))||((__pyx_v_prefix) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_prefix)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_qname(__pyx_v_self, ((PyObject*)__pyx_v_name), ((PyObject*)__pyx_v_prefix)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 818; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":812
+ /* "src/lxml/serializer.pxi":821
*
* self._write_attributes_and_namespaces(
* attributes, flat_namespace_map, new_namespaces) # <<<<<<<<<<<<<<
*
* tree.xmlOutputBufferWrite(self._c_out, 1, '>')
*/
- if (!(likely(PyList_CheckExact(__pyx_v_attributes))||((__pyx_v_attributes) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_attributes)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 812; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (!(likely(PyDict_CheckExact(__pyx_v_flat_namespace_map))||((__pyx_v_flat_namespace_map) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_flat_namespace_map)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 812; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (!(likely(PyList_CheckExact(__pyx_v_new_namespaces))||((__pyx_v_new_namespaces) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_new_namespaces)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 812; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyList_CheckExact(__pyx_v_attributes))||((__pyx_v_attributes) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_attributes)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 821; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyDict_CheckExact(__pyx_v_flat_namespace_map))||((__pyx_v_flat_namespace_map) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "dict", Py_TYPE(__pyx_v_flat_namespace_map)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 821; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyList_CheckExact(__pyx_v_new_namespaces))||((__pyx_v_new_namespaces) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "list", Py_TYPE(__pyx_v_new_namespaces)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 821; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/serializer.pxi":811
+ /* "src/lxml/serializer.pxi":820
* self._write_qname(name, prefix)
*
* self._write_attributes_and_namespaces( # <<<<<<<<<<<<<<
* attributes, flat_namespace_map, new_namespaces)
*
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_attributes_and_namespaces(__pyx_v_self, ((PyObject*)__pyx_v_attributes), ((PyObject*)__pyx_v_flat_namespace_map), ((PyObject*)__pyx_v_new_namespaces)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 811; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_attributes_and_namespaces(__pyx_v_self, ((PyObject*)__pyx_v_attributes), ((PyObject*)__pyx_v_flat_namespace_map), ((PyObject*)__pyx_v_new_namespaces)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 820; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":814
+ /* "src/lxml/serializer.pxi":823
* attributes, flat_namespace_map, new_namespaces)
*
* tree.xmlOutputBufferWrite(self._c_out, 1, '>') # <<<<<<<<<<<<<<
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out)
*/
- xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__65);
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__66);
- /* "src/lxml/serializer.pxi":815
+ /* "src/lxml/serializer.pxi":824
*
* tree.xmlOutputBufferWrite(self._c_out, 1, '>')
* if not self._buffered: # <<<<<<<<<<<<<<
__pyx_t_1 = ((!(__pyx_v_self->_buffered != 0)) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":816
+ /* "src/lxml/serializer.pxi":825
* tree.xmlOutputBufferWrite(self._c_out, 1, '>')
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out) # <<<<<<<<<<<<<<
}
__pyx_L8:;
- /* "src/lxml/serializer.pxi":817
+ /* "src/lxml/serializer.pxi":826
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out)
* self._handle_error(self._c_out.error) # <<<<<<<<<<<<<<
*
* self._element_stack.append((ns, name, prefix, flat_namespace_map))
*/
- __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 817; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 826; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":819
+ /* "src/lxml/serializer.pxi":828
* self._handle_error(self._c_out.error)
*
* self._element_stack.append((ns, name, prefix, flat_namespace_map)) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_self->_element_stack == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "append");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 819; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_5 = PyTuple_New(4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 819; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyTuple_New(4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_INCREF(__pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_ns);
__Pyx_INCREF(__pyx_v_flat_namespace_map);
PyTuple_SET_ITEM(__pyx_t_5, 3, __pyx_v_flat_namespace_map);
__Pyx_GIVEREF(__pyx_v_flat_namespace_map);
- __pyx_t_8 = __Pyx_PyList_Append(__pyx_v_self->_element_stack, __pyx_t_5); if (unlikely(__pyx_t_8 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 819; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyList_Append(__pyx_v_self->_element_stack, __pyx_t_5); if (unlikely(__pyx_t_8 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":820
+ /* "src/lxml/serializer.pxi":829
*
* self._element_stack.append((ns, name, prefix, flat_namespace_map))
* self._status = WRITER_IN_ELEMENT # <<<<<<<<<<<<<<
*/
__pyx_v_self->_status = __pyx_e_4lxml_5etree_WRITER_IN_ELEMENT;
- /* "src/lxml/serializer.pxi":802
+ /* "src/lxml/serializer.pxi":811
* tree.xmlOutputBufferWrite(self._c_out, len(name), _cstr(name))
*
* cdef _write_start_element(self, element_config): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":822
+/* "src/lxml/serializer.pxi":831
* self._status = WRITER_IN_ELEMENT
*
* cdef _write_attributes_and_namespaces(self, list attributes, # <<<<<<<<<<<<<<
__Pyx_RefNannySetupContext("_write_attributes_and_namespaces", 0);
__Pyx_INCREF(__pyx_v_attributes);
- /* "src/lxml/serializer.pxi":825
+ /* "src/lxml/serializer.pxi":834
* dict flat_namespace_map,
* list new_namespaces):
* if attributes: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_attributes != Py_None) && (PyList_GET_SIZE(__pyx_v_attributes) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":827
+ /* "src/lxml/serializer.pxi":836
* if attributes:
* # _find_prefix() may append to new_namespaces => build them first
* attributes = [ # <<<<<<<<<<<<<<
* (self._find_prefix(ns, flat_namespace_map, new_namespaces), name, value)
* for ns, name, value in attributes ]
*/
- __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 827; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- /* "src/lxml/serializer.pxi":829
+ /* "src/lxml/serializer.pxi":838
* attributes = [
* (self._find_prefix(ns, flat_namespace_map, new_namespaces), name, value)
* for ns, name, value in attributes ] # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_attributes == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_t_3 = __pyx_v_attributes; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0;
for (;;) {
if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_3)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_5 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_5); __pyx_t_4++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_5); __pyx_t_4++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
if ((likely(PyTuple_CheckExact(__pyx_t_5))) || (PyList_CheckExact(__pyx_t_5))) {
PyObject* sequence = __pyx_t_5;
if (unlikely(size != 3)) {
if (size > 3) __Pyx_RaiseTooManyValuesError(3);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_7);
__Pyx_INCREF(__pyx_t_8);
#else
- __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_7 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
- __pyx_t_8 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
#endif
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_9 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_t_10 = Py_TYPE(__pyx_t_9)->tp_iternext;
__Pyx_GOTREF(__pyx_t_7);
index = 2; __pyx_t_8 = __pyx_t_10(__pyx_t_9); if (unlikely(!__pyx_t_8)) goto __pyx_L6_unpacking_failed;
__Pyx_GOTREF(__pyx_t_8);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_9), 3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_10(__pyx_t_9), 3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_10 = NULL;
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
goto __pyx_L7_unpacking_done;
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
__pyx_t_10 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 829; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L7_unpacking_done:;
}
__Pyx_XDECREF_SET(__pyx_v_ns, __pyx_t_6);
__Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_8);
__pyx_t_8 = 0;
- /* "src/lxml/serializer.pxi":828
+ /* "src/lxml/serializer.pxi":837
* # _find_prefix() may append to new_namespaces => build them first
* attributes = [
* (self._find_prefix(ns, flat_namespace_map, new_namespaces), name, value) # <<<<<<<<<<<<<<
* for ns, name, value in attributes ]
* if new_namespaces:
*/
- if (!(likely(PyBytes_CheckExact(__pyx_v_ns))||((__pyx_v_ns) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_ns)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__find_prefix(__pyx_v_self, ((PyObject*)__pyx_v_ns), __pyx_v_flat_namespace_map, __pyx_v_new_namespaces); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_ns))||((__pyx_v_ns) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_ns)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__find_prefix(__pyx_v_self, ((PyObject*)__pyx_v_ns), __pyx_v_flat_namespace_map, __pyx_v_new_namespaces); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_8 = PyTuple_New(3); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 828; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PyTuple_New(3); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_5);
__Pyx_GIVEREF(__pyx_t_5);
PyTuple_SET_ITEM(__pyx_t_8, 2, __pyx_v_value);
__Pyx_GIVEREF(__pyx_v_value);
__pyx_t_5 = 0;
- if (unlikely(__Pyx_ListComp_Append(__pyx_t_2, (PyObject*)__pyx_t_8))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 827; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_ListComp_Append(__pyx_t_2, (PyObject*)__pyx_t_8))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
- /* "src/lxml/serializer.pxi":829
+ /* "src/lxml/serializer.pxi":838
* attributes = [
* (self._find_prefix(ns, flat_namespace_map, new_namespaces), name, value)
* for ns, name, value in attributes ] # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":830
+ /* "src/lxml/serializer.pxi":839
* (self._find_prefix(ns, flat_namespace_map, new_namespaces), name, value)
* for ns, name, value in attributes ]
* if new_namespaces: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_new_namespaces != Py_None) && (PyList_GET_SIZE(__pyx_v_new_namespaces) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":831
+ /* "src/lxml/serializer.pxi":840
* for ns, name, value in attributes ]
* if new_namespaces:
* new_namespaces.sort() # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_new_namespaces == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "sort");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 831; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_11 = PyList_Sort(__pyx_v_new_namespaces); if (unlikely(__pyx_t_11 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 831; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_11 = PyList_Sort(__pyx_v_new_namespaces); if (unlikely(__pyx_t_11 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/serializer.pxi":832
+ /* "src/lxml/serializer.pxi":841
* if new_namespaces:
* new_namespaces.sort()
* self._write_attributes_list(new_namespaces) # <<<<<<<<<<<<<<
* if attributes:
* self._write_attributes_list(attributes)
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_attributes_list(__pyx_v_self, __pyx_v_new_namespaces); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 832; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_attributes_list(__pyx_v_self, __pyx_v_new_namespaces); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 841; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
goto __pyx_L8;
}
__pyx_L8:;
- /* "src/lxml/serializer.pxi":833
+ /* "src/lxml/serializer.pxi":842
* new_namespaces.sort()
* self._write_attributes_list(new_namespaces)
* if attributes: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_attributes != Py_None) && (PyList_GET_SIZE(__pyx_v_attributes) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":834
+ /* "src/lxml/serializer.pxi":843
* self._write_attributes_list(new_namespaces)
* if attributes:
* self._write_attributes_list(attributes) # <<<<<<<<<<<<<<
*
* cdef _write_attributes_list(self, list attributes):
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_attributes_list(__pyx_v_self, __pyx_v_attributes); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 834; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_attributes_list(__pyx_v_self, __pyx_v_attributes); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 843; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
goto __pyx_L9;
}
__pyx_L9:;
- /* "src/lxml/serializer.pxi":822
+ /* "src/lxml/serializer.pxi":831
* self._status = WRITER_IN_ELEMENT
*
* cdef _write_attributes_and_namespaces(self, list attributes, # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":836
+/* "src/lxml/serializer.pxi":845
* self._write_attributes_list(attributes)
*
* cdef _write_attributes_list(self, list attributes): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_write_attributes_list", 0);
- /* "src/lxml/serializer.pxi":837
+ /* "src/lxml/serializer.pxi":846
*
* cdef _write_attributes_list(self, list attributes):
* for prefix, name, value in attributes: # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_attributes == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_t_1 = __pyx_v_attributes; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0;
for (;;) {
if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
if ((likely(PyTuple_CheckExact(__pyx_t_3))) || (PyList_CheckExact(__pyx_t_3))) {
PyObject* sequence = __pyx_t_3;
if (unlikely(size != 3)) {
if (size > 3) __Pyx_RaiseTooManyValuesError(3);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_5);
__Pyx_INCREF(__pyx_t_6);
#else
- __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
#endif
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_7 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext;
__Pyx_GOTREF(__pyx_t_5);
index = 2; __pyx_t_6 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L5_unpacking_failed;
__Pyx_GOTREF(__pyx_t_6);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 3) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_8 = NULL;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
goto __pyx_L6_unpacking_done;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__pyx_t_8 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L6_unpacking_done:;
}
__Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_4);
__Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":838
+ /* "src/lxml/serializer.pxi":847
* cdef _write_attributes_list(self, list attributes):
* for prefix, name, value in attributes:
* tree.xmlOutputBufferWrite(self._c_out, 1, ' ') # <<<<<<<<<<<<<<
*/
xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__14);
- /* "src/lxml/serializer.pxi":839
+ /* "src/lxml/serializer.pxi":848
* for prefix, name, value in attributes:
* tree.xmlOutputBufferWrite(self._c_out, 1, ' ')
* self._write_qname(name, prefix) # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWrite(self._c_out, 2, '="')
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(value), NULL)
*/
- if (!(likely(PyBytes_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_name)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (!(likely(PyBytes_CheckExact(__pyx_v_prefix))||((__pyx_v_prefix) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_prefix)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_3 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_qname(__pyx_v_self, ((PyObject*)__pyx_v_name), ((PyObject*)__pyx_v_prefix)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_name)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_prefix))||((__pyx_v_prefix) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_prefix)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_qname(__pyx_v_self, ((PyObject*)__pyx_v_name), ((PyObject*)__pyx_v_prefix)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":840
+ /* "src/lxml/serializer.pxi":849
* tree.xmlOutputBufferWrite(self._c_out, 1, ' ')
* self._write_qname(name, prefix)
* tree.xmlOutputBufferWrite(self._c_out, 2, '="') # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(value), NULL)
* tree.xmlOutputBufferWrite(self._c_out, 1, '"')
*/
- xmlOutputBufferWrite(__pyx_v_self->_c_out, 2, __pyx_k__66);
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, 2, __pyx_k__67);
- /* "src/lxml/serializer.pxi":841
+ /* "src/lxml/serializer.pxi":850
* self._write_qname(name, prefix)
* tree.xmlOutputBufferWrite(self._c_out, 2, '="')
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(value), NULL) # <<<<<<<<<<<<<<
*/
xmlOutputBufferWriteEscape(__pyx_v_self->_c_out, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_value), NULL);
- /* "src/lxml/serializer.pxi":842
+ /* "src/lxml/serializer.pxi":851
* tree.xmlOutputBufferWrite(self._c_out, 2, '="')
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(value), NULL)
* tree.xmlOutputBufferWrite(self._c_out, 1, '"') # <<<<<<<<<<<<<<
*
* cdef _write_end_element(self, element_config):
*/
- xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__54);
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__25);
- /* "src/lxml/serializer.pxi":837
+ /* "src/lxml/serializer.pxi":846
*
* cdef _write_attributes_list(self, list attributes):
* for prefix, name, value in attributes: # <<<<<<<<<<<<<<
}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":836
+ /* "src/lxml/serializer.pxi":845
* self._write_attributes_list(attributes)
*
* cdef _write_attributes_list(self, list attributes): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":844
+/* "src/lxml/serializer.pxi":853
* tree.xmlOutputBufferWrite(self._c_out, 1, '"')
*
* cdef _write_end_element(self, element_config): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_write_end_element", 0);
- /* "src/lxml/serializer.pxi":845
+ /* "src/lxml/serializer.pxi":854
*
* cdef _write_end_element(self, element_config):
* if self._status != WRITER_IN_ELEMENT: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_status != __pyx_e_4lxml_5etree_WRITER_IN_ELEMENT) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":846
+ /* "src/lxml/serializer.pxi":855
* cdef _write_end_element(self, element_config):
* if self._status != WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("not in an element") # <<<<<<<<<<<<<<
* if not self._element_stack or self._element_stack[-1][:2] != element_config[:2]:
* raise LxmlSyntaxError("inconsistent exit action in context manager")
*/
- __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__67, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__68, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":847
+ /* "src/lxml/serializer.pxi":856
* if self._status != WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("not in an element")
* if not self._element_stack or self._element_stack[-1][:2] != element_config[:2]: # <<<<<<<<<<<<<<
}
if (unlikely(__pyx_v_self->_element_stack == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_3 = __Pyx_GetItemInt_List(__pyx_v_self->_element_stack, -1, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_3 = __Pyx_GetItemInt_List(__pyx_v_self->_element_stack, -1, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_t_3, 0, 2, NULL, NULL, &__pyx_slice__68, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_GetSlice(__pyx_t_3, 0, 2, NULL, NULL, &__pyx_slice__69, 0, 1, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = __Pyx_PyObject_GetSlice(__pyx_v_element_config, 0, 2, NULL, NULL, &__pyx_slice__69, 0, 1, 1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetSlice(__pyx_v_element_config, 0, 2, NULL, NULL, &__pyx_slice__70, 0, 1, 1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_6 = PyObject_RichCompare(__pyx_t_2, __pyx_t_3, Py_NE); __Pyx_XGOTREF(__pyx_t_6); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyObject_RichCompare(__pyx_t_2, __pyx_t_3, Py_NE); __Pyx_XGOTREF(__pyx_t_6); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_t_1 = __pyx_t_5;
__pyx_L5_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":848
+ /* "src/lxml/serializer.pxi":857
* raise LxmlSyntaxError("not in an element")
* if not self._element_stack or self._element_stack[-1][:2] != element_config[:2]:
* raise LxmlSyntaxError("inconsistent exit action in context manager") # <<<<<<<<<<<<<<
*
* name, prefix = self._element_stack.pop()[1:3]
*/
- __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__70, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__71, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":850
+ /* "src/lxml/serializer.pxi":859
* raise LxmlSyntaxError("inconsistent exit action in context manager")
*
* name, prefix = self._element_stack.pop()[1:3] # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_self->_element_stack == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "pop");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_3 = __Pyx_PyList_Pop(__pyx_v_self->_element_stack); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyList_Pop(__pyx_v_self->_element_stack); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_6 = __Pyx_PyObject_GetSlice(__pyx_t_3, 1, 3, NULL, NULL, &__pyx_slice__71, 1, 1, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_GetSlice(__pyx_t_3, 1, 3, NULL, NULL, &__pyx_slice__72, 1, 1, 1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
if ((likely(PyTuple_CheckExact(__pyx_t_6))) || (PyList_CheckExact(__pyx_t_6))) {
if (unlikely(size != 2)) {
if (size > 2) __Pyx_RaiseTooManyValuesError(2);
else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
#if CYTHON_COMPILING_IN_CPYTHON
if (likely(PyTuple_CheckExact(sequence))) {
__Pyx_INCREF(__pyx_t_3);
__Pyx_INCREF(__pyx_t_2);
#else
- __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_2 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
#endif
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
} else {
Py_ssize_t index = -1;
- __pyx_t_7 = PyObject_GetIter(__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyObject_GetIter(__pyx_t_6); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_t_8 = Py_TYPE(__pyx_t_7)->tp_iternext;
__Pyx_GOTREF(__pyx_t_3);
index = 1; __pyx_t_2 = __pyx_t_8(__pyx_t_7); if (unlikely(!__pyx_t_2)) goto __pyx_L7_unpacking_failed;
__Pyx_GOTREF(__pyx_t_2);
- if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_IternextUnpackEndCheck(__pyx_t_8(__pyx_t_7), 2) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_8 = NULL;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
goto __pyx_L8_unpacking_done;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__pyx_t_8 = NULL;
if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_L8_unpacking_done:;
}
__pyx_v_name = __pyx_t_3;
__pyx_v_prefix = __pyx_t_2;
__pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":851
+ /* "src/lxml/serializer.pxi":860
*
* name, prefix = self._element_stack.pop()[1:3]
* tree.xmlOutputBufferWrite(self._c_out, 2, '</') # <<<<<<<<<<<<<<
* self._write_qname(name, prefix)
* tree.xmlOutputBufferWrite(self._c_out, 1, '>')
*/
- xmlOutputBufferWrite(__pyx_v_self->_c_out, 2, __pyx_k__72);
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, 2, __pyx_k__73);
- /* "src/lxml/serializer.pxi":852
+ /* "src/lxml/serializer.pxi":861
* name, prefix = self._element_stack.pop()[1:3]
* tree.xmlOutputBufferWrite(self._c_out, 2, '</')
* self._write_qname(name, prefix) # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWrite(self._c_out, 1, '>')
*
*/
- if (!(likely(PyBytes_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_name)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 852; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (!(likely(PyBytes_CheckExact(__pyx_v_prefix))||((__pyx_v_prefix) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_prefix)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 852; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_6 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_qname(__pyx_v_self, ((PyObject*)__pyx_v_name), ((PyObject*)__pyx_v_prefix)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 852; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_name))||((__pyx_v_name) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_name)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 861; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(PyBytes_CheckExact(__pyx_v_prefix))||((__pyx_v_prefix) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_v_prefix)->tp_name), 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 861; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_qname(__pyx_v_self, ((PyObject*)__pyx_v_name), ((PyObject*)__pyx_v_prefix)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 861; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":853
+ /* "src/lxml/serializer.pxi":862
* tree.xmlOutputBufferWrite(self._c_out, 2, '</')
* self._write_qname(name, prefix)
* tree.xmlOutputBufferWrite(self._c_out, 1, '>') # <<<<<<<<<<<<<<
*
* if not self._element_stack:
*/
- xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__65);
+ xmlOutputBufferWrite(__pyx_v_self->_c_out, 1, __pyx_k__66);
- /* "src/lxml/serializer.pxi":855
+ /* "src/lxml/serializer.pxi":864
* tree.xmlOutputBufferWrite(self._c_out, 1, '>')
*
* if not self._element_stack: # <<<<<<<<<<<<<<
__pyx_t_5 = ((!__pyx_t_1) != 0);
if (__pyx_t_5) {
- /* "src/lxml/serializer.pxi":856
+ /* "src/lxml/serializer.pxi":865
*
* if not self._element_stack:
* self._status = WRITER_FINISHED # <<<<<<<<<<<<<<
}
__pyx_L9:;
- /* "src/lxml/serializer.pxi":857
+ /* "src/lxml/serializer.pxi":866
* if not self._element_stack:
* self._status = WRITER_FINISHED
* if not self._buffered: # <<<<<<<<<<<<<<
__pyx_t_5 = ((!(__pyx_v_self->_buffered != 0)) != 0);
if (__pyx_t_5) {
- /* "src/lxml/serializer.pxi":858
+ /* "src/lxml/serializer.pxi":867
* self._status = WRITER_FINISHED
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out) # <<<<<<<<<<<<<<
}
__pyx_L10:;
- /* "src/lxml/serializer.pxi":859
+ /* "src/lxml/serializer.pxi":868
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out)
* self._handle_error(self._c_out.error) # <<<<<<<<<<<<<<
*
* cdef _find_prefix(self, bytes href, dict flat_namespaces_map, list new_namespaces):
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":844
+ /* "src/lxml/serializer.pxi":853
* tree.xmlOutputBufferWrite(self._c_out, 1, '"')
*
* cdef _write_end_element(self, element_config): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":861
+/* "src/lxml/serializer.pxi":870
* self._handle_error(self._c_out.error)
*
* cdef _find_prefix(self, bytes href, dict flat_namespaces_map, list new_namespaces): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_find_prefix", 0);
- /* "src/lxml/serializer.pxi":862
+ /* "src/lxml/serializer.pxi":871
*
* cdef _find_prefix(self, bytes href, dict flat_namespaces_map, list new_namespaces):
* if href is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":863
+ /* "src/lxml/serializer.pxi":872
* cdef _find_prefix(self, bytes href, dict flat_namespaces_map, list new_namespaces):
* if href is None:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":864
+ /* "src/lxml/serializer.pxi":873
* if href is None:
* return None
* if href in flat_namespaces_map: # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_flat_namespaces_map == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_2 = (__Pyx_PyDict_Contains(__pyx_v_href, __pyx_v_flat_namespaces_map, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 864; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = (__Pyx_PyDict_Contains(__pyx_v_href, __pyx_v_flat_namespaces_map, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":865
+ /* "src/lxml/serializer.pxi":874
* return None
* if href in flat_namespaces_map:
* return flat_namespaces_map[href] # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
if (unlikely(__pyx_v_flat_namespaces_map == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 865; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 874; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_3 = __Pyx_PyDict_GetItem(__pyx_v_flat_namespaces_map, __pyx_v_href); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 865; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_3 = __Pyx_PyDict_GetItem(__pyx_v_flat_namespaces_map, __pyx_v_href); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 874; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":867
+ /* "src/lxml/serializer.pxi":876
* return flat_namespaces_map[href]
* # need to create a new prefix
* prefixes = flat_namespaces_map.values() # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_flat_namespaces_map == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "values");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 867; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 876; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_3 = __Pyx_PyDict_Values(__pyx_v_flat_namespaces_map); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 867; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyDict_Values(__pyx_v_flat_namespaces_map); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 876; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_prefixes = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":868
+ /* "src/lxml/serializer.pxi":877
* # need to create a new prefix
* prefixes = flat_namespaces_map.values()
* i = 0 # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_int_0);
__pyx_v_i = __pyx_int_0;
- /* "src/lxml/serializer.pxi":869
+ /* "src/lxml/serializer.pxi":878
* prefixes = flat_namespaces_map.values()
* i = 0
* while True: # <<<<<<<<<<<<<<
*/
while (1) {
- /* "src/lxml/serializer.pxi":870
+ /* "src/lxml/serializer.pxi":879
* i = 0
* while True:
* prefix = _utf8('ns%d' % i) # <<<<<<<<<<<<<<
* if prefix not in prefixes:
* new_namespaces.append((b'xmlns', prefix, href))
*/
- __pyx_t_3 = __Pyx_PyString_Format(__pyx_kp_s_ns_d, __pyx_v_i); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 870; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyString_Format(__pyx_kp_s_ns_d, __pyx_v_i); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 879; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 870; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__utf8(__pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 879; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_XDECREF_SET(__pyx_v_prefix, ((PyObject*)__pyx_t_4));
__pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":871
+ /* "src/lxml/serializer.pxi":880
* while True:
* prefix = _utf8('ns%d' % i)
* if prefix not in prefixes: # <<<<<<<<<<<<<<
* new_namespaces.append((b'xmlns', prefix, href))
* flat_namespaces_map[href] = prefix
*/
- __pyx_t_1 = (__Pyx_PySequence_Contains(__pyx_v_prefix, __pyx_v_prefixes, Py_NE)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = (__Pyx_PySequence_Contains(__pyx_v_prefix, __pyx_v_prefixes, Py_NE)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 880; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":872
+ /* "src/lxml/serializer.pxi":881
* prefix = _utf8('ns%d' % i)
* if prefix not in prefixes:
* new_namespaces.append((b'xmlns', prefix, href)) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_new_namespaces == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "append");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 872; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 881; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 872; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 881; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(__pyx_n_b_xmlns);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_n_b_xmlns);
__Pyx_INCREF(__pyx_v_href);
PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_href);
__Pyx_GIVEREF(__pyx_v_href);
- __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_new_namespaces, __pyx_t_4); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 872; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_new_namespaces, __pyx_t_4); if (unlikely(__pyx_t_5 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 881; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/serializer.pxi":873
+ /* "src/lxml/serializer.pxi":882
* if prefix not in prefixes:
* new_namespaces.append((b'xmlns', prefix, href))
* flat_namespaces_map[href] = prefix # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_flat_namespaces_map == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 882; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- if (unlikely(PyDict_SetItem(__pyx_v_flat_namespaces_map, __pyx_v_href, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(PyDict_SetItem(__pyx_v_flat_namespaces_map, __pyx_v_href, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 882; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/serializer.pxi":874
+ /* "src/lxml/serializer.pxi":883
* new_namespaces.append((b'xmlns', prefix, href))
* flat_namespaces_map[href] = prefix
* return prefix # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/serializer.pxi":875
+ /* "src/lxml/serializer.pxi":884
* flat_namespaces_map[href] = prefix
* return prefix
* i += 1 # <<<<<<<<<<<<<<
*
* cdef _collect_namespaces(self, dict nsmap):
*/
- __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_i, __pyx_int_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 875; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_i, __pyx_int_1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 884; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF_SET(__pyx_v_i, __pyx_t_4);
__pyx_t_4 = 0;
}
- /* "src/lxml/serializer.pxi":861
+ /* "src/lxml/serializer.pxi":870
* self._handle_error(self._c_out.error)
*
* cdef _find_prefix(self, bytes href, dict flat_namespaces_map, list new_namespaces): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":877
+/* "src/lxml/serializer.pxi":886
* i += 1
*
* cdef _collect_namespaces(self, dict nsmap): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_collect_namespaces", 0);
- /* "src/lxml/serializer.pxi":878
+ /* "src/lxml/serializer.pxi":887
*
* cdef _collect_namespaces(self, dict nsmap):
* new_namespaces = [] # <<<<<<<<<<<<<<
* flat_namespaces_map = {}
* for ns, prefix in nsmap.iteritems():
*/
- __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 878; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 887; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_new_namespaces = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":879
+ /* "src/lxml/serializer.pxi":888
* cdef _collect_namespaces(self, dict nsmap):
* new_namespaces = []
* flat_namespaces_map = {} # <<<<<<<<<<<<<<
* for ns, prefix in nsmap.iteritems():
* flat_namespaces_map[ns] = prefix
*/
- __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 879; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_flat_namespaces_map = ((PyObject*)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":880
+ /* "src/lxml/serializer.pxi":889
* new_namespaces = []
* flat_namespaces_map = {}
* for ns, prefix in nsmap.iteritems(): # <<<<<<<<<<<<<<
__pyx_t_2 = 0;
if (unlikely(__pyx_v_nsmap == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "iteritems");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 880; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 889; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_5 = __Pyx_dict_iterator(__pyx_v_nsmap, 1, __pyx_n_s_iteritems, (&__pyx_t_3), (&__pyx_t_4)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 880; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_dict_iterator(__pyx_v_nsmap, 1, __pyx_n_s_iteritems, (&__pyx_t_3), (&__pyx_t_4)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 889; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_XDECREF(__pyx_t_1);
__pyx_t_1 = __pyx_t_5;
while (1) {
__pyx_t_7 = __Pyx_dict_iter_next(__pyx_t_1, __pyx_t_3, &__pyx_t_2, &__pyx_t_5, &__pyx_t_6, NULL, __pyx_t_4);
if (unlikely(__pyx_t_7 == 0)) break;
- if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 880; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 889; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_GOTREF(__pyx_t_6);
__Pyx_XDECREF_SET(__pyx_v_ns, __pyx_t_5);
__Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":881
+ /* "src/lxml/serializer.pxi":890
* flat_namespaces_map = {}
* for ns, prefix in nsmap.iteritems():
* flat_namespaces_map[ns] = prefix # <<<<<<<<<<<<<<
* if prefix is None:
- * new_namespaces.append((None, b'xmlns', ns))
+ * # use empty bytes rather than None to allow sorting
*/
- if (unlikely(PyDict_SetItem(__pyx_v_flat_namespaces_map, __pyx_v_ns, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 881; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(PyDict_SetItem(__pyx_v_flat_namespaces_map, __pyx_v_ns, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 890; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/serializer.pxi":882
+ /* "src/lxml/serializer.pxi":891
* for ns, prefix in nsmap.iteritems():
* flat_namespaces_map[ns] = prefix
* if prefix is None: # <<<<<<<<<<<<<<
- * new_namespaces.append((None, b'xmlns', ns))
- * else:
+ * # use empty bytes rather than None to allow sorting
+ * new_namespaces.append((b'', b'xmlns', ns))
*/
__pyx_t_8 = (__pyx_v_prefix == Py_None);
__pyx_t_9 = (__pyx_t_8 != 0);
if (__pyx_t_9) {
- /* "src/lxml/serializer.pxi":883
- * flat_namespaces_map[ns] = prefix
+ /* "src/lxml/serializer.pxi":893
* if prefix is None:
- * new_namespaces.append((None, b'xmlns', ns)) # <<<<<<<<<<<<<<
+ * # use empty bytes rather than None to allow sorting
+ * new_namespaces.append((b'', b'xmlns', ns)) # <<<<<<<<<<<<<<
* else:
* new_namespaces.append((b'xmlns', prefix, ns))
*/
- __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 883; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __Pyx_INCREF(Py_None);
- PyTuple_SET_ITEM(__pyx_t_6, 0, Py_None);
- __Pyx_GIVEREF(Py_None);
+ __Pyx_INCREF(__pyx_kp_b__15);
+ PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_kp_b__15);
+ __Pyx_GIVEREF(__pyx_kp_b__15);
__Pyx_INCREF(__pyx_n_b_xmlns);
PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_n_b_xmlns);
__Pyx_GIVEREF(__pyx_n_b_xmlns);
__Pyx_INCREF(__pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_ns);
__Pyx_GIVEREF(__pyx_v_ns);
- __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_new_namespaces, __pyx_t_6); if (unlikely(__pyx_t_10 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 883; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_new_namespaces, __pyx_t_6); if (unlikely(__pyx_t_10 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
goto __pyx_L5;
}
/*else*/ {
- /* "src/lxml/serializer.pxi":885
- * new_namespaces.append((None, b'xmlns', ns))
+ /* "src/lxml/serializer.pxi":895
+ * new_namespaces.append((b'', b'xmlns', ns))
* else:
* new_namespaces.append((b'xmlns', prefix, ns)) # <<<<<<<<<<<<<<
* # merge in flat namespace map of parent
* if self._element_stack:
*/
- __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 885; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 895; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_INCREF(__pyx_n_b_xmlns);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_n_b_xmlns);
__Pyx_INCREF(__pyx_v_ns);
PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_ns);
__Pyx_GIVEREF(__pyx_v_ns);
- __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_new_namespaces, __pyx_t_6); if (unlikely(__pyx_t_10 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 885; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_new_namespaces, __pyx_t_6); if (unlikely(__pyx_t_10 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 895; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
__pyx_L5:;
}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":887
+ /* "src/lxml/serializer.pxi":897
* new_namespaces.append((b'xmlns', prefix, ns))
* # merge in flat namespace map of parent
* if self._element_stack: # <<<<<<<<<<<<<<
__pyx_t_9 = (__pyx_v_self->_element_stack != Py_None) && (PyList_GET_SIZE(__pyx_v_self->_element_stack) != 0);
if (__pyx_t_9) {
- /* "src/lxml/serializer.pxi":888
+ /* "src/lxml/serializer.pxi":898
* # merge in flat namespace map of parent
* if self._element_stack:
* for ns, prefix in (<dict>self._element_stack[-1][-1]).iteritems(): # <<<<<<<<<<<<<<
__pyx_t_3 = 0;
if (unlikely(__pyx_v_self->_element_stack == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_6 = __Pyx_GetItemInt_List(__pyx_v_self->_element_stack, -1, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(__pyx_t_6 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_6 = __Pyx_GetItemInt_List(__pyx_v_self->_element_stack, -1, long, 1, __Pyx_PyInt_From_long, 1, 1, 1); if (unlikely(__pyx_t_6 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_5 = __Pyx_GetItemInt(__pyx_t_6, -1, long, 1, __Pyx_PyInt_From_long, 0, 1, 1); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_5 = __Pyx_GetItemInt(__pyx_t_6, -1, long, 1, __Pyx_PyInt_From_long, 0, 1, 1); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
if (unlikely(__pyx_t_5 == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "iteritems");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- __pyx_t_6 = __Pyx_dict_iterator(((PyObject*)__pyx_t_5), 1, __pyx_n_s_iteritems, (&__pyx_t_2), (&__pyx_t_4)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_dict_iterator(((PyObject*)__pyx_t_5), 1, __pyx_n_s_iteritems, (&__pyx_t_2), (&__pyx_t_4)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_XDECREF(__pyx_t_1);
while (1) {
__pyx_t_7 = __Pyx_dict_iter_next(__pyx_t_1, __pyx_t_2, &__pyx_t_3, &__pyx_t_6, &__pyx_t_5, NULL, __pyx_t_4);
if (unlikely(__pyx_t_7 == 0)) break;
- if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_7 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_GOTREF(__pyx_t_5);
__Pyx_XDECREF_SET(__pyx_v_ns, __pyx_t_6);
__Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/serializer.pxi":889
+ /* "src/lxml/serializer.pxi":899
* if self._element_stack:
* for ns, prefix in (<dict>self._element_stack[-1][-1]).iteritems():
* if flat_namespaces_map.get(ns) is None: # <<<<<<<<<<<<<<
* # unknown or empty prefix => prefer a 'real' prefix
* flat_namespaces_map[ns] = prefix
*/
- __pyx_t_5 = __Pyx_PyDict_GetItemDefault(__pyx_v_flat_namespaces_map, __pyx_v_ns, Py_None); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 889; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyDict_GetItemDefault(__pyx_v_flat_namespaces_map, __pyx_v_ns, Py_None); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_t_9 = (__pyx_t_5 == Py_None);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_t_8 = (__pyx_t_9 != 0);
if (__pyx_t_8) {
- /* "src/lxml/serializer.pxi":891
+ /* "src/lxml/serializer.pxi":901
* if flat_namespaces_map.get(ns) is None:
* # unknown or empty prefix => prefer a 'real' prefix
* flat_namespaces_map[ns] = prefix # <<<<<<<<<<<<<<
* return flat_namespaces_map, new_namespaces
*
*/
- if (unlikely(PyDict_SetItem(__pyx_v_flat_namespaces_map, __pyx_v_ns, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 891; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(PyDict_SetItem(__pyx_v_flat_namespaces_map, __pyx_v_ns, __pyx_v_prefix) < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L9;
}
__pyx_L9:;
}
__pyx_L6:;
- /* "src/lxml/serializer.pxi":892
+ /* "src/lxml/serializer.pxi":902
* # unknown or empty prefix => prefer a 'real' prefix
* flat_namespaces_map[ns] = prefix
* return flat_namespaces_map, new_namespaces # <<<<<<<<<<<<<<
* def write(self, *args, bint with_tail=True, bint pretty_print=False):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 892; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_INCREF(__pyx_v_flat_namespaces_map);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_flat_namespaces_map);
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/serializer.pxi":877
+ /* "src/lxml/serializer.pxi":886
* i += 1
*
* cdef _collect_namespaces(self, dict nsmap): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":894
+/* "src/lxml/serializer.pxi":904
* return flat_namespaces_map, new_namespaces
*
* def write(self, *args, bint with_tail=True, bint pretty_print=False): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, 0, "write") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 894; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, 0, "write") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) < 0) {
goto __pyx_L5_argtuple_error;
} else {
}
if (values[0]) {
- __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[0]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 894; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_with_tail = __Pyx_PyObject_IsTrue(values[0]); if (unlikely((__pyx_v_with_tail == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_with_tail = ((int)1);
}
if (values[1]) {
- __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[1]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 894; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_pretty_print = __Pyx_PyObject_IsTrue(values[1]); if (unlikely((__pyx_v_pretty_print == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else {
__pyx_v_pretty_print = ((int)0);
}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("write", 0, 0, 0, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 894; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("write", 0, 0, 0, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_DECREF(__pyx_v_args); __pyx_v_args = 0;
__Pyx_AddTraceback("lxml.etree._IncrementalFileWriter.write", __pyx_clineno, __pyx_lineno, __pyx_filename);
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("write", 0);
- /* "src/lxml/serializer.pxi":899
+ /* "src/lxml/serializer.pxi":909
* Write subtrees or strings into the file.
* """
* assert self._c_out is not NULL # <<<<<<<<<<<<<<
if (unlikely(!Py_OptimizeFlag)) {
if (unlikely(!((__pyx_v_self->_c_out != NULL) != 0))) {
PyErr_SetNone(PyExc_AssertionError);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/serializer.pxi":900
+ /* "src/lxml/serializer.pxi":910
* """
* assert self._c_out is not NULL
* for content in args: # <<<<<<<<<<<<<<
for (;;) {
if (__pyx_t_2 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
#if CYTHON_COMPILING_IN_CPYTHON
- __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#else
- __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 910; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
#endif
__Pyx_XDECREF_SET(__pyx_v_content, __pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":901
+ /* "src/lxml/serializer.pxi":911
* assert self._c_out is not NULL
* for content in args:
* if _isString(content): # <<<<<<<<<<<<<<
__pyx_t_4 = (_isString(__pyx_v_content) != 0);
if (__pyx_t_4) {
- /* "src/lxml/serializer.pxi":902
+ /* "src/lxml/serializer.pxi":912
* for content in args:
* if _isString(content):
* if self._status != WRITER_IN_ELEMENT: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_self->_status != __pyx_e_4lxml_5etree_WRITER_IN_ELEMENT) != 0);
if (__pyx_t_4) {
- /* "src/lxml/serializer.pxi":903
+ /* "src/lxml/serializer.pxi":913
* if _isString(content):
* if self._status != WRITER_IN_ELEMENT:
* if self._status > WRITER_IN_ELEMENT or content.strip(): # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_t_5;
goto __pyx_L8_bool_binop_done;
}
- __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_content, __pyx_n_s_strip); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_content, __pyx_n_s_strip); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__pyx_t_7 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_6))) {
}
}
if (__pyx_t_7) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
} else {
- __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallNoArg(__pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_3); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_4 = __pyx_t_5;
__pyx_L8_bool_binop_done:;
if (__pyx_t_4) {
- /* "src/lxml/serializer.pxi":904
+ /* "src/lxml/serializer.pxi":914
* if self._status != WRITER_IN_ELEMENT:
* if self._status > WRITER_IN_ELEMENT or content.strip():
* raise LxmlSyntaxError("not in an element") # <<<<<<<<<<<<<<
* content = _utf8(content)
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(content), NULL)
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__73, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__74, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_Raise(__pyx_t_6, 0, 0, 0);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L6;
}
__pyx_L6:;
- /* "src/lxml/serializer.pxi":905
+ /* "src/lxml/serializer.pxi":915
* if self._status > WRITER_IN_ELEMENT or content.strip():
* raise LxmlSyntaxError("not in an element")
* content = _utf8(content) # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(content), NULL)
* elif iselement(content):
*/
- __pyx_t_6 = __pyx_f_4lxml_5etree__utf8(__pyx_v_content); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 905; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __pyx_f_4lxml_5etree__utf8(__pyx_v_content); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF_SET(__pyx_v_content, __pyx_t_6);
__pyx_t_6 = 0;
- /* "src/lxml/serializer.pxi":906
+ /* "src/lxml/serializer.pxi":916
* raise LxmlSyntaxError("not in an element")
* content = _utf8(content)
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(content), NULL) # <<<<<<<<<<<<<<
goto __pyx_L5;
}
- /* "src/lxml/serializer.pxi":907
+ /* "src/lxml/serializer.pxi":917
* content = _utf8(content)
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(content), NULL)
* elif iselement(content): # <<<<<<<<<<<<<<
* if self._status > WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("cannot append trailing element to complete XML document")
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_iselement); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_iselement); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_7 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_3))) {
}
}
if (!__pyx_t_7) {
- __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_content); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_content); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
} else {
- __pyx_t_8 = PyTuple_New(1+1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PyTuple_New(1+1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_7); __pyx_t_7 = NULL;
__Pyx_INCREF(__pyx_v_content);
PyTuple_SET_ITEM(__pyx_t_8, 0+1, __pyx_v_content);
__Pyx_GIVEREF(__pyx_v_content);
- __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_8, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_8, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_6); if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
if (__pyx_t_4) {
- /* "src/lxml/serializer.pxi":908
+ /* "src/lxml/serializer.pxi":918
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(content), NULL)
* elif iselement(content):
* if self._status > WRITER_IN_ELEMENT: # <<<<<<<<<<<<<<
__pyx_t_4 = ((__pyx_v_self->_status > __pyx_e_4lxml_5etree_WRITER_IN_ELEMENT) != 0);
if (__pyx_t_4) {
- /* "src/lxml/serializer.pxi":909
+ /* "src/lxml/serializer.pxi":919
* elif iselement(content):
* if self._status > WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("cannot append trailing element to complete XML document") # <<<<<<<<<<<<<<
* _writeNodeToBuffer(self._c_out, (<_Element>content)._c_node,
* self._c_encoding, NULL, self._method,
*/
- __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__74, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__75, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":910
+ /* "src/lxml/serializer.pxi":920
* if self._status > WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("cannot append trailing element to complete XML document")
* _writeNodeToBuffer(self._c_out, (<_Element>content)._c_node, # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree__writeNodeToBuffer(__pyx_v_self->_c_out, ((struct LxmlElement *)__pyx_v_content)->_c_node, __pyx_v_self->_c_encoding, NULL, __pyx_v_self->_method, 0, 0, __pyx_v_pretty_print, __pyx_v_with_tail, 0);
- /* "src/lxml/serializer.pxi":913
+ /* "src/lxml/serializer.pxi":923
* self._c_encoding, NULL, self._method,
* False, False, pretty_print, with_tail, False)
* if (<_Element>content)._c_node.type == tree.XML_ELEMENT_NODE: # <<<<<<<<<<<<<<
__pyx_t_4 = ((((struct LxmlElement *)__pyx_v_content)->_c_node->type == XML_ELEMENT_NODE) != 0);
if (__pyx_t_4) {
- /* "src/lxml/serializer.pxi":914
+ /* "src/lxml/serializer.pxi":924
* False, False, pretty_print, with_tail, False)
* if (<_Element>content)._c_node.type == tree.XML_ELEMENT_NODE:
* if not self._element_stack: # <<<<<<<<<<<<<<
__pyx_t_5 = ((!__pyx_t_4) != 0);
if (__pyx_t_5) {
- /* "src/lxml/serializer.pxi":915
+ /* "src/lxml/serializer.pxi":925
* if (<_Element>content)._c_node.type == tree.XML_ELEMENT_NODE:
* if not self._element_stack:
* self._status = WRITER_FINISHED # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":917
+ /* "src/lxml/serializer.pxi":927
* self._status = WRITER_FINISHED
* else:
* raise TypeError("got invalid input value of type %s, expected string or Element" % type(content)) # <<<<<<<<<<<<<<
* self._handle_error(self._c_out.error)
* if not self._buffered:
*/
- __pyx_t_3 = __Pyx_PyString_Format(__pyx_kp_s_got_invalid_input_value_of_type, ((PyObject *)Py_TYPE(__pyx_v_content))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyString_Format(__pyx_kp_s_got_invalid_input_value_of_type, ((PyObject *)Py_TYPE(__pyx_v_content))); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_3);
__Pyx_GIVEREF(__pyx_t_3);
__pyx_t_3 = 0;
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 917; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_L5:;
- /* "src/lxml/serializer.pxi":918
+ /* "src/lxml/serializer.pxi":928
* else:
* raise TypeError("got invalid input value of type %s, expected string or Element" % type(content))
* self._handle_error(self._c_out.error) # <<<<<<<<<<<<<<
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out)
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_self->_c_out->error); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/serializer.pxi":900
+ /* "src/lxml/serializer.pxi":910
* """
* assert self._c_out is not NULL
* for content in args: # <<<<<<<<<<<<<<
}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/serializer.pxi":919
+ /* "src/lxml/serializer.pxi":929
* raise TypeError("got invalid input value of type %s, expected string or Element" % type(content))
* self._handle_error(self._c_out.error)
* if not self._buffered: # <<<<<<<<<<<<<<
__pyx_t_5 = ((!(__pyx_v_self->_buffered != 0)) != 0);
if (__pyx_t_5) {
- /* "src/lxml/serializer.pxi":920
+ /* "src/lxml/serializer.pxi":930
* self._handle_error(self._c_out.error)
* if not self._buffered:
* tree.xmlOutputBufferFlush(self._c_out) # <<<<<<<<<<<<<<
}
__pyx_L13:;
- /* "src/lxml/serializer.pxi":894
+ /* "src/lxml/serializer.pxi":904
* return flat_namespaces_map, new_namespaces
*
* def write(self, *args, bint with_tail=True, bint pretty_print=False): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":922
+/* "src/lxml/serializer.pxi":932
* tree.xmlOutputBufferFlush(self._c_out)
*
* def flush(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("flush", 0);
- /* "src/lxml/serializer.pxi":927
+ /* "src/lxml/serializer.pxi":937
* Write any pending content of the current output buffer to the stream.
* """
* assert self._c_out is not NULL # <<<<<<<<<<<<<<
if (unlikely(!Py_OptimizeFlag)) {
if (unlikely(!((__pyx_v_self->_c_out != NULL) != 0))) {
PyErr_SetNone(PyExc_AssertionError);
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 927; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 937; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/serializer.pxi":928
+ /* "src/lxml/serializer.pxi":938
* """
* assert self._c_out is not NULL
* tree.xmlOutputBufferFlush(self._c_out) # <<<<<<<<<<<<<<
*/
xmlOutputBufferFlush(__pyx_v_self->_c_out);
- /* "src/lxml/serializer.pxi":922
+ /* "src/lxml/serializer.pxi":932
* tree.xmlOutputBufferFlush(self._c_out)
*
* def flush(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":930
+/* "src/lxml/serializer.pxi":940
* tree.xmlOutputBufferFlush(self._c_out)
*
* cdef _close(self, bint raise_on_error): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_close", 0);
- /* "src/lxml/serializer.pxi":931
+ /* "src/lxml/serializer.pxi":941
*
* cdef _close(self, bint raise_on_error):
* if raise_on_error: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_raise_on_error != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":932
+ /* "src/lxml/serializer.pxi":942
* cdef _close(self, bint raise_on_error):
* if raise_on_error:
* if self._status < WRITER_IN_ELEMENT: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_status < __pyx_e_4lxml_5etree_WRITER_IN_ELEMENT) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":933
+ /* "src/lxml/serializer.pxi":943
* if raise_on_error:
* if self._status < WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("no content written") # <<<<<<<<<<<<<<
* if self._element_stack:
* raise LxmlSyntaxError("pending open tags on close")
*/
- __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 933; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 943; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__75, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 933; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__76, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 943; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 933; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 943; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/serializer.pxi":934
+ /* "src/lxml/serializer.pxi":944
* if self._status < WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("no content written")
* if self._element_stack: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_self->_element_stack != Py_None) && (PyList_GET_SIZE(__pyx_v_self->_element_stack) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":935
+ /* "src/lxml/serializer.pxi":945
* raise LxmlSyntaxError("no content written")
* if self._element_stack:
* raise LxmlSyntaxError("pending open tags on close") # <<<<<<<<<<<<<<
* error_result = self._c_out.error
* if error_result == xmlerror.XML_ERR_OK:
*/
- __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 935; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlSyntaxError); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__76, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 935; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__77, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 935; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
goto __pyx_L3;
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":936
+ /* "src/lxml/serializer.pxi":946
* if self._element_stack:
* raise LxmlSyntaxError("pending open tags on close")
* error_result = self._c_out.error # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_self->_c_out->error;
__pyx_v_error_result = __pyx_t_4;
- /* "src/lxml/serializer.pxi":937
+ /* "src/lxml/serializer.pxi":947
* raise LxmlSyntaxError("pending open tags on close")
* error_result = self._c_out.error
* if error_result == xmlerror.XML_ERR_OK: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_error_result == XML_ERR_OK) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":938
+ /* "src/lxml/serializer.pxi":948
* error_result = self._c_out.error
* if error_result == xmlerror.XML_ERR_OK:
* error_result = tree.xmlOutputBufferClose(self._c_out) # <<<<<<<<<<<<<<
*/
__pyx_v_error_result = xmlOutputBufferClose(__pyx_v_self->_c_out);
- /* "src/lxml/serializer.pxi":939
+ /* "src/lxml/serializer.pxi":949
* if error_result == xmlerror.XML_ERR_OK:
* error_result = tree.xmlOutputBufferClose(self._c_out)
* if error_result > 0: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_error_result > 0) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":940
+ /* "src/lxml/serializer.pxi":950
* error_result = tree.xmlOutputBufferClose(self._c_out)
* if error_result > 0:
* error_result = xmlerror.XML_ERR_OK # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/serializer.pxi":942
+ /* "src/lxml/serializer.pxi":952
* error_result = xmlerror.XML_ERR_OK
* else:
* tree.xmlOutputBufferClose(self._c_out) # <<<<<<<<<<<<<<
}
__pyx_L6:;
- /* "src/lxml/serializer.pxi":943
+ /* "src/lxml/serializer.pxi":953
* else:
* tree.xmlOutputBufferClose(self._c_out)
* self._status = WRITER_FINISHED # <<<<<<<<<<<<<<
*/
__pyx_v_self->_status = __pyx_e_4lxml_5etree_WRITER_FINISHED;
- /* "src/lxml/serializer.pxi":944
+ /* "src/lxml/serializer.pxi":954
* tree.xmlOutputBufferClose(self._c_out)
* self._status = WRITER_FINISHED
* self._c_out = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_self->_c_out = NULL;
- /* "src/lxml/serializer.pxi":945
+ /* "src/lxml/serializer.pxi":955
* self._status = WRITER_FINISHED
* self._c_out = NULL
* del self._element_stack[:] # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_self->_element_stack == Py_None)) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 955; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- if (__Pyx_PyObject_DelSlice(__pyx_v_self->_element_stack, 0, 0, NULL, NULL, NULL, 0, 0, 1) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_PyObject_DelSlice(__pyx_v_self->_element_stack, 0, 0, NULL, NULL, NULL, 0, 0, 1) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 955; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/serializer.pxi":946
+ /* "src/lxml/serializer.pxi":956
* self._c_out = NULL
* del self._element_stack[:]
* if raise_on_error: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_v_raise_on_error != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":947
+ /* "src/lxml/serializer.pxi":957
* del self._element_stack[:]
* if raise_on_error:
* self._handle_error(error_result) # <<<<<<<<<<<<<<
*
* cdef _handle_error(self, int error_result):
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_error_result); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 947; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error(__pyx_v_self, __pyx_v_error_result); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 957; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
goto __pyx_L8;
}
__pyx_L8:;
- /* "src/lxml/serializer.pxi":930
+ /* "src/lxml/serializer.pxi":940
* tree.xmlOutputBufferFlush(self._c_out)
*
* cdef _close(self, bint raise_on_error): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":949
+/* "src/lxml/serializer.pxi":959
* self._handle_error(error_result)
*
* cdef _handle_error(self, int error_result): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_handle_error", 0);
- /* "src/lxml/serializer.pxi":950
+ /* "src/lxml/serializer.pxi":960
*
* cdef _handle_error(self, int error_result):
* if error_result != xmlerror.XML_ERR_OK: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_error_result != XML_ERR_OK) != 0);
if (__pyx_t_1) {
- /* "src/lxml/serializer.pxi":951
+ /* "src/lxml/serializer.pxi":961
* cdef _handle_error(self, int error_result):
* if error_result != xmlerror.XML_ERR_OK:
* if self._target is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/serializer.pxi":952
+ /* "src/lxml/serializer.pxi":962
* if error_result != xmlerror.XML_ERR_OK:
* if self._target is not None:
* self._target._exc_context._raise_if_stored() # <<<<<<<<<<<<<<
* _raiseSerialisationError(error_result)
*
*/
- __pyx_t_3 = ((struct __pyx_vtabstruct_4lxml_5etree__ExceptionContext *)__pyx_v_self->_target->_exc_context->__pyx_vtab)->_raise_if_stored(__pyx_v_self->_target->_exc_context); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 952; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((struct __pyx_vtabstruct_4lxml_5etree__ExceptionContext *)__pyx_v_self->_target->_exc_context->__pyx_vtab)->_raise_if_stored(__pyx_v_self->_target->_exc_context); if (unlikely(__pyx_t_3 == -1)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 962; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L4;
}
__pyx_L4:;
- /* "src/lxml/serializer.pxi":953
+ /* "src/lxml/serializer.pxi":963
* if self._target is not None:
* self._target._exc_context._raise_if_stored()
* _raiseSerialisationError(error_result) # <<<<<<<<<<<<<<
*
* @cython.final
*/
- __pyx_t_4 = __pyx_f_4lxml_5etree__raiseSerialisationError(__pyx_v_error_result); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 953; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree__raiseSerialisationError(__pyx_v_error_result); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 963; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
goto __pyx_L3;
}
__pyx_L3:;
- /* "src/lxml/serializer.pxi":949
+ /* "src/lxml/serializer.pxi":959
* self._handle_error(error_result)
*
* cdef _handle_error(self, int error_result): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":962
+/* "src/lxml/serializer.pxi":972
* cdef _IncrementalFileWriter _writer
*
* def __cinit__(self, _IncrementalFileWriter writer not None, element_config): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_element_config)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 2, 2, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 962; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 2, 2, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 972; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 962; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 972; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 962; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 972; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._FileWriterElement.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
return -1;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_writer), __pyx_ptype_4lxml_5etree__IncrementalFileWriter, 0, "writer", 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 962; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_writer), __pyx_ptype_4lxml_5etree__IncrementalFileWriter, 0, "writer", 0))) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 972; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_r = __pyx_pf_4lxml_5etree_18_FileWriterElement___cinit__(((struct __pyx_obj_4lxml_5etree__FileWriterElement *)__pyx_v_self), __pyx_v_writer, __pyx_v_element_config);
/* function exit code */
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/serializer.pxi":963
+ /* "src/lxml/serializer.pxi":973
*
* def __cinit__(self, _IncrementalFileWriter writer not None, element_config):
* self._writer = writer # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_writer));
__pyx_v_self->_writer = __pyx_v_writer;
- /* "src/lxml/serializer.pxi":964
+ /* "src/lxml/serializer.pxi":974
* def __cinit__(self, _IncrementalFileWriter writer not None, element_config):
* self._writer = writer
* self._element = element_config # <<<<<<<<<<<<<<
__Pyx_DECREF(__pyx_v_self->_element);
__pyx_v_self->_element = __pyx_v_element_config;
- /* "src/lxml/serializer.pxi":962
+ /* "src/lxml/serializer.pxi":972
* cdef _IncrementalFileWriter _writer
*
* def __cinit__(self, _IncrementalFileWriter writer not None, element_config): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":966
+/* "src/lxml/serializer.pxi":976
* self._element = element_config
*
* def __enter__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__enter__", 0);
- /* "src/lxml/serializer.pxi":967
+ /* "src/lxml/serializer.pxi":977
*
* def __enter__(self):
* self._writer._write_start_element(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = __pyx_v_self->_element;
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_start_element(__pyx_v_self->_writer, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 967; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_start_element(__pyx_v_self->_writer, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 977; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":966
+ /* "src/lxml/serializer.pxi":976
* self._element = element_config
*
* def __enter__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/serializer.pxi":969
+/* "src/lxml/serializer.pxi":979
* self._writer._write_start_element(self._element)
*
* def __exit__(self, exc_type, exc_val, exc_tb): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_exc_val)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 969; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 1); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 979; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_exc_tb)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 2); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 969; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 2); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 979; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__exit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 969; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__exit__") < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 979; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 969; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[7]; __pyx_lineno = 979; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._FileWriterElement.__exit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__exit__", 0);
- /* "src/lxml/serializer.pxi":970
+ /* "src/lxml/serializer.pxi":980
*
* def __exit__(self, exc_type, exc_val, exc_tb):
* self._writer._write_end_element(self._element) # <<<<<<<<<<<<<<
*/
__pyx_t_1 = __pyx_v_self->_element;
__Pyx_INCREF(__pyx_t_1);
- __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_end_element(__pyx_v_self->_writer, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 970; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_end_element(__pyx_v_self->_writer, __pyx_t_1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 980; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/serializer.pxi":969
+ /* "src/lxml/serializer.pxi":979
* self._writer._write_start_element(self._element)
*
* def __exit__(self, exc_type, exc_val, exc_tb): # <<<<<<<<<<<<<<
{
static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_source,&__pyx_n_s_events,&__pyx_n_s_tag,&__pyx_n_s_attribute_defaults,&__pyx_n_s_dtd_validation,&__pyx_n_s_load_dtd,&__pyx_n_s_no_network,&__pyx_n_s_remove_blank_text,&__pyx_n_s_compact,&__pyx_n_s_resolve_entities,&__pyx_n_s_remove_comments,&__pyx_n_s_remove_pis,&__pyx_n_s_strip_cdata,&__pyx_n_s_encoding,&__pyx_n_s_html,&__pyx_n_s_recover,&__pyx_n_s_huge_tree,&__pyx_n_s_collect_ids,&__pyx_n_s_schema,0};
PyObject* values[19] = {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0};
- values[1] = ((PyObject *)__pyx_tuple__77);
+ values[1] = ((PyObject *)__pyx_tuple__78);
values[2] = ((PyObject *)Py_None);
/* "src/lxml/iterparse.pxi":67
*/
__pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->_source, __pyx_n_s_read); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 218; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__78, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 218; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__79, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 218; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_v_data = __pyx_t_2;
* if not data:
* try:
*/
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__79, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__80, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
{
static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_element_or_tree,&__pyx_n_s_events,&__pyx_n_s_tag,0};
PyObject* values[3] = {0,0,0};
- values[1] = ((PyObject *)__pyx_tuple__80);
+ values[1] = ((PyObject *)__pyx_tuple__81);
values[2] = ((PyObject *)Py_None);
if (unlikely(__pyx_kwds)) {
Py_ssize_t kw_args;
__pyx_t_3 = __pyx_t_5;
goto __pyx_L4_bool_binop_done;
}
- __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_v_tag, __pyx_kp_s__35, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 250; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = (__Pyx_PyString_Equals(__pyx_v_tag, __pyx_kp_s__36, Py_EQ)); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 250; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = __pyx_t_5;
__pyx_L4_bool_binop_done:;
if (__pyx_t_3) {
* node = self._node_stack[self._index][0]
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->_pop_event, __pyx_tuple__81, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 274; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->_pop_event, __pyx_tuple__82, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 274; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
*
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->_pop_event, __pyx_tuple__82, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_v_self->_pop_event, __pyx_tuple__83, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
* for i from 0 <= i < ns_count:
* self._events.append(event)
*/
- __Pyx_INCREF(__pyx_tuple__83);
- __pyx_v_event = __pyx_tuple__83;
+ __Pyx_INCREF(__pyx_tuple__84);
+ __pyx_v_event = __pyx_tuple__84;
/* "src/lxml/iterparse.pxi":331
* if self._event_filter & PARSE_EVENT_FILTER_END_NS:
*
* # ElementTree compatible implementation: parse and look for 'id' attributes
*/
- __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPath)), __pyx_tuple__84, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 15; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPath)), __pyx_tuple__85, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 15; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree__find_id_attributes);
__Pyx_DECREF_SET(__pyx_v_4lxml_5etree__find_id_attributes, __pyx_t_3);
*/
__pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_elem, __pyx_n_s_get); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__85, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__86, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
if (unlikely(PyDict_SetItem(__pyx_v_dic, __pyx_t_3, __pyx_v_elem) < 0)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
* def __iter__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyObject_GetSlice(__pyx_v_self->_keys, 0, 0, NULL, NULL, &__pyx_slice__86, 0, 0, 1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetSlice(__pyx_v_self->_keys, 0, 0, NULL, NULL, &__pyx_slice__87, 0, 0, 1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
* def iteritems(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyObject_GetSlice(__pyx_v_self->_items, 0, 0, NULL, NULL, &__pyx_slice__87, 0, 0, 1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetSlice(__pyx_v_self->_items, 0, 0, NULL, NULL, &__pyx_slice__88, 0, 0, 1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
*/
__pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_name, __pyx_n_s_startswith); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 446; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__88, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 446; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__89, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 446; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 446; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("test (wrapper)", 0);
{
- static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ctxt,&__pyx_n_s_s_4,&__pyx_n_s_rexp,&__pyx_n_s_flags,0};
+ static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ctxt,&__pyx_n_s_s_6,&__pyx_n_s_rexp,&__pyx_n_s_flags,0};
PyObject* values[4] = {0,0,0,0};
values[3] = ((PyObject *)__pyx_kp_u__15);
if (unlikely(__pyx_kwds)) {
if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctxt)) != 0)) kw_args--;
else goto __pyx_L5_argtuple_error;
case 1:
- if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_s_4)) != 0)) kw_args--;
+ if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_s_6)) != 0)) kw_args--;
else {
__Pyx_RaiseArgtupleInvalid("test", 0, 3, 4, 1); {__pyx_filename = __pyx_f[8]; __pyx_lineno = 498; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("match (wrapper)", 0);
{
- static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ctxt,&__pyx_n_s_s_4,&__pyx_n_s_rexp,&__pyx_n_s_flags,0};
+ static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ctxt,&__pyx_n_s_s_6,&__pyx_n_s_rexp,&__pyx_n_s_flags,0};
PyObject* values[4] = {0,0,0,0};
values[3] = ((PyObject *)__pyx_kp_u__15);
if (unlikely(__pyx_kwds)) {
if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctxt)) != 0)) kw_args--;
else goto __pyx_L5_argtuple_error;
case 1:
- if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_s_4)) != 0)) kw_args--;
+ if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_s_6)) != 0)) kw_args--;
else {
__Pyx_RaiseArgtupleInvalid("match", 0, 3, 4, 1); {__pyx_filename = __pyx_f[8]; __pyx_lineno = 507; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_result, __pyx_n_s_groups); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__89, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__90, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_t_5 = NULL;
*/
__pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_Element); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__90, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__91, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_v_root = __pyx_t_3;
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("replace (wrapper)", 0);
{
- static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ctxt,&__pyx_n_s_s_4,&__pyx_n_s_rexp,&__pyx_n_s_flags,&__pyx_n_s_replacement,0};
+ static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ctxt,&__pyx_n_s_s_6,&__pyx_n_s_rexp,&__pyx_n_s_flags,&__pyx_n_s_replacement,0};
PyObject* values[5] = {0,0,0,0,0};
if (unlikely(__pyx_kwds)) {
Py_ssize_t kw_args;
if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctxt)) != 0)) kw_args--;
else goto __pyx_L5_argtuple_error;
case 1:
- if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_s_4)) != 0)) kw_args--;
+ if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_s_6)) != 0)) kw_args--;
else {
__Pyx_RaiseArgtupleInvalid("replace", 1, 5, 5, 1); {__pyx_filename = __pyx_f[8]; __pyx_lineno = 533; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
* namespace = (<bytes>namespace).decode('utf8')
* namespaces[prefix.decode('utf8')] = namespace
*/
- __pyx_t_1 = __Pyx_PyObject_GetSlice(__pyx_v_namespace_def, 1, -1, NULL, NULL, &__pyx_slice__91, 1, 1, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 499; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetSlice(__pyx_v_namespace_def, 1, -1, NULL, NULL, &__pyx_slice__92, 1, 1, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 499; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_XDECREF_SET(__pyx_v_namespace, __pyx_t_1);
__pyx_t_1 = 0;
* # FIXME: this also replaces {namespaces} within strings!
* path_utf = path_utf.replace(namespace_def, prefix_str)
*/
- __pyx_t_1 = PyNumber_Add(__pyx_v_prefix, __pyx_kp_b__62); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 502; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyNumber_Add(__pyx_v_prefix, __pyx_kp_b__63); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 502; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_XDECREF_SET(__pyx_v_prefix_str, ((PyObject*)__pyx_t_1));
__pyx_t_1 = 0;
*/
__pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_path_utf, __pyx_n_s_decode); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 505; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__92, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 505; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__93, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 505; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF_SET(__pyx_v_path, __pyx_t_1);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_2 = PyUnicode_Join(__pyx_kp_u__93, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 254; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyUnicode_Join(__pyx_kp_u__94, __pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 254; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_6) {
- __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__94, NULL);
+ __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__95, NULL);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_10);
* xslt.xsltMaxDepth = max_depth
*
*/
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__95, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 465; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__96, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 465; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_Raise(__pyx_t_2, 0, 0, 0);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
* # and + 1 as array is NULL terminated
* params = <const_char**>python.PyMem_Malloc( # <<<<<<<<<<<<<<
* sizeof(const_char*) * (parameter_count * 2 + 1))
- * try:
+ * if not params:
*/
__pyx_v_params = ((const char **)PyMem_Malloc(((sizeof(const char *)) * ((__pyx_v_parameter_count * 2) + 1))));
/* "src/lxml/xslt.pxi":653
* params = <const_char**>python.PyMem_Malloc(
* sizeof(const_char*) * (parameter_count * 2 + 1))
+ * if not params: # <<<<<<<<<<<<<<
+ * raise MemoryError()
+ * try:
+ */
+ __pyx_t_3 = ((!(__pyx_v_params != 0)) != 0);
+ if (__pyx_t_3) {
+
+ /* "src/lxml/xslt.pxi":654
+ * sizeof(const_char*) * (parameter_count * 2 + 1))
+ * if not params:
+ * raise MemoryError() # <<<<<<<<<<<<<<
+ * try:
+ * i = 0
+ */
+ PyErr_NoMemory(); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+
+ /* "src/lxml/xslt.pxi":655
+ * if not params:
+ * raise MemoryError()
* try: # <<<<<<<<<<<<<<
* i = 0
* for key, value in parameters.iteritems():
__Pyx_XGOTREF(__pyx_t_6);
/*try:*/ {
- /* "src/lxml/xslt.pxi":654
- * sizeof(const_char*) * (parameter_count * 2 + 1))
+ /* "src/lxml/xslt.pxi":656
+ * raise MemoryError()
* try:
* i = 0 # <<<<<<<<<<<<<<
* for key, value in parameters.iteritems():
*/
__pyx_v_i = 0;
- /* "src/lxml/xslt.pxi":655
+ /* "src/lxml/xslt.pxi":657
* try:
* i = 0
* for key, value in parameters.iteritems(): # <<<<<<<<<<<<<<
__pyx_t_2 = 0;
if (unlikely(__pyx_v_parameters == Py_None)) {
PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "iteritems");
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 657; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
}
- __pyx_t_10 = __Pyx_dict_iterator(__pyx_v_parameters, 1, __pyx_n_s_iteritems, (&__pyx_t_8), (&__pyx_t_9)); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_10 = __Pyx_dict_iterator(__pyx_v_parameters, 1, __pyx_n_s_iteritems, (&__pyx_t_8), (&__pyx_t_9)); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 657; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_10);
__Pyx_XDECREF(__pyx_t_7);
__pyx_t_7 = __pyx_t_10;
while (1) {
__pyx_t_12 = __Pyx_dict_iter_next(__pyx_t_7, __pyx_t_8, &__pyx_t_2, &__pyx_t_10, &__pyx_t_11, NULL, __pyx_t_9);
if (unlikely(__pyx_t_12 == 0)) break;
- if (unlikely(__pyx_t_12 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 655; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ if (unlikely(__pyx_t_12 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 657; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_10);
__Pyx_GOTREF(__pyx_t_11);
__Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_10);
__Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_11);
__pyx_t_11 = 0;
- /* "src/lxml/xslt.pxi":656
+ /* "src/lxml/xslt.pxi":658
* i = 0
* for key, value in parameters.iteritems():
* k = _utf8(key) # <<<<<<<<<<<<<<
* if isinstance(value, _XSLTQuotedStringParam):
* v = (<_XSLTQuotedStringParam>value).strval
*/
- __pyx_t_11 = __pyx_f_4lxml_5etree__utf8(__pyx_v_key); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 656; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_11 = __pyx_f_4lxml_5etree__utf8(__pyx_v_key); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 658; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_11);
__Pyx_XDECREF_SET(__pyx_v_k, ((PyObject*)__pyx_t_11));
__pyx_t_11 = 0;
- /* "src/lxml/xslt.pxi":657
+ /* "src/lxml/xslt.pxi":659
* for key, value in parameters.iteritems():
* k = _utf8(key)
* if isinstance(value, _XSLTQuotedStringParam): # <<<<<<<<<<<<<<
__pyx_t_13 = (__pyx_t_3 != 0);
if (__pyx_t_13) {
- /* "src/lxml/xslt.pxi":658
+ /* "src/lxml/xslt.pxi":660
* k = _utf8(key)
* if isinstance(value, _XSLTQuotedStringParam):
* v = (<_XSLTQuotedStringParam>value).strval # <<<<<<<<<<<<<<
__Pyx_XDECREF_SET(__pyx_v_v, ((PyObject*)__pyx_t_11));
__pyx_t_11 = 0;
- /* "src/lxml/xslt.pxi":659
+ /* "src/lxml/xslt.pxi":661
* if isinstance(value, _XSLTQuotedStringParam):
* v = (<_XSLTQuotedStringParam>value).strval
* xslt.xsltQuoteOneUserParam( # <<<<<<<<<<<<<<
* else:
*/
xsltQuoteOneUserParam(__pyx_v_transform_ctxt, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_k), (const xmlChar*)PyBytes_AS_STRING(__pyx_v_v));
- goto __pyx_L14;
+ goto __pyx_L15;
}
/*else*/ {
- /* "src/lxml/xslt.pxi":662
+ /* "src/lxml/xslt.pxi":664
* transform_ctxt, _xcstr(k), _xcstr(v))
* else:
* if isinstance(value, XPath): # <<<<<<<<<<<<<<
__pyx_t_3 = (__pyx_t_13 != 0);
if (__pyx_t_3) {
- /* "src/lxml/xslt.pxi":663
+ /* "src/lxml/xslt.pxi":665
* else:
* if isinstance(value, XPath):
* v = (<XPath>value)._path # <<<<<<<<<<<<<<
__Pyx_INCREF(__pyx_t_11);
__Pyx_XDECREF_SET(__pyx_v_v, ((PyObject*)__pyx_t_11));
__pyx_t_11 = 0;
- goto __pyx_L15;
+ goto __pyx_L16;
}
/*else*/ {
- /* "src/lxml/xslt.pxi":665
+ /* "src/lxml/xslt.pxi":667
* v = (<XPath>value)._path
* else:
* v = _utf8(value) # <<<<<<<<<<<<<<
* params[i] = <const_char*>tree.xmlDictLookup(c_dict, _xcstr(k), len(k))
* i += 1
*/
- __pyx_t_11 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_11 = __pyx_f_4lxml_5etree__utf8(__pyx_v_value); if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 667; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_11);
__Pyx_XDECREF_SET(__pyx_v_v, ((PyObject*)__pyx_t_11));
__pyx_t_11 = 0;
}
- __pyx_L15:;
+ __pyx_L16:;
- /* "src/lxml/xslt.pxi":666
+ /* "src/lxml/xslt.pxi":668
* else:
* v = _utf8(value)
* params[i] = <const_char*>tree.xmlDictLookup(c_dict, _xcstr(k), len(k)) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_k == Py_None)) {
PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 666; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
}
- __pyx_t_14 = PyBytes_GET_SIZE(__pyx_v_k); if (unlikely(__pyx_t_14 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 666; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_14 = PyBytes_GET_SIZE(__pyx_v_k); if (unlikely(__pyx_t_14 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
(__pyx_v_params[__pyx_v_i]) = ((const char *)xmlDictLookup(__pyx_v_c_dict, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_k), __pyx_t_14));
- /* "src/lxml/xslt.pxi":667
+ /* "src/lxml/xslt.pxi":669
* v = _utf8(value)
* params[i] = <const_char*>tree.xmlDictLookup(c_dict, _xcstr(k), len(k))
* i += 1 # <<<<<<<<<<<<<<
*/
__pyx_v_i = (__pyx_v_i + 1);
- /* "src/lxml/xslt.pxi":668
+ /* "src/lxml/xslt.pxi":670
* params[i] = <const_char*>tree.xmlDictLookup(c_dict, _xcstr(k), len(k))
* i += 1
* params[i] = <const_char*>tree.xmlDictLookup(c_dict, _xcstr(v), len(v)) # <<<<<<<<<<<<<<
*/
if (unlikely(__pyx_v_v == Py_None)) {
PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
}
- __pyx_t_14 = PyBytes_GET_SIZE(__pyx_v_v); if (unlikely(__pyx_t_14 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 668; __pyx_clineno = __LINE__; goto __pyx_L4_error;}
+ __pyx_t_14 = PyBytes_GET_SIZE(__pyx_v_v); if (unlikely(__pyx_t_14 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
(__pyx_v_params[__pyx_v_i]) = ((const char *)xmlDictLookup(__pyx_v_c_dict, (const xmlChar*)PyBytes_AS_STRING(__pyx_v_v), __pyx_t_14));
- /* "src/lxml/xslt.pxi":669
+ /* "src/lxml/xslt.pxi":671
* i += 1
* params[i] = <const_char*>tree.xmlDictLookup(c_dict, _xcstr(v), len(v))
* i += 1 # <<<<<<<<<<<<<<
*/
__pyx_v_i = (__pyx_v_i + 1);
}
- __pyx_L14:;
+ __pyx_L15:;
}
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
}
__Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
- goto __pyx_L11_try_end;
- __pyx_L4_error:;
+ goto __pyx_L12_try_end;
+ __pyx_L5_error:;
__Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0;
__Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0;
__Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
- /* "src/lxml/xslt.pxi":670
+ /* "src/lxml/xslt.pxi":672
* params[i] = <const_char*>tree.xmlDictLookup(c_dict, _xcstr(v), len(v))
* i += 1
* except: # <<<<<<<<<<<<<<
*/
/*except:*/ {
__Pyx_AddTraceback("lxml.etree._convert_xslt_parameters", __pyx_clineno, __pyx_lineno, __pyx_filename);
- if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_11, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 670; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_11, &__pyx_t_10) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 672; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
__Pyx_GOTREF(__pyx_t_7);
__Pyx_GOTREF(__pyx_t_11);
__Pyx_GOTREF(__pyx_t_10);
- /* "src/lxml/xslt.pxi":671
+ /* "src/lxml/xslt.pxi":673
* i += 1
* except:
* python.PyMem_Free(params) # <<<<<<<<<<<<<<
*/
PyMem_Free(__pyx_v_params);
- /* "src/lxml/xslt.pxi":672
+ /* "src/lxml/xslt.pxi":674
* except:
* python.PyMem_Free(params)
* raise # <<<<<<<<<<<<<<
__Pyx_XGIVEREF(__pyx_t_10);
__Pyx_ErrRestore(__pyx_t_7, __pyx_t_11, __pyx_t_10);
__pyx_t_7 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0;
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 672; __pyx_clineno = __LINE__; goto __pyx_L6_except_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L7_except_error;}
}
- __pyx_L6_except_error:;
+ __pyx_L7_except_error:;
__Pyx_XGIVEREF(__pyx_t_4);
__Pyx_XGIVEREF(__pyx_t_5);
__Pyx_XGIVEREF(__pyx_t_6);
__Pyx_ExceptionReset(__pyx_t_4, __pyx_t_5, __pyx_t_6);
goto __pyx_L1_error;
- __pyx_L11_try_end:;
+ __pyx_L12_try_end:;
}
- /* "src/lxml/xslt.pxi":673
+ /* "src/lxml/xslt.pxi":675
* python.PyMem_Free(params)
* raise
* params[i] = NULL # <<<<<<<<<<<<<<
*/
(__pyx_v_params[__pyx_v_i]) = NULL;
- /* "src/lxml/xslt.pxi":674
+ /* "src/lxml/xslt.pxi":676
* raise
* params[i] = NULL
* params_ptr[0] = params # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":676
+/* "src/lxml/xslt.pxi":678
* params_ptr[0] = params
*
* cdef XSLT _copyXSLT(XSLT stylesheet): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_copyXSLT", 0);
- /* "src/lxml/xslt.pxi":679
+ /* "src/lxml/xslt.pxi":681
* cdef XSLT new_xslt
* cdef xmlDoc* c_doc
* assert stylesheet._c_style is not NULL, "XSLT stylesheet not initialised" # <<<<<<<<<<<<<<
if (unlikely(!Py_OptimizeFlag)) {
if (unlikely(!((__pyx_v_stylesheet->_c_style != NULL) != 0))) {
PyErr_SetObject(PyExc_AssertionError, __pyx_kp_s_XSLT_stylesheet_not_initialised);
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 679; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 681; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/xslt.pxi":680
+ /* "src/lxml/xslt.pxi":682
* cdef xmlDoc* c_doc
* assert stylesheet._c_style is not NULL, "XSLT stylesheet not initialised"
* new_xslt = XSLT.__new__(XSLT) # <<<<<<<<<<<<<<
* new_xslt._access_control = stylesheet._access_control
* new_xslt._error_log = _ErrorLog()
*/
- __pyx_t_1 = __pyx_tp_new_4lxml_5etree_XSLT(((PyTypeObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XSLT)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 680; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_tp_new_4lxml_5etree_XSLT(((PyTypeObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XSLT)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (!(likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree_XSLT)))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 680; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree_XSLT)))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_new_xslt = ((struct __pyx_obj_4lxml_5etree_XSLT *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/xslt.pxi":681
+ /* "src/lxml/xslt.pxi":683
* assert stylesheet._c_style is not NULL, "XSLT stylesheet not initialised"
* new_xslt = XSLT.__new__(XSLT)
* new_xslt._access_control = stylesheet._access_control # <<<<<<<<<<<<<<
__pyx_v_new_xslt->_access_control = ((struct __pyx_obj_4lxml_5etree_XSLTAccessControl *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/xslt.pxi":682
+ /* "src/lxml/xslt.pxi":684
* new_xslt = XSLT.__new__(XSLT)
* new_xslt._access_control = stylesheet._access_control
* new_xslt._error_log = _ErrorLog() # <<<<<<<<<<<<<<
* new_xslt._context = stylesheet._context._copy()
*
*/
- __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ErrorLog)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 682; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ErrorLog)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 684; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_new_xslt->_error_log);
__pyx_v_new_xslt->_error_log = ((struct __pyx_obj_4lxml_5etree__ErrorLog *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/xslt.pxi":683
+ /* "src/lxml/xslt.pxi":685
* new_xslt._access_control = stylesheet._access_control
* new_xslt._error_log = _ErrorLog()
* new_xslt._context = stylesheet._context._copy() # <<<<<<<<<<<<<<
*
* new_xslt._xslt_resolver_context = stylesheet._xslt_resolver_context._copy()
*/
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree_12_XSLTContext__copy(((struct __pyx_obj_4lxml_5etree__BaseContext *)__pyx_v_stylesheet->_context))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree_12_XSLTContext__copy(((struct __pyx_obj_4lxml_5etree__BaseContext *)__pyx_v_stylesheet->_context))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 685; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__XSLTContext))))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_4lxml_5etree__XSLTContext))))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 685; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_new_xslt->_context);
__Pyx_DECREF(((PyObject *)__pyx_v_new_xslt->_context));
__pyx_v_new_xslt->_context = ((struct __pyx_obj_4lxml_5etree__XSLTContext *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/xslt.pxi":685
+ /* "src/lxml/xslt.pxi":687
* new_xslt._context = stylesheet._context._copy()
*
* new_xslt._xslt_resolver_context = stylesheet._xslt_resolver_context._copy() # <<<<<<<<<<<<<<
* new_xslt._xslt_resolver_context._c_style_doc = _copyDoc(
* stylesheet._xslt_resolver_context._c_style_doc, 1)
*/
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree_20_XSLTResolverContext__copy(__pyx_v_stylesheet->_xslt_resolver_context)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 685; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree_20_XSLTResolverContext__copy(__pyx_v_stylesheet->_xslt_resolver_context)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 687; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_new_xslt->_xslt_resolver_context);
__pyx_v_new_xslt->_xslt_resolver_context = ((struct __pyx_obj_4lxml_5etree__XSLTResolverContext *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/xslt.pxi":686
+ /* "src/lxml/xslt.pxi":688
*
* new_xslt._xslt_resolver_context = stylesheet._xslt_resolver_context._copy()
* new_xslt._xslt_resolver_context._c_style_doc = _copyDoc( # <<<<<<<<<<<<<<
* stylesheet._xslt_resolver_context._c_style_doc, 1)
*
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__copyDoc(__pyx_v_stylesheet->_xslt_resolver_context->_c_style_doc, 1); if (unlikely(__pyx_t_2 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 686; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__copyDoc(__pyx_v_stylesheet->_xslt_resolver_context->_c_style_doc, 1); if (unlikely(__pyx_t_2 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 688; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_new_xslt->_xslt_resolver_context->_c_style_doc = __pyx_t_2;
- /* "src/lxml/xslt.pxi":689
+ /* "src/lxml/xslt.pxi":691
* stylesheet._xslt_resolver_context._c_style_doc, 1)
*
* c_doc = _copyDoc(stylesheet._c_style.doc, 1) # <<<<<<<<<<<<<<
* new_xslt._c_style = xslt.xsltParseStylesheetDoc(c_doc)
* if new_xslt._c_style is NULL:
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree__copyDoc(__pyx_v_stylesheet->_c_style->doc, 1); if (unlikely(__pyx_t_2 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 689; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree__copyDoc(__pyx_v_stylesheet->_c_style->doc, 1); if (unlikely(__pyx_t_2 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 691; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_c_doc = __pyx_t_2;
- /* "src/lxml/xslt.pxi":690
+ /* "src/lxml/xslt.pxi":692
*
* c_doc = _copyDoc(stylesheet._c_style.doc, 1)
* new_xslt._c_style = xslt.xsltParseStylesheetDoc(c_doc) # <<<<<<<<<<<<<<
*/
__pyx_v_new_xslt->_c_style = xsltParseStylesheetDoc(__pyx_v_c_doc);
- /* "src/lxml/xslt.pxi":691
+ /* "src/lxml/xslt.pxi":693
* c_doc = _copyDoc(stylesheet._c_style.doc, 1)
* new_xslt._c_style = xslt.xsltParseStylesheetDoc(c_doc)
* if new_xslt._c_style is NULL: # <<<<<<<<<<<<<<
__pyx_t_3 = ((__pyx_v_new_xslt->_c_style == NULL) != 0);
if (__pyx_t_3) {
- /* "src/lxml/xslt.pxi":692
+ /* "src/lxml/xslt.pxi":694
* new_xslt._c_style = xslt.xsltParseStylesheetDoc(c_doc)
* if new_xslt._c_style is NULL:
* tree.xmlFreeDoc(c_doc) # <<<<<<<<<<<<<<
*/
xmlFreeDoc(__pyx_v_c_doc);
- /* "src/lxml/xslt.pxi":693
+ /* "src/lxml/xslt.pxi":695
* if new_xslt._c_style is NULL:
* tree.xmlFreeDoc(c_doc)
* raise MemoryError() # <<<<<<<<<<<<<<
*
* return new_xslt
*/
- PyErr_NoMemory(); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 693; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyErr_NoMemory(); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 695; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/xslt.pxi":695
+ /* "src/lxml/xslt.pxi":697
* raise MemoryError()
*
* return new_xslt # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_new_xslt;
goto __pyx_L0;
- /* "src/lxml/xslt.pxi":676
+ /* "src/lxml/xslt.pxi":678
* params_ptr[0] = params
*
* cdef XSLT _copyXSLT(XSLT stylesheet): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":704
+/* "src/lxml/xslt.pxi":706
* cdef Py_ssize_t _buffer_len
* cdef Py_ssize_t _buffer_refcnt
* def __cinit__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/xslt.pxi":705
+ /* "src/lxml/xslt.pxi":707
* cdef Py_ssize_t _buffer_refcnt
* def __cinit__(self):
* self._buffer = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_self->_buffer = NULL;
- /* "src/lxml/xslt.pxi":706
+ /* "src/lxml/xslt.pxi":708
* def __cinit__(self):
* self._buffer = NULL
* self._buffer_len = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_buffer_len = 0;
- /* "src/lxml/xslt.pxi":707
+ /* "src/lxml/xslt.pxi":709
* self._buffer = NULL
* self._buffer_len = 0
* self._buffer_refcnt = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_buffer_refcnt = 0;
- /* "src/lxml/xslt.pxi":704
+ /* "src/lxml/xslt.pxi":706
* cdef Py_ssize_t _buffer_len
* cdef Py_ssize_t _buffer_refcnt
* def __cinit__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":709
+/* "src/lxml/xslt.pxi":711
* self._buffer_refcnt = 0
*
* cdef _saveToStringAndSize(self, xmlChar** s, int* l): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_saveToStringAndSize", 0);
- /* "src/lxml/xslt.pxi":712
+ /* "src/lxml/xslt.pxi":714
* cdef _Document doc
* cdef int r
* if self._context_node is not None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":713
+ /* "src/lxml/xslt.pxi":715
* cdef int r
* if self._context_node is not None:
* doc = self._context_node._doc # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/xslt.pxi":715
+ /* "src/lxml/xslt.pxi":717
* doc = self._context_node._doc
* else:
* doc = None # <<<<<<<<<<<<<<
}
__pyx_L3:;
- /* "src/lxml/xslt.pxi":716
+ /* "src/lxml/xslt.pxi":718
* else:
* doc = None
* if doc is None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":717
+ /* "src/lxml/xslt.pxi":719
* doc = None
* if doc is None:
* doc = self._doc # <<<<<<<<<<<<<<
__Pyx_DECREF_SET(__pyx_v_doc, ((struct LxmlDocument *)__pyx_t_3));
__pyx_t_3 = 0;
- /* "src/lxml/xslt.pxi":718
+ /* "src/lxml/xslt.pxi":720
* if doc is None:
* doc = self._doc
* if doc is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":719
+ /* "src/lxml/xslt.pxi":721
* doc = self._doc
* if doc is None:
* s[0] = NULL # <<<<<<<<<<<<<<
*/
(__pyx_v_s[0]) = NULL;
- /* "src/lxml/xslt.pxi":720
+ /* "src/lxml/xslt.pxi":722
* if doc is None:
* s[0] = NULL
* return # <<<<<<<<<<<<<<
}
__pyx_L4:;
- /* "src/lxml/xslt.pxi":721
+ /* "src/lxml/xslt.pxi":723
* s[0] = NULL
* return
* with nogil: # <<<<<<<<<<<<<<
#endif
/*try:*/ {
- /* "src/lxml/xslt.pxi":722
+ /* "src/lxml/xslt.pxi":724
* return
* with nogil:
* r = xslt.xsltSaveResultToString(s, l, doc._c_doc, # <<<<<<<<<<<<<<
__pyx_v_r = xsltSaveResultToString(__pyx_v_s, __pyx_v_l, __pyx_v_doc->_c_doc, __pyx_v_self->_xslt->_c_style);
}
- /* "src/lxml/xslt.pxi":721
+ /* "src/lxml/xslt.pxi":723
* s[0] = NULL
* return
* with nogil: # <<<<<<<<<<<<<<
}
}
- /* "src/lxml/xslt.pxi":724
+ /* "src/lxml/xslt.pxi":726
* r = xslt.xsltSaveResultToString(s, l, doc._c_doc,
* self._xslt._c_style)
* if r == -1: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_r == -1) != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":725
+ /* "src/lxml/xslt.pxi":727
* self._xslt._c_style)
* if r == -1:
* raise MemoryError() # <<<<<<<<<<<<<<
*
* def __str__(self):
*/
- PyErr_NoMemory(); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 725; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyErr_NoMemory(); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 727; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/xslt.pxi":709
+ /* "src/lxml/xslt.pxi":711
* self._buffer_refcnt = 0
*
* cdef _saveToStringAndSize(self, xmlChar** s, int* l): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":727
+/* "src/lxml/xslt.pxi":729
* raise MemoryError()
*
* def __str__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__str__", 0);
- /* "src/lxml/xslt.pxi":728
+ /* "src/lxml/xslt.pxi":730
*
* def __str__(self):
* cdef xmlChar* s = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_s = NULL;
- /* "src/lxml/xslt.pxi":729
+ /* "src/lxml/xslt.pxi":731
* def __str__(self):
* cdef xmlChar* s = NULL
* cdef int l = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_l = 0;
- /* "src/lxml/xslt.pxi":730
+ /* "src/lxml/xslt.pxi":732
* cdef xmlChar* s = NULL
* cdef int l = 0
* if python.IS_PYTHON3: # <<<<<<<<<<<<<<
__pyx_t_1 = (IS_PYTHON3 != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":731
+ /* "src/lxml/xslt.pxi":733
* cdef int l = 0
* if python.IS_PYTHON3:
* return self.__unicode__() # <<<<<<<<<<<<<<
* if s is NULL:
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_unicode_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_unicode_2); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_t_4 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && likely(PyMethod_Check(__pyx_t_3))) {
}
}
if (__pyx_t_4) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
} else {
- __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":732
+ /* "src/lxml/xslt.pxi":734
* if python.IS_PYTHON3:
* return self.__unicode__()
* self._saveToStringAndSize(&s, &l) # <<<<<<<<<<<<<<
* if s is NULL:
* return ''
*/
- __pyx_t_2 = __pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize(__pyx_v_self, (&__pyx_v_s), (&__pyx_v_l)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 732; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize(__pyx_v_self, (&__pyx_v_s), (&__pyx_v_l)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "src/lxml/xslt.pxi":733
+ /* "src/lxml/xslt.pxi":735
* return self.__unicode__()
* self._saveToStringAndSize(&s, &l)
* if s is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_s == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":734
+ /* "src/lxml/xslt.pxi":736
* self._saveToStringAndSize(&s, &l)
* if s is NULL:
* return '' # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":736
+ /* "src/lxml/xslt.pxi":738
* return ''
* # we must not use 'funicode' here as this is not always UTF-8
* try: # <<<<<<<<<<<<<<
*/
/*try:*/ {
- /* "src/lxml/xslt.pxi":737
+ /* "src/lxml/xslt.pxi":739
* # we must not use 'funicode' here as this is not always UTF-8
* try:
* result = <bytes>s[:l] # <<<<<<<<<<<<<<
* finally:
* tree.xmlFree(s)
*/
- __pyx_t_2 = __Pyx_PyBytes_FromStringAndSize(((const char*)__pyx_v_s) + 0, __pyx_v_l - 0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
+ __pyx_t_2 = __Pyx_PyBytes_FromStringAndSize(((const char*)__pyx_v_s) + 0, __pyx_v_l - 0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L6_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_t_3 = __pyx_t_2;
__Pyx_INCREF(__pyx_t_3);
__pyx_t_3 = 0;
}
- /* "src/lxml/xslt.pxi":739
+ /* "src/lxml/xslt.pxi":741
* result = <bytes>s[:l]
* finally:
* tree.xmlFree(s) # <<<<<<<<<<<<<<
__pyx_L7:;
}
- /* "src/lxml/xslt.pxi":740
+ /* "src/lxml/xslt.pxi":742
* finally:
* tree.xmlFree(s)
* return result # <<<<<<<<<<<<<<
__pyx_r = __pyx_v_result;
goto __pyx_L0;
- /* "src/lxml/xslt.pxi":727
+ /* "src/lxml/xslt.pxi":729
* raise MemoryError()
*
* def __str__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":742
+/* "src/lxml/xslt.pxi":744
* return result
*
* def __unicode__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__unicode__", 0);
- /* "src/lxml/xslt.pxi":744
+ /* "src/lxml/xslt.pxi":746
* def __unicode__(self):
* cdef xmlChar* encoding
* cdef xmlChar* s = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_s = NULL;
- /* "src/lxml/xslt.pxi":745
+ /* "src/lxml/xslt.pxi":747
* cdef xmlChar* encoding
* cdef xmlChar* s = NULL
* cdef int l = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_l = 0;
- /* "src/lxml/xslt.pxi":746
+ /* "src/lxml/xslt.pxi":748
* cdef xmlChar* s = NULL
* cdef int l = 0
* self._saveToStringAndSize(&s, &l) # <<<<<<<<<<<<<<
* if s is NULL:
* return u''
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize(__pyx_v_self, (&__pyx_v_s), (&__pyx_v_l)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize(__pyx_v_self, (&__pyx_v_s), (&__pyx_v_l)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/xslt.pxi":747
+ /* "src/lxml/xslt.pxi":749
* cdef int l = 0
* self._saveToStringAndSize(&s, &l)
* if s is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_s == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":748
+ /* "src/lxml/xslt.pxi":750
* self._saveToStringAndSize(&s, &l)
* if s is NULL:
* return u'' # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":749
+ /* "src/lxml/xslt.pxi":751
* if s is NULL:
* return u''
* encoding = self._xslt._c_style.encoding # <<<<<<<<<<<<<<
__pyx_t_3 = __pyx_v_self->_xslt->_c_style->encoding;
__pyx_v_encoding = __pyx_t_3;
- /* "src/lxml/xslt.pxi":750
+ /* "src/lxml/xslt.pxi":752
* return u''
* encoding = self._xslt._c_style.encoding
* try: # <<<<<<<<<<<<<<
*/
/*try:*/ {
- /* "src/lxml/xslt.pxi":751
+ /* "src/lxml/xslt.pxi":753
* encoding = self._xslt._c_style.encoding
* try:
* if encoding is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_encoding == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":752
+ /* "src/lxml/xslt.pxi":754
* try:
* if encoding is NULL:
* result = s[:l].decode('UTF-8') # <<<<<<<<<<<<<<
* else:
* result = s[:l].decode(encoding)
*/
- __pyx_t_1 = __Pyx_decode_c_string(((char *)__pyx_v_s), 0, __pyx_v_l, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 752; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_1 = __Pyx_decode_c_string(((char *)__pyx_v_s), 0, __pyx_v_l, NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 754; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_result = __pyx_t_1;
__pyx_t_1 = 0;
}
/*else*/ {
- /* "src/lxml/xslt.pxi":754
+ /* "src/lxml/xslt.pxi":756
* result = s[:l].decode('UTF-8')
* else:
* result = s[:l].decode(encoding) # <<<<<<<<<<<<<<
* finally:
* tree.xmlFree(s)
*/
- __pyx_t_1 = __Pyx_decode_c_string(((char *)__pyx_v_s), 0, __pyx_v_l, ((char *)__pyx_v_encoding), NULL, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 754; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
+ __pyx_t_1 = __Pyx_decode_c_string(((char *)__pyx_v_s), 0, __pyx_v_l, ((char *)__pyx_v_encoding), NULL, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 756; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_v_result = __pyx_t_1;
__pyx_t_1 = 0;
__pyx_L7:;
}
- /* "src/lxml/xslt.pxi":756
+ /* "src/lxml/xslt.pxi":758
* result = s[:l].decode(encoding)
* finally:
* tree.xmlFree(s) # <<<<<<<<<<<<<<
__pyx_L6:;
}
- /* "src/lxml/xslt.pxi":757
+ /* "src/lxml/xslt.pxi":759
* finally:
* tree.xmlFree(s)
* return _stripEncodingDeclaration(result) # <<<<<<<<<<<<<<
* def __getbuffer__(self, Py_buffer* buffer, int flags):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree__stripEncodingDeclaration(__pyx_v_result); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 757; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__stripEncodingDeclaration(__pyx_v_result); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 759; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/xslt.pxi":742
+ /* "src/lxml/xslt.pxi":744
* return result
*
* def __unicode__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":759
+/* "src/lxml/xslt.pxi":761
* return _stripEncodingDeclaration(result)
*
* def __getbuffer__(self, Py_buffer* buffer, int flags): # <<<<<<<<<<<<<<
__Pyx_GIVEREF(__pyx_v_buffer->obj);
}
- /* "src/lxml/xslt.pxi":760
+ /* "src/lxml/xslt.pxi":762
*
* def __getbuffer__(self, Py_buffer* buffer, int flags):
* cdef int l = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_l = 0;
- /* "src/lxml/xslt.pxi":761
+ /* "src/lxml/xslt.pxi":763
* def __getbuffer__(self, Py_buffer* buffer, int flags):
* cdef int l = 0
* if buffer is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_buffer == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":762
+ /* "src/lxml/xslt.pxi":764
* cdef int l = 0
* if buffer is NULL:
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":763
+ /* "src/lxml/xslt.pxi":765
* if buffer is NULL:
* return
* if self._buffer is NULL or flags & python.PyBUF_WRITABLE: # <<<<<<<<<<<<<<
__pyx_L5_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":764
+ /* "src/lxml/xslt.pxi":766
* return
* if self._buffer is NULL or flags & python.PyBUF_WRITABLE:
* self._saveToStringAndSize(<xmlChar**>&buffer.buf, &l) # <<<<<<<<<<<<<<
* buffer.len = l
* if self._buffer is NULL and not flags & python.PyBUF_WRITABLE:
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize(__pyx_v_self, ((xmlChar **)(&__pyx_v_buffer->buf)), (&__pyx_v_l)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 764; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize(__pyx_v_self, ((xmlChar **)(&__pyx_v_buffer->buf)), (&__pyx_v_l)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 766; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "src/lxml/xslt.pxi":765
+ /* "src/lxml/xslt.pxi":767
* if self._buffer is NULL or flags & python.PyBUF_WRITABLE:
* self._saveToStringAndSize(<xmlChar**>&buffer.buf, &l)
* buffer.len = l # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->len = __pyx_v_l;
- /* "src/lxml/xslt.pxi":766
+ /* "src/lxml/xslt.pxi":768
* self._saveToStringAndSize(<xmlChar**>&buffer.buf, &l)
* buffer.len = l
* if self._buffer is NULL and not flags & python.PyBUF_WRITABLE: # <<<<<<<<<<<<<<
__pyx_L8_bool_binop_done:;
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":767
+ /* "src/lxml/xslt.pxi":769
* buffer.len = l
* if self._buffer is NULL and not flags & python.PyBUF_WRITABLE:
* self._buffer = <xmlChar*>buffer.buf # <<<<<<<<<<<<<<
*/
__pyx_v_self->_buffer = ((xmlChar *)__pyx_v_buffer->buf);
- /* "src/lxml/xslt.pxi":768
+ /* "src/lxml/xslt.pxi":770
* if self._buffer is NULL and not flags & python.PyBUF_WRITABLE:
* self._buffer = <xmlChar*>buffer.buf
* self._buffer_len = l # <<<<<<<<<<<<<<
*/
__pyx_v_self->_buffer_len = __pyx_v_l;
- /* "src/lxml/xslt.pxi":769
+ /* "src/lxml/xslt.pxi":771
* self._buffer = <xmlChar*>buffer.buf
* self._buffer_len = l
* self._buffer_refcnt = 1 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/xslt.pxi":771
+ /* "src/lxml/xslt.pxi":773
* self._buffer_refcnt = 1
* else:
* buffer.buf = self._buffer # <<<<<<<<<<<<<<
__pyx_t_4 = __pyx_v_self->_buffer;
__pyx_v_buffer->buf = __pyx_t_4;
- /* "src/lxml/xslt.pxi":772
+ /* "src/lxml/xslt.pxi":774
* else:
* buffer.buf = self._buffer
* buffer.len = self._buffer_len # <<<<<<<<<<<<<<
__pyx_t_5 = __pyx_v_self->_buffer_len;
__pyx_v_buffer->len = __pyx_t_5;
- /* "src/lxml/xslt.pxi":773
+ /* "src/lxml/xslt.pxi":775
* buffer.buf = self._buffer
* buffer.len = self._buffer_len
* self._buffer_refcnt += 1 # <<<<<<<<<<<<<<
}
__pyx_L4:;
- /* "src/lxml/xslt.pxi":774
+ /* "src/lxml/xslt.pxi":776
* buffer.len = self._buffer_len
* self._buffer_refcnt += 1
* if flags & python.PyBUF_WRITABLE: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_flags & PyBUF_WRITABLE) != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":775
+ /* "src/lxml/xslt.pxi":777
* self._buffer_refcnt += 1
* if flags & python.PyBUF_WRITABLE:
* buffer.readonly = 0 # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/xslt.pxi":777
+ /* "src/lxml/xslt.pxi":779
* buffer.readonly = 0
* else:
* buffer.readonly = 1 # <<<<<<<<<<<<<<
}
__pyx_L10:;
- /* "src/lxml/xslt.pxi":778
+ /* "src/lxml/xslt.pxi":780
* else:
* buffer.readonly = 1
* if flags & python.PyBUF_FORMAT: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_flags & PyBUF_FORMAT) != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":779
+ /* "src/lxml/xslt.pxi":781
* buffer.readonly = 1
* if flags & python.PyBUF_FORMAT:
* buffer.format = "B" # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/xslt.pxi":781
+ /* "src/lxml/xslt.pxi":783
* buffer.format = "B"
* else:
* buffer.format = NULL # <<<<<<<<<<<<<<
}
__pyx_L11:;
- /* "src/lxml/xslt.pxi":782
+ /* "src/lxml/xslt.pxi":784
* else:
* buffer.format = NULL
* buffer.ndim = 0 # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->ndim = 0;
- /* "src/lxml/xslt.pxi":783
+ /* "src/lxml/xslt.pxi":785
* buffer.format = NULL
* buffer.ndim = 0
* buffer.shape = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->shape = NULL;
- /* "src/lxml/xslt.pxi":784
+ /* "src/lxml/xslt.pxi":786
* buffer.ndim = 0
* buffer.shape = NULL
* buffer.strides = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->strides = NULL;
- /* "src/lxml/xslt.pxi":785
+ /* "src/lxml/xslt.pxi":787
* buffer.shape = NULL
* buffer.strides = NULL
* buffer.suboffsets = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->suboffsets = NULL;
- /* "src/lxml/xslt.pxi":786
+ /* "src/lxml/xslt.pxi":788
* buffer.strides = NULL
* buffer.suboffsets = NULL
* buffer.itemsize = 1 # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->itemsize = 1;
- /* "src/lxml/xslt.pxi":787
+ /* "src/lxml/xslt.pxi":789
* buffer.suboffsets = NULL
* buffer.itemsize = 1
* buffer.internal = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->internal = NULL;
- /* "src/lxml/xslt.pxi":788
+ /* "src/lxml/xslt.pxi":790
* buffer.itemsize = 1
* buffer.internal = NULL
* if buffer.obj is not self: # set by Cython? # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":789
+ /* "src/lxml/xslt.pxi":791
* buffer.internal = NULL
* if buffer.obj is not self: # set by Cython?
* buffer.obj = self # <<<<<<<<<<<<<<
}
__pyx_L12:;
- /* "src/lxml/xslt.pxi":759
+ /* "src/lxml/xslt.pxi":761
* return _stripEncodingDeclaration(result)
*
* def __getbuffer__(self, Py_buffer* buffer, int flags): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":791
+/* "src/lxml/xslt.pxi":793
* buffer.obj = self
*
* def __releasebuffer__(self, Py_buffer* buffer): # <<<<<<<<<<<<<<
int __pyx_t_1;
__Pyx_RefNannySetupContext("__releasebuffer__", 0);
- /* "src/lxml/xslt.pxi":792
+ /* "src/lxml/xslt.pxi":794
*
* def __releasebuffer__(self, Py_buffer* buffer):
* if buffer is NULL: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_buffer == NULL) != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":793
+ /* "src/lxml/xslt.pxi":795
* def __releasebuffer__(self, Py_buffer* buffer):
* if buffer is NULL:
* return # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":794
+ /* "src/lxml/xslt.pxi":796
* if buffer is NULL:
* return
* if <xmlChar*>buffer.buf is self._buffer: # <<<<<<<<<<<<<<
__pyx_t_1 = ((((xmlChar *)__pyx_v_buffer->buf) == __pyx_v_self->_buffer) != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":795
+ /* "src/lxml/xslt.pxi":797
* return
* if <xmlChar*>buffer.buf is self._buffer:
* self._buffer_refcnt -= 1 # <<<<<<<<<<<<<<
*/
__pyx_v_self->_buffer_refcnt = (__pyx_v_self->_buffer_refcnt - 1);
- /* "src/lxml/xslt.pxi":796
+ /* "src/lxml/xslt.pxi":798
* if <xmlChar*>buffer.buf is self._buffer:
* self._buffer_refcnt -= 1
* if self._buffer_refcnt == 0: # <<<<<<<<<<<<<<
__pyx_t_1 = ((__pyx_v_self->_buffer_refcnt == 0) != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":797
+ /* "src/lxml/xslt.pxi":799
* self._buffer_refcnt -= 1
* if self._buffer_refcnt == 0:
* tree.xmlFree(<char*>self._buffer) # <<<<<<<<<<<<<<
*/
xmlFree(((char *)__pyx_v_self->_buffer));
- /* "src/lxml/xslt.pxi":798
+ /* "src/lxml/xslt.pxi":800
* if self._buffer_refcnt == 0:
* tree.xmlFree(<char*>self._buffer)
* self._buffer = NULL # <<<<<<<<<<<<<<
}
/*else*/ {
- /* "src/lxml/xslt.pxi":800
+ /* "src/lxml/xslt.pxi":802
* self._buffer = NULL
* else:
* tree.xmlFree(<char*>buffer.buf) # <<<<<<<<<<<<<<
}
__pyx_L4:;
- /* "src/lxml/xslt.pxi":801
+ /* "src/lxml/xslt.pxi":803
* else:
* tree.xmlFree(<char*>buffer.buf)
* buffer.buf = NULL # <<<<<<<<<<<<<<
*/
__pyx_v_buffer->buf = NULL;
- /* "src/lxml/xslt.pxi":791
+ /* "src/lxml/xslt.pxi":793
* buffer.obj = self
*
* def __releasebuffer__(self, Py_buffer* buffer): # <<<<<<<<<<<<<<
__Pyx_RefNannyFinishContext();
}
-/* "src/lxml/xslt.pxi":806
+/* "src/lxml/xslt.pxi":808
* u"""Return an ElementTree with profiling data for the stylesheet run.
* """
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/xslt.pxi":808
+ /* "src/lxml/xslt.pxi":810
* def __get__(self):
* cdef object root
* if self._profile is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":809
+ /* "src/lxml/xslt.pxi":811
* cdef object root
* if self._profile is None:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":810
+ /* "src/lxml/xslt.pxi":812
* if self._profile is None:
* return None
* root = self._profile.getroot() # <<<<<<<<<<<<<<
* if root is None:
* return None
*/
- __pyx_t_3 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_self->_profile); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 810; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree_9_Document_getroot(__pyx_v_self->_profile); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 812; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_v_root = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/xslt.pxi":811
+ /* "src/lxml/xslt.pxi":813
* return None
* root = self._profile.getroot()
* if root is None: # <<<<<<<<<<<<<<
__pyx_t_1 = (__pyx_t_2 != 0);
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":812
+ /* "src/lxml/xslt.pxi":814
* root = self._profile.getroot()
* if root is None:
* return None # <<<<<<<<<<<<<<
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":813
+ /* "src/lxml/xslt.pxi":815
* if root is None:
* return None
* return ElementTree(root) # <<<<<<<<<<<<<<
* def __del__(self):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_ElementTree); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_ElementTree); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_t_5 = NULL;
if (CYTHON_COMPILING_IN_CPYTHON && unlikely(PyMethod_Check(__pyx_t_4))) {
}
}
if (!__pyx_t_5) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_root); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_root); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
} else {
- __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_5); __pyx_t_5 = NULL;
__Pyx_INCREF(__pyx_v_root);
PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_v_root);
__Pyx_GIVEREF(__pyx_v_root);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 815; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
}
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/xslt.pxi":806
+ /* "src/lxml/xslt.pxi":808
* u"""Return an ElementTree with profiling data for the stylesheet run.
* """
* def __get__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":815
+/* "src/lxml/xslt.pxi":817
* return ElementTree(root)
*
* def __del__(self): # <<<<<<<<<<<<<<
__Pyx_RefNannyDeclarations
__Pyx_RefNannySetupContext("__del__", 0);
- /* "src/lxml/xslt.pxi":816
+ /* "src/lxml/xslt.pxi":818
*
* def __del__(self):
* self._profile = None # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_self->_profile));
__pyx_v_self->_profile = ((struct LxmlDocument *)Py_None);
- /* "src/lxml/xslt.pxi":815
+ /* "src/lxml/xslt.pxi":817
* return ElementTree(root)
*
* def __del__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":818
+/* "src/lxml/xslt.pxi":820
* self._profile = None
*
* cdef _xsltResultTreeFactory(_Document doc, XSLT xslt, _Document profile): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_xsltResultTreeFactory", 0);
- /* "src/lxml/xslt.pxi":820
+ /* "src/lxml/xslt.pxi":822
* cdef _xsltResultTreeFactory(_Document doc, XSLT xslt, _Document profile):
* cdef _XSLTResultTree result
* result = <_XSLTResultTree>_newElementTree(doc, None, _XSLTResultTree) # <<<<<<<<<<<<<<
* result._xslt = xslt
* result._profile = profile
*/
- __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__newElementTree(__pyx_v_doc, ((struct LxmlElement *)Py_None), ((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__XSLTResultTree)))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 820; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((PyObject *)__pyx_f_4lxml_5etree__newElementTree(__pyx_v_doc, ((struct LxmlElement *)Py_None), ((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__XSLTResultTree)))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 822; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_t_2 = __pyx_t_1;
__Pyx_INCREF(__pyx_t_2);
__pyx_v_result = ((struct __pyx_obj_4lxml_5etree__XSLTResultTree *)__pyx_t_2);
__pyx_t_2 = 0;
- /* "src/lxml/xslt.pxi":821
+ /* "src/lxml/xslt.pxi":823
* cdef _XSLTResultTree result
* result = <_XSLTResultTree>_newElementTree(doc, None, _XSLTResultTree)
* result._xslt = xslt # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_result->_xslt));
__pyx_v_result->_xslt = __pyx_v_xslt;
- /* "src/lxml/xslt.pxi":822
+ /* "src/lxml/xslt.pxi":824
* result = <_XSLTResultTree>_newElementTree(doc, None, _XSLTResultTree)
* result._xslt = xslt
* result._profile = profile # <<<<<<<<<<<<<<
__Pyx_DECREF(((PyObject *)__pyx_v_result->_profile));
__pyx_v_result->_profile = __pyx_v_profile;
- /* "src/lxml/xslt.pxi":823
+ /* "src/lxml/xslt.pxi":825
* result._xslt = xslt
* result._profile = profile
* return result # <<<<<<<<<<<<<<
__pyx_r = ((PyObject *)__pyx_v_result);
goto __pyx_L0;
- /* "src/lxml/xslt.pxi":818
+ /* "src/lxml/xslt.pxi":820
* self._profile = None
*
* cdef _xsltResultTreeFactory(_Document doc, XSLT xslt, _Document profile): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":841
+/* "src/lxml/xslt.pxi":843
* cdef XPath __findStylesheetByID = None
*
* cdef _findStylesheetByID(_Document doc, id): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_findStylesheetByID", 0);
- /* "src/lxml/xslt.pxi":843
+ /* "src/lxml/xslt.pxi":845
* cdef _findStylesheetByID(_Document doc, id):
* global __findStylesheetByID
* if __findStylesheetByID is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":844
+ /* "src/lxml/xslt.pxi":846
* global __findStylesheetByID
* if __findStylesheetByID is None:
* __findStylesheetByID = XPath( # <<<<<<<<<<<<<<
* u"//xsl:stylesheet[@xml:id = $id]",
* namespaces={u"xsl" : u"http://www.w3.org/1999/XSL/Transform"})
*/
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 844; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- /* "src/lxml/xslt.pxi":846
+ /* "src/lxml/xslt.pxi":848
* __findStylesheetByID = XPath(
* u"//xsl:stylesheet[@xml:id = $id]",
* namespaces={u"xsl" : u"http://www.w3.org/1999/XSL/Transform"}) # <<<<<<<<<<<<<<
* return __findStylesheetByID(doc, id=id)
*
*/
- __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- if (PyDict_SetItem(__pyx_t_4, __pyx_n_u_xsl, __pyx_kp_u_http_www_w3_org_1999_XSL_Transfo) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_namespaces, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 844; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_4, __pyx_n_u_xsl, __pyx_kp_u_http_www_w3_org_1999_XSL_Transfo) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_namespaces, __pyx_t_4) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- /* "src/lxml/xslt.pxi":844
+ /* "src/lxml/xslt.pxi":846
* global __findStylesheetByID
* if __findStylesheetByID is None:
* __findStylesheetByID = XPath( # <<<<<<<<<<<<<<
* u"//xsl:stylesheet[@xml:id = $id]",
* namespaces={u"xsl" : u"http://www.w3.org/1999/XSL/Transform"})
*/
- __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPath)), __pyx_tuple__96, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 844; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPath)), __pyx_tuple__97, __pyx_t_3); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_XGOTREF(((PyObject *)__pyx_v_4lxml_5etree___findStylesheetByID));
}
__pyx_L3:;
- /* "src/lxml/xslt.pxi":847
+ /* "src/lxml/xslt.pxi":849
* u"//xsl:stylesheet[@xml:id = $id]",
* namespaces={u"xsl" : u"http://www.w3.org/1999/XSL/Transform"})
* return __findStylesheetByID(doc, id=id) # <<<<<<<<<<<<<<
* cdef class _XSLTProcessingInstruction(PIBase):
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_INCREF(((PyObject *)__pyx_v_doc));
PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)__pyx_v_doc));
__Pyx_GIVEREF(((PyObject *)__pyx_v_doc));
- __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyDict_New(); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_id, __pyx_v_id) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_4lxml_5etree___findStylesheetByID), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_id, __pyx_v_id) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_v_4lxml_5etree___findStylesheetByID), __pyx_t_4, __pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_t_5 = 0;
goto __pyx_L0;
- /* "src/lxml/xslt.pxi":841
+ /* "src/lxml/xslt.pxi":843
* cdef XPath __findStylesheetByID = None
*
* cdef _findStylesheetByID(_Document doc, id): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":850
+/* "src/lxml/xslt.pxi":852
*
* cdef class _XSLTProcessingInstruction(PIBase):
* def parseXSL(self, parser=None): # <<<<<<<<<<<<<<
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "parseXSL") < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "parseXSL") < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 852; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else {
switch (PyTuple_GET_SIZE(__pyx_args)) {
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("parseXSL", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("parseXSL", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 852; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._XSLTProcessingInstruction.parseXSL", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("parseXSL", 0);
- /* "src/lxml/xslt.pxi":866
+ /* "src/lxml/xslt.pxi":868
* cdef const_xmlChar* c_href
* cdef xmlAttr* c_attr
* _assertValidNode(self) # <<<<<<<<<<<<<<
* if self._c_node.content is NULL:
* raise ValueError, u"PI lacks content"
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 866; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree__assertValidNode(((struct LxmlElement *)__pyx_v_self)); if (unlikely(__pyx_t_1 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/xslt.pxi":867
+ /* "src/lxml/xslt.pxi":869
* cdef xmlAttr* c_attr
* _assertValidNode(self)
* if self._c_node.content is NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._c_node->content == NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":868
+ /* "src/lxml/xslt.pxi":870
* _assertValidNode(self)
* if self._c_node.content is NULL:
* raise ValueError, u"PI lacks content" # <<<<<<<<<<<<<<
* if len(hrefs) != 1:
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_PI_lacks_content, 0, 0);
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 868; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 870; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/xslt.pxi":869
+ /* "src/lxml/xslt.pxi":871
* if self._c_node.content is NULL:
* raise ValueError, u"PI lacks content"
* hrefs = _FIND_PI_HREF(u' ' + (<unsigned char*>self._c_node.content).decode('UTF-8')) # <<<<<<<<<<<<<<
* raise ValueError, u"malformed PI attributes"
*/
__pyx_t_4 = ((unsigned char *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._c_node->content);
- __pyx_t_5 = __Pyx_decode_c_string(((char *)__pyx_t_4), 0, strlen(((char *)__pyx_t_4)), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 869; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_decode_c_string(((char *)__pyx_t_4), 0, strlen(((char *)__pyx_t_4)), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = __Pyx_PyUnicode_ConcatSafe(__pyx_kp_u__14, __pyx_t_5); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 869; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyUnicode_ConcatSafe(__pyx_kp_u__14, __pyx_t_5); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_INCREF(__pyx_v_4lxml_5etree__FIND_PI_HREF);
}
}
if (!__pyx_t_7) {
- __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 869; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_GOTREF(__pyx_t_3);
} else {
- __pyx_t_8 = PyTuple_New(1+1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 869; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PyTuple_New(1+1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_7); __pyx_t_7 = NULL;
PyTuple_SET_ITEM(__pyx_t_8, 0+1, __pyx_t_6);
__Pyx_GIVEREF(__pyx_t_6);
__pyx_t_6 = 0;
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 869; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
}
__pyx_v_hrefs = __pyx_t_3;
__pyx_t_3 = 0;
- /* "src/lxml/xslt.pxi":870
+ /* "src/lxml/xslt.pxi":872
* raise ValueError, u"PI lacks content"
* hrefs = _FIND_PI_HREF(u' ' + (<unsigned char*>self._c_node.content).decode('UTF-8'))
* if len(hrefs) != 1: # <<<<<<<<<<<<<<
* raise ValueError, u"malformed PI attributes"
* hrefs = hrefs[0]
*/
- __pyx_t_9 = PyObject_Length(__pyx_v_hrefs); if (unlikely(__pyx_t_9 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 870; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyObject_Length(__pyx_v_hrefs); if (unlikely(__pyx_t_9 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 872; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_2 = ((__pyx_t_9 != 1) != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":871
+ /* "src/lxml/xslt.pxi":873
* hrefs = _FIND_PI_HREF(u' ' + (<unsigned char*>self._c_node.content).decode('UTF-8'))
* if len(hrefs) != 1:
* raise ValueError, u"malformed PI attributes" # <<<<<<<<<<<<<<
* href_utf = utf8(hrefs[0] or hrefs[1])
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_malformed_PI_attributes, 0, 0);
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/xslt.pxi":872
+ /* "src/lxml/xslt.pxi":874
* if len(hrefs) != 1:
* raise ValueError, u"malformed PI attributes"
* hrefs = hrefs[0] # <<<<<<<<<<<<<<
* href_utf = utf8(hrefs[0] or hrefs[1])
* c_href = _xcstr(href_utf)
*/
- __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_hrefs, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 872; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_hrefs, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_3 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 874; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF_SET(__pyx_v_hrefs, __pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/xslt.pxi":873
+ /* "src/lxml/xslt.pxi":875
* raise ValueError, u"malformed PI attributes"
* hrefs = hrefs[0]
* href_utf = utf8(hrefs[0] or hrefs[1]) # <<<<<<<<<<<<<<
* c_href = _xcstr(href_utf)
*
*/
- __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_hrefs, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_hrefs, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 875; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 875; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (!__pyx_t_2) {
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
} else {
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
goto __pyx_L5_bool_binop_done;
}
- __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_hrefs, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_hrefs, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_5 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 875; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_5);
__Pyx_INCREF(__pyx_t_5);
__pyx_t_3 = __pyx_t_5;
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_L5_bool_binop_done:;
- __pyx_t_5 = utf8(__pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 873; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = utf8(__pyx_t_3); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 875; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_href_utf = ((PyObject*)__pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/xslt.pxi":874
+ /* "src/lxml/xslt.pxi":876
* hrefs = hrefs[0]
* href_utf = utf8(hrefs[0] or hrefs[1])
* c_href = _xcstr(href_utf) # <<<<<<<<<<<<<<
*/
__pyx_v_c_href = (const xmlChar*)PyBytes_AS_STRING(__pyx_v_href_utf);
- /* "src/lxml/xslt.pxi":876
+ /* "src/lxml/xslt.pxi":878
* c_href = _xcstr(href_utf)
*
* if c_href[0] != c'#': # <<<<<<<<<<<<<<
__pyx_t_2 = (((__pyx_v_c_href[0]) != '#') != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":878
+ /* "src/lxml/xslt.pxi":880
* if c_href[0] != c'#':
* # normal URL, try to parse from it
* c_href = tree.xmlBuildURI( # <<<<<<<<<<<<<<
*/
__pyx_v_c_href = xmlBuildURI(__pyx_v_c_href, xmlNodeGetBase(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._c_node->doc, __pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._c_node));
- /* "src/lxml/xslt.pxi":881
+ /* "src/lxml/xslt.pxi":883
* c_href,
* tree.xmlNodeGetBase(self._c_node.doc, self._c_node))
* if c_href is not NULL: # <<<<<<<<<<<<<<
__pyx_t_2 = ((__pyx_v_c_href != NULL) != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":882
+ /* "src/lxml/xslt.pxi":884
* tree.xmlNodeGetBase(self._c_node.doc, self._c_node))
* if c_href is not NULL:
* try: # <<<<<<<<<<<<<<
*/
/*try:*/ {
- /* "src/lxml/xslt.pxi":883
+ /* "src/lxml/xslt.pxi":885
* if c_href is not NULL:
* try:
* href_utf = <unsigned char*>c_href # <<<<<<<<<<<<<<
* finally:
* tree.xmlFree(<char*>c_href)
*/
- __pyx_t_5 = __Pyx_PyBytes_FromUString(((unsigned char *)__pyx_v_c_href)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 883; __pyx_clineno = __LINE__; goto __pyx_L10_error;}
+ __pyx_t_5 = __Pyx_PyBytes_FromUString(((unsigned char *)__pyx_v_c_href)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 885; __pyx_clineno = __LINE__; goto __pyx_L10_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF_SET(__pyx_v_href_utf, ((PyObject*)__pyx_t_5));
__pyx_t_5 = 0;
}
- /* "src/lxml/xslt.pxi":885
+ /* "src/lxml/xslt.pxi":887
* href_utf = <unsigned char*>c_href
* finally:
* tree.xmlFree(<char*>c_href) # <<<<<<<<<<<<<<
}
__pyx_L8:;
- /* "src/lxml/xslt.pxi":886
+ /* "src/lxml/xslt.pxi":888
* finally:
* tree.xmlFree(<char*>c_href)
* result_doc = _parseDocumentFromURL(href_utf, parser) # <<<<<<<<<<<<<<
* return _elementTreeFactory(result_doc, None)
*
*/
- if (!(likely(((__pyx_v_parser) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_parser, __pyx_ptype_4lxml_5etree__BaseParser))))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 886; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocumentFromURL(__pyx_v_href_utf, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_v_parser))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 886; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_v_parser) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_parser, __pyx_ptype_4lxml_5etree__BaseParser))))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__parseDocumentFromURL(__pyx_v_href_utf, ((struct __pyx_obj_4lxml_5etree__BaseParser *)__pyx_v_parser))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 888; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_v_result_doc = ((struct LxmlDocument *)__pyx_t_5);
__pyx_t_5 = 0;
- /* "src/lxml/xslt.pxi":887
+ /* "src/lxml/xslt.pxi":889
* tree.xmlFree(<char*>c_href)
* result_doc = _parseDocumentFromURL(href_utf, parser)
* return _elementTreeFactory(result_doc, None) # <<<<<<<<<<<<<<
* # ID reference to embedded stylesheet
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_result_doc, ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 887; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(__pyx_v_result_doc, ((struct LxmlElement *)Py_None))); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 889; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__pyx_r = __pyx_t_5;
__pyx_t_5 = 0;
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":891
+ /* "src/lxml/xslt.pxi":893
* # ID reference to embedded stylesheet
* # try XML:ID lookup
* _assertValidDoc(self._doc) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_10 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_5)); if (unlikely(__pyx_t_10 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 891; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = __pyx_f_4lxml_5etree__assertValidDoc(((struct LxmlDocument *)__pyx_t_5)); if (unlikely(__pyx_t_10 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- /* "src/lxml/xslt.pxi":892
+ /* "src/lxml/xslt.pxi":894
* # try XML:ID lookup
* _assertValidDoc(self._doc)
* c_href += 1 # skip leading '#' # <<<<<<<<<<<<<<
*/
__pyx_v_c_href = (__pyx_v_c_href + 1);
- /* "src/lxml/xslt.pxi":893
+ /* "src/lxml/xslt.pxi":895
* _assertValidDoc(self._doc)
* c_href += 1 # skip leading '#'
* c_attr = tree.xmlGetID(self._c_node.doc, c_href) # <<<<<<<<<<<<<<
*/
__pyx_v_c_attr = xmlGetID(__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._c_node->doc, __pyx_v_c_href);
- /* "src/lxml/xslt.pxi":894
+ /* "src/lxml/xslt.pxi":896
* c_href += 1 # skip leading '#'
* c_attr = tree.xmlGetID(self._c_node.doc, c_href)
* if c_attr is not NULL and c_attr.doc is self._c_node.doc: # <<<<<<<<<<<<<<
__pyx_L15_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":895
+ /* "src/lxml/xslt.pxi":897
* c_attr = tree.xmlGetID(self._c_node.doc, c_href)
* if c_attr is not NULL and c_attr.doc is self._c_node.doc:
* result_node = _elementFactory(self._doc, c_attr.parent) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_attr->parent)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 895; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementFactory(((struct LxmlDocument *)__pyx_t_5), __pyx_v_c_attr->parent)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 897; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__pyx_v_result_node = ((struct LxmlElement *)__pyx_t_3);
__pyx_t_3 = 0;
- /* "src/lxml/xslt.pxi":896
+ /* "src/lxml/xslt.pxi":898
* if c_attr is not NULL and c_attr.doc is self._c_node.doc:
* result_node = _elementFactory(self._doc, c_attr.parent)
* return _elementTreeFactory(result_node._doc, result_node) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_3 = ((PyObject *)__pyx_v_result_node->_doc);
__Pyx_INCREF(__pyx_t_3);
- __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_3), __pyx_v_result_node)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 896; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_3), __pyx_v_result_node)); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 898; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_r = __pyx_t_5;
goto __pyx_L0;
}
- /* "src/lxml/xslt.pxi":899
+ /* "src/lxml/xslt.pxi":901
*
* # try XPath search
* root = _findStylesheetByID(self._doc, funicode(c_href)) # <<<<<<<<<<<<<<
*/
__pyx_t_5 = ((PyObject *)__pyx_v_self->__pyx_base.__pyx_base.__pyx_base.__pyx_base._doc);
__Pyx_INCREF(__pyx_t_5);
- __pyx_t_3 = __pyx_f_4lxml_5etree_funicode(__pyx_v_c_href); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __pyx_f_4lxml_5etree_funicode(__pyx_v_c_href); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_8 = __pyx_f_4lxml_5etree__findStylesheetByID(((struct LxmlDocument *)__pyx_t_5), __pyx_t_3); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 899; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __pyx_f_4lxml_5etree__findStylesheetByID(((struct LxmlDocument *)__pyx_t_5), __pyx_t_3); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__pyx_v_root = __pyx_t_8;
__pyx_t_8 = 0;
- /* "src/lxml/xslt.pxi":900
+ /* "src/lxml/xslt.pxi":902
* # try XPath search
* root = _findStylesheetByID(self._doc, funicode(c_href))
* if not root: # <<<<<<<<<<<<<<
* raise ValueError, u"reference to non-existing embedded stylesheet"
* elif len(root) > 1:
*/
- __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_root); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 900; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_root); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_18 = ((!__pyx_t_2) != 0);
if (__pyx_t_18) {
- /* "src/lxml/xslt.pxi":901
+ /* "src/lxml/xslt.pxi":903
* root = _findStylesheetByID(self._doc, funicode(c_href))
* if not root:
* raise ValueError, u"reference to non-existing embedded stylesheet" # <<<<<<<<<<<<<<
* raise ValueError, u"ambiguous reference to embedded stylesheet"
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_reference_to_non_existing_embedd, 0, 0);
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 901; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/xslt.pxi":902
+ /* "src/lxml/xslt.pxi":904
* if not root:
* raise ValueError, u"reference to non-existing embedded stylesheet"
* elif len(root) > 1: # <<<<<<<<<<<<<<
* raise ValueError, u"ambiguous reference to embedded stylesheet"
* result_node = root[0]
*/
- __pyx_t_9 = PyObject_Length(__pyx_v_root); if (unlikely(__pyx_t_9 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyObject_Length(__pyx_v_root); if (unlikely(__pyx_t_9 == -1)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_18 = ((__pyx_t_9 > 1) != 0);
if (__pyx_t_18) {
- /* "src/lxml/xslt.pxi":903
+ /* "src/lxml/xslt.pxi":905
* raise ValueError, u"reference to non-existing embedded stylesheet"
* elif len(root) > 1:
* raise ValueError, u"ambiguous reference to embedded stylesheet" # <<<<<<<<<<<<<<
* return _elementTreeFactory(result_node._doc, result_node)
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_ambiguous_reference_to_embedded, 0, 0);
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 903; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 905; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/xslt.pxi":904
+ /* "src/lxml/xslt.pxi":906
* elif len(root) > 1:
* raise ValueError, u"ambiguous reference to embedded stylesheet"
* result_node = root[0] # <<<<<<<<<<<<<<
* return _elementTreeFactory(result_node._doc, result_node)
*
*/
- __pyx_t_8 = __Pyx_GetItemInt(__pyx_v_root, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_8 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_t_8 = __Pyx_GetItemInt(__pyx_v_root, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(__pyx_t_8 == NULL)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 906; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__Pyx_GOTREF(__pyx_t_8);
- if (!(likely(((__pyx_t_8) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_8, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(likely(((__pyx_t_8) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_8, __pyx_ptype_4lxml_5etree__Element))))) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 906; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_result_node = ((struct LxmlElement *)__pyx_t_8);
__pyx_t_8 = 0;
- /* "src/lxml/xslt.pxi":905
+ /* "src/lxml/xslt.pxi":907
* raise ValueError, u"ambiguous reference to embedded stylesheet"
* result_node = root[0]
* return _elementTreeFactory(result_node._doc, result_node) # <<<<<<<<<<<<<<
__Pyx_XDECREF(__pyx_r);
__pyx_t_8 = ((PyObject *)__pyx_v_result_node->_doc);
__Pyx_INCREF(__pyx_t_8);
- __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_8), __pyx_v_result_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 905; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = ((PyObject *)__pyx_f_4lxml_5etree__elementTreeFactory(((struct LxmlDocument *)__pyx_t_8), __pyx_v_result_node)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
goto __pyx_L0;
- /* "src/lxml/xslt.pxi":850
+ /* "src/lxml/xslt.pxi":852
*
* cdef class _XSLTProcessingInstruction(PIBase):
* def parseXSL(self, parser=None): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/xslt.pxi":907
+/* "src/lxml/xslt.pxi":909
* return _elementTreeFactory(result_node._doc, result_node)
*
* def set(self, key, value): # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, 1); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "set") < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
goto __pyx_L5_argtuple_error;
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 907; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("set", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[2]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._XSLTProcessingInstruction.set", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("set", 0);
- /* "src/lxml/xslt.pxi":913
+ /* "src/lxml/xslt.pxi":915
* the processing instruction.
* """
* if key != u"href": # <<<<<<<<<<<<<<
* raise AttributeError, \
* u"only setting the 'href' attribute is supported on XSLT-PIs"
*/
- __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_key, __pyx_n_u_href, Py_NE)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 913; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_key, __pyx_n_u_href, Py_NE)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (__pyx_t_1) {
- /* "src/lxml/xslt.pxi":914
+ /* "src/lxml/xslt.pxi":916
* """
* if key != u"href":
* raise AttributeError, \ # <<<<<<<<<<<<<<
* if value is None:
*/
__Pyx_Raise(__pyx_builtin_AttributeError, __pyx_kp_u_only_setting_the_href_attribute, 0, 0);
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 916; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/xslt.pxi":916
+ /* "src/lxml/xslt.pxi":918
* raise AttributeError, \
* u"only setting the 'href' attribute is supported on XSLT-PIs"
* if value is None: # <<<<<<<<<<<<<<
__pyx_t_2 = (__pyx_t_1 != 0);
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":917
+ /* "src/lxml/xslt.pxi":919
* u"only setting the 'href' attribute is supported on XSLT-PIs"
* if value is None:
* attrib = u"" # <<<<<<<<<<<<<<
goto __pyx_L4;
}
- /* "src/lxml/xslt.pxi":918
+ /* "src/lxml/xslt.pxi":920
* if value is None:
* attrib = u""
* elif u'"' in value or u'>' in value: # <<<<<<<<<<<<<<
* raise ValueError, u"Invalid URL, must not contain '\"' or '>'"
* else:
*/
- __pyx_t_1 = (__Pyx_PySequence_Contains(__pyx_kp_u__54, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = (__Pyx_PySequence_Contains(__pyx_kp_u__25, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 920; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = (__pyx_t_1 != 0);
if (!__pyx_t_3) {
} else {
__pyx_t_2 = __pyx_t_3;
goto __pyx_L5_bool_binop_done;
}
- __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_kp_u__65, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = (__Pyx_PySequence_Contains(__pyx_kp_u__66, __pyx_v_value, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 920; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_1 = (__pyx_t_3 != 0);
__pyx_t_2 = __pyx_t_1;
__pyx_L5_bool_binop_done:;
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":919
+ /* "src/lxml/xslt.pxi":921
* attrib = u""
* elif u'"' in value or u'>' in value:
* raise ValueError, u"Invalid URL, must not contain '\"' or '>'" # <<<<<<<<<<<<<<
* attrib = u' href="%s"' % value
*/
__Pyx_Raise(__pyx_builtin_ValueError, __pyx_kp_u_Invalid_URL_must_not_contain_or, 0, 0);
- {__pyx_filename = __pyx_f[2]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[2]; __pyx_lineno = 921; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
/*else*/ {
- /* "src/lxml/xslt.pxi":921
+ /* "src/lxml/xslt.pxi":923
* raise ValueError, u"Invalid URL, must not contain '\"' or '>'"
* else:
* attrib = u' href="%s"' % value # <<<<<<<<<<<<<<
* text = u' ' + self.text
* if _FIND_PI_HREF(text):
*/
- __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_href_s, __pyx_v_value); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 921; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_href_s, __pyx_v_value); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__pyx_v_attrib = ((PyObject*)__pyx_t_4);
__pyx_t_4 = 0;
}
__pyx_L4:;
- /* "src/lxml/xslt.pxi":922
+ /* "src/lxml/xslt.pxi":924
* else:
* attrib = u' href="%s"' % value
* text = u' ' + self.text # <<<<<<<<<<<<<<
* if _FIND_PI_HREF(text):
* self.text = _REPLACE_PI_HREF(attrib, text)
*/
- __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 922; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyNumber_Add(__pyx_kp_u__14, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 922; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyNumber_Add(__pyx_kp_u__14, __pyx_t_4); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
__pyx_v_text = __pyx_t_5;
__pyx_t_5 = 0;
- /* "src/lxml/xslt.pxi":923
+ /* "src/lxml/xslt.pxi":925
* attrib = u' href="%s"' % value
* text = u' ' + self.text
* if _FIND_PI_HREF(text): # <<<<<<<<<<<<<<
}
}
if (!__pyx_t_6) {
- __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_text); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_v_text); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
} else {
- __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_6); __Pyx_GIVEREF(__pyx_t_6); __pyx_t_6 = NULL;
__Pyx_INCREF(__pyx_v_text);
PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_v_text);
__Pyx_GIVEREF(__pyx_v_text);
- __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 923; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_2 < 0)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
if (__pyx_t_2) {
- /* "src/lxml/xslt.pxi":924
+ /* "src/lxml/xslt.pxi":926
* text = u' ' + self.text
* if _FIND_PI_HREF(text):
* self.text = _REPLACE_PI_HREF(attrib, text) # <<<<<<<<<<<<<<
__pyx_t_8 = 1;
}
}
- __pyx_t_6 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyTuple_New(2+__pyx_t_8); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 926; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
if (__pyx_t_7) {
PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_7); __pyx_t_7 = NULL;
__Pyx_INCREF(__pyx_v_text);
PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_8, __pyx_v_text);
__Pyx_GIVEREF(__pyx_v_text);
- __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 926; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text, __pyx_t_5) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text, __pyx_t_5) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 926; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
goto __pyx_L7;
}
/*else*/ {
- /* "src/lxml/xslt.pxi":926
+ /* "src/lxml/xslt.pxi":928
* self.text = _REPLACE_PI_HREF(attrib, text)
* else:
* self.text = text + attrib # <<<<<<<<<<<<<<
*/
- __pyx_t_5 = PyNumber_Add(__pyx_v_text, __pyx_v_attrib); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 926; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyNumber_Add(__pyx_v_text, __pyx_v_attrib); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text, __pyx_t_5) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 926; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_PyObject_SetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_text, __pyx_t_5) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 928; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
}
__pyx_L7:;
- /* "src/lxml/xslt.pxi":907
+ /* "src/lxml/xslt.pxi":909
* return _elementTreeFactory(result_node._doc, result_node)
*
* def set(self, key, value): # <<<<<<<<<<<<<<
__pyx_t_26 = __Pyx_PyObject_GetAttrStr(__pyx_t_25, __pyx_n_s_encode); if (unlikely(!__pyx_t_26)) {__pyx_filename = __pyx_f[19]; __pyx_lineno = 225; __pyx_clineno = __LINE__; goto __pyx_L42_except_error;}
__Pyx_GOTREF(__pyx_t_26);
__Pyx_DECREF(__pyx_t_25); __pyx_t_25 = 0;
- __pyx_t_25 = __Pyx_PyObject_Call(__pyx_t_26, __pyx_tuple__97, NULL); if (unlikely(!__pyx_t_25)) {__pyx_filename = __pyx_f[19]; __pyx_lineno = 225; __pyx_clineno = __LINE__; goto __pyx_L42_except_error;}
+ __pyx_t_25 = __Pyx_PyObject_Call(__pyx_t_26, __pyx_tuple__98, NULL); if (unlikely(!__pyx_t_25)) {__pyx_filename = __pyx_f[19]; __pyx_lineno = 225; __pyx_clineno = __LINE__; goto __pyx_L42_except_error;}
__Pyx_GOTREF(__pyx_t_25);
__Pyx_DECREF(__pyx_t_26); __pyx_t_26 = 0;
__Pyx_DECREF_SET(__pyx_v_e, __pyx_t_25);
#endif
}
-/* "src/lxml/lxml.etree.pyx":3347
+/* "src/lxml/lxml.etree.pyx":3356
* u"Base class for XML validators."
* cdef _ErrorLog _error_log
* def __cinit__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__cinit__", 0);
- /* "src/lxml/lxml.etree.pyx":3348
+ /* "src/lxml/lxml.etree.pyx":3357
* cdef _ErrorLog _error_log
* def __cinit__(self):
* self._error_log = _ErrorLog() # <<<<<<<<<<<<<<
*
* def validate(self, etree):
*/
- __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ErrorLog)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3348; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__ErrorLog)), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3357; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__Pyx_GOTREF(__pyx_v_self->_error_log);
__pyx_v_self->_error_log = ((struct __pyx_obj_4lxml_5etree__ErrorLog *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3347
+ /* "src/lxml/lxml.etree.pyx":3356
* u"Base class for XML validators."
* cdef _ErrorLog _error_log
* def __cinit__(self): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3350
+/* "src/lxml/lxml.etree.pyx":3359
* self._error_log = _ErrorLog()
*
* def validate(self, etree): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("validate", 0);
- /* "src/lxml/lxml.etree.pyx":3357
+ /* "src/lxml/lxml.etree.pyx":3366
* Returns true if document is valid, false if not.
* """
* return self(etree) # <<<<<<<<<<<<<<
}
}
if (!__pyx_t_3) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3357; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3366; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
} else {
- __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3357; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3366; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __pyx_t_3 = NULL;
__Pyx_INCREF(__pyx_v_etree);
PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v_etree);
__Pyx_GIVEREF(__pyx_v_etree);
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3357; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3366; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
}
__pyx_t_1 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":3350
+ /* "src/lxml/lxml.etree.pyx":3359
* self._error_log = _ErrorLog()
*
* def validate(self, etree): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3359
+/* "src/lxml/lxml.etree.pyx":3368
* return self(etree)
*
* def assertValid(self, etree): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("assertValid", 0);
- /* "src/lxml/lxml.etree.pyx":3364
+ /* "src/lxml/lxml.etree.pyx":3373
* Raises `DocumentInvalid` if the document does not comply with the schema.
* """
* if not self(etree): # <<<<<<<<<<<<<<
}
}
if (!__pyx_t_3) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3373; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
} else {
- __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3373; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __pyx_t_3 = NULL;
__Pyx_INCREF(__pyx_v_etree);
PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v_etree);
__Pyx_GIVEREF(__pyx_v_etree);
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3373; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3373; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_6 = ((!__pyx_t_5) != 0);
if (__pyx_t_6) {
- /* "src/lxml/lxml.etree.pyx":3365
+ /* "src/lxml/lxml.etree.pyx":3374
* """
* if not self(etree):
* raise DocumentInvalid(self._error_log._buildExceptionMessage( # <<<<<<<<<<<<<<
* u"Document does not comply with schema"),
* self._error_log)
*/
- __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_DocumentInvalid); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3365; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_DocumentInvalid); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_4 = __pyx_f_4lxml_5etree_13_BaseErrorLog__buildExceptionMessage(((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_v_self->_error_log), __pyx_kp_u_Document_does_not_comply_with_sc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3365; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __pyx_f_4lxml_5etree_13_BaseErrorLog__buildExceptionMessage(((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_v_self->_error_log), __pyx_kp_u_Document_does_not_comply_with_sc); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- /* "src/lxml/lxml.etree.pyx":3367
+ /* "src/lxml/lxml.etree.pyx":3376
* raise DocumentInvalid(self._error_log._buildExceptionMessage(
* u"Document does not comply with schema"),
* self._error_log) # <<<<<<<<<<<<<<
__pyx_t_7 = 1;
}
}
- __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3365; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
if (__pyx_t_3) {
PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __pyx_t_3 = NULL;
PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, ((PyObject *)__pyx_v_self->_error_log));
__Pyx_GIVEREF(((PyObject *)__pyx_v_self->_error_log));
__pyx_t_4 = 0;
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3365; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_8, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_Raise(__pyx_t_1, 0, 0, 0);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3365; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3359
+ /* "src/lxml/lxml.etree.pyx":3368
* return self(etree)
*
* def assertValid(self, etree): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3369
+/* "src/lxml/lxml.etree.pyx":3378
* self._error_log)
*
* def assert_(self, etree): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("assert_", 0);
- /* "src/lxml/lxml.etree.pyx":3374
+ /* "src/lxml/lxml.etree.pyx":3383
* Raises `AssertionError` if the document does not comply with the schema.
* """
* if not self(etree): # <<<<<<<<<<<<<<
}
}
if (!__pyx_t_3) {
- __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
} else {
- __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __Pyx_GIVEREF(__pyx_t_3); __pyx_t_3 = NULL;
__Pyx_INCREF(__pyx_v_etree);
PyTuple_SET_ITEM(__pyx_t_4, 0+1, __pyx_v_etree);
__Pyx_GIVEREF(__pyx_v_etree);
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_5 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_6 = ((!__pyx_t_5) != 0);
if (__pyx_t_6) {
- /* "src/lxml/lxml.etree.pyx":3375
+ /* "src/lxml/lxml.etree.pyx":3384
* """
* if not self(etree):
* raise AssertionError, self._error_log._buildExceptionMessage( # <<<<<<<<<<<<<<
* u"Document does not comply with schema")
*
*/
- __pyx_t_1 = __pyx_f_4lxml_5etree_13_BaseErrorLog__buildExceptionMessage(((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_v_self->_error_log), __pyx_kp_u_Document_does_not_comply_with_sc); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3375; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_13_BaseErrorLog__buildExceptionMessage(((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_v_self->_error_log), __pyx_kp_u_Document_does_not_comply_with_sc); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3384; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_Raise(__pyx_builtin_AssertionError, __pyx_t_1, 0, 0);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3375; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3384; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
- /* "src/lxml/lxml.etree.pyx":3369
+ /* "src/lxml/lxml.etree.pyx":3378
* self._error_log)
*
* def assert_(self, etree): # <<<<<<<<<<<<<<
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3378
+/* "src/lxml/lxml.etree.pyx":3387
* u"Document does not comply with schema")
*
* cpdef _append_log_message(self, int domain, int type, int level, int line, # <<<<<<<<<<<<<<
if (unlikely(__pyx_skip_dispatch)) ;
/* Check if overridden in Python */
else if (unlikely(Py_TYPE(((PyObject *)__pyx_v_self))->tp_dictoffset != 0)) {
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_append_log_message); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_append_log_message); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)__pyx_pw_4lxml_5etree_10_Validator_9_append_log_message)) {
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_domain); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_domain); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_type); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_type); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_level); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_level); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_6 = __Pyx_PyInt_From_int(__pyx_v_line); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyInt_From_int(__pyx_v_line); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_INCREF(__pyx_t_1);
__pyx_t_7 = __pyx_t_1; __pyx_t_8 = NULL;
__pyx_t_9 = 1;
}
}
- __pyx_t_10 = PyTuple_New(6+__pyx_t_9); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_10 = PyTuple_New(6+__pyx_t_9); if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_10);
if (__pyx_t_8) {
PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_8); __pyx_t_8 = NULL;
__pyx_t_4 = 0;
__pyx_t_5 = 0;
__pyx_t_6 = 0;
- __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_10, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_10, NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
}
- /* "src/lxml/lxml.etree.pyx":3380
+ /* "src/lxml/lxml.etree.pyx":3389
* cpdef _append_log_message(self, int domain, int type, int level, int line,
* message, filename):
* self._error_log._receiveGeneric(domain, type, level, line, message, # <<<<<<<<<<<<<<
*/
__pyx_f_4lxml_5etree_13_BaseErrorLog__receiveGeneric(((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_v_self->_error_log), __pyx_v_domain, __pyx_v_type, __pyx_v_level, __pyx_v_line, __pyx_v_message, __pyx_v_filename);
- /* "src/lxml/lxml.etree.pyx":3378
+ /* "src/lxml/lxml.etree.pyx":3387
* u"Document does not comply with schema")
*
* cpdef _append_log_message(self, int domain, int type, int level, int line, # <<<<<<<<<<<<<<
case 1:
if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_type)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 1); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_level)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 2); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 2); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_line)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 3); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 3); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_message)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 4); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 4); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
if (likely((values[5] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_filename)) != 0)) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 5); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, 5); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_append_log_message") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "_append_log_message") < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
} else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
goto __pyx_L5_argtuple_error;
values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
}
- __pyx_v_domain = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_domain == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_type = __Pyx_PyInt_As_int(values[1]); if (unlikely((__pyx_v_type == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_level = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_level == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_line = __Pyx_PyInt_As_int(values[3]); if (unlikely((__pyx_v_line == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_domain = __Pyx_PyInt_As_int(values[0]); if (unlikely((__pyx_v_domain == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_type = __Pyx_PyInt_As_int(values[1]); if (unlikely((__pyx_v_type == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_level = __Pyx_PyInt_As_int(values[2]); if (unlikely((__pyx_v_level == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_line = __Pyx_PyInt_As_int(values[3]); if (unlikely((__pyx_v_line == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_v_message = values[4];
__pyx_v_filename = values[5];
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("_append_log_message", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("lxml.etree._Validator._append_log_message", __pyx_clineno, __pyx_lineno, __pyx_filename);
__Pyx_RefNannyFinishContext();
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_append_log_message", 0);
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree_10_Validator__append_log_message(__pyx_v_self, __pyx_v_domain, __pyx_v_type, __pyx_v_level, __pyx_v_line, __pyx_v_message, __pyx_v_filename, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3378; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_10_Validator__append_log_message(__pyx_v_self, __pyx_v_domain, __pyx_v_type, __pyx_v_level, __pyx_v_line, __pyx_v_message, __pyx_v_filename, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3383
+/* "src/lxml/lxml.etree.pyx":3392
* filename)
*
* cpdef _clear_error_log(self): # <<<<<<<<<<<<<<
if (unlikely(__pyx_skip_dispatch)) ;
/* Check if overridden in Python */
else if (unlikely(Py_TYPE(((PyObject *)__pyx_v_self))->tp_dictoffset != 0)) {
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_clear_error_log); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_clear_error_log); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3392; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
if (!PyCFunction_Check(__pyx_t_1) || (PyCFunction_GET_FUNCTION(__pyx_t_1) != (PyCFunction)__pyx_pw_4lxml_5etree_10_Validator_11_clear_error_log)) {
__Pyx_XDECREF(__pyx_r);
}
}
if (__pyx_t_4) {
- __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3392; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
} else {
- __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3392; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
}
- /* "src/lxml/lxml.etree.pyx":3384
+ /* "src/lxml/lxml.etree.pyx":3393
*
* cpdef _clear_error_log(self):
* self._error_log.clear() # <<<<<<<<<<<<<<
*
* property error_log:
*/
- __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree__ErrorLog *)__pyx_v_self->_error_log->__pyx_base.__pyx_base.__pyx_vtab)->clear(__pyx_v_self->_error_log, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3384; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = ((struct __pyx_vtabstruct_4lxml_5etree__ErrorLog *)__pyx_v_self->_error_log->__pyx_base.__pyx_base.__pyx_vtab)->clear(__pyx_v_self->_error_log, 0); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3393; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3383
+ /* "src/lxml/lxml.etree.pyx":3392
* filename)
*
* cpdef _clear_error_log(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("_clear_error_log", 0);
__Pyx_XDECREF(__pyx_r);
- __pyx_t_1 = __pyx_f_4lxml_5etree_10_Validator__clear_error_log(__pyx_v_self, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3383; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __pyx_f_4lxml_5etree_10_Validator__clear_error_log(__pyx_v_self, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3392; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__pyx_r = __pyx_t_1;
__pyx_t_1 = 0;
return __pyx_r;
}
-/* "src/lxml/lxml.etree.pyx":3388
+/* "src/lxml/lxml.etree.pyx":3397
* property error_log:
* u"The log of validation errors and warnings."
* def __get__(self): # <<<<<<<<<<<<<<
int __pyx_clineno = 0;
__Pyx_RefNannySetupContext("__get__", 0);
- /* "src/lxml/lxml.etree.pyx":3389
+ /* "src/lxml/lxml.etree.pyx":3398
* u"The log of validation errors and warnings."
* def __get__(self):
* assert self._error_log is not None, "XPath evaluator not initialised" # <<<<<<<<<<<<<<
__pyx_t_1 = (((PyObject *)__pyx_v_self->_error_log) != Py_None);
if (unlikely(!(__pyx_t_1 != 0))) {
PyErr_SetObject(PyExc_AssertionError, __pyx_kp_s_XPath_evaluator_not_initialised);
- {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3389; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
}
#endif
- /* "src/lxml/lxml.etree.pyx":3390
+ /* "src/lxml/lxml.etree.pyx":3399
* def __get__(self):
* assert self._error_log is not None, "XPath evaluator not initialised"
* return self._error_log.copy() # <<<<<<<<<<<<<<
* include "dtd.pxi" # DTD
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_2 = ((struct __pyx_vtabstruct_4lxml_5etree__ErrorLog *)__pyx_v_self->_error_log->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.copy(((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_v_self->_error_log), 0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3390; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = ((struct __pyx_vtabstruct_4lxml_5etree__ErrorLog *)__pyx_v_self->_error_log->__pyx_base.__pyx_base.__pyx_vtab)->__pyx_base.__pyx_base.copy(((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_v_self->_error_log), 0); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3399; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__pyx_r = __pyx_t_2;
__pyx_t_2 = 0;
goto __pyx_L0;
- /* "src/lxml/lxml.etree.pyx":3388
+ /* "src/lxml/lxml.etree.pyx":3397
* property error_log:
* u"The log of validation errors and warnings."
* def __get__(self): # <<<<<<<<<<<<<<
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_7) {
- __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple__98, NULL);
+ __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple__99, NULL);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
if (unlikely(!__pyx_t_11)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 281; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_11);
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_7) {
- __pyx_t_9 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple__99, NULL);
+ __pyx_t_9 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple__100, NULL);
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 288; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
*/
__pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_DTDError); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__100, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__101, NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_Raise(__pyx_t_3, 0, 0, 0);
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_4) {
- __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__101, NULL);
+ __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__102, NULL);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 372; __pyx_clineno = __LINE__; goto __pyx_L5_error;}
__Pyx_GOTREF(__pyx_t_8);
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_3) {
- __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__102, NULL);
+ __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__103, NULL);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 394; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_9) {
- __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__103, NULL);
+ __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__104, NULL);
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
if (unlikely(!__pyx_t_13)) {__pyx_filename = __pyx_f[21]; __pyx_lineno = 51; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_13);
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_8) {
- __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_tuple__104, NULL);
+ __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_tuple__105, NULL);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
if (unlikely(!__pyx_t_12)) {__pyx_filename = __pyx_f[23]; __pyx_lineno = 98; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_12);
/*finally:*/ {
/*normal exit:*/{
if (__pyx_t_8) {
- __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_tuple__105, NULL);
+ __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_tuple__106, NULL);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
if (unlikely(!__pyx_t_10)) {__pyx_filename = __pyx_f[23]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L22_error;}
__Pyx_GOTREF(__pyx_t_10);
{&__pyx_n_s_XMLSyntaxError, __pyx_k_XMLSyntaxError, sizeof(__pyx_k_XMLSyntaxError), 0, 0, 1, 1},
{&__pyx_n_s_XMLTreeBuilder, __pyx_k_XMLTreeBuilder, sizeof(__pyx_k_XMLTreeBuilder), 0, 0, 1, 1},
{&__pyx_kp_s_XML_declaration_already_written, __pyx_k_XML_declaration_already_written, sizeof(__pyx_k_XML_declaration_already_written), 0, 0, 1, 0},
- {&__pyx_kp_u_XML_line_3049, __pyx_k_XML_line_3049, sizeof(__pyx_k_XML_line_3049), 0, 1, 0, 0},
+ {&__pyx_kp_u_XML_line_3058, __pyx_k_XML_line_3058, sizeof(__pyx_k_XML_line_3058), 0, 1, 0, 0},
{&__pyx_kp_u_XML_text_parser_None_base_url_No, __pyx_k_XML_text_parser_None_base_url_No, sizeof(__pyx_k_XML_text_parser_None_base_url_No), 0, 1, 0, 0},
{&__pyx_n_u_XPATH_LOCATIONSET, __pyx_k_XPATH_LOCATIONSET, sizeof(__pyx_k_XPATH_LOCATIONSET), 0, 1, 0, 1},
{&__pyx_n_u_XPATH_POINT, __pyx_k_XPATH_POINT, sizeof(__pyx_k_XPATH_POINT), 0, 1, 0, 1},
{&__pyx_kp_b__15, __pyx_k__15, sizeof(__pyx_k__15), 0, 0, 0, 0},
{&__pyx_kp_s__15, __pyx_k__15, sizeof(__pyx_k__15), 0, 0, 1, 0},
{&__pyx_kp_u__15, __pyx_k__15, sizeof(__pyx_k__15), 0, 1, 0, 0},
- {&__pyx_kp_b__199, __pyx_k__199, sizeof(__pyx_k__199), 0, 0, 0, 0},
- {&__pyx_kp_b__201, __pyx_k__201, sizeof(__pyx_k__201), 0, 0, 0, 0},
+ {&__pyx_kp_b__200, __pyx_k__200, sizeof(__pyx_k__200), 0, 0, 0, 0},
+ {&__pyx_kp_b__202, __pyx_k__202, sizeof(__pyx_k__202), 0, 0, 0, 0},
{&__pyx_kp_s__22, __pyx_k__22, sizeof(__pyx_k__22), 0, 0, 1, 0},
{&__pyx_kp_u__22, __pyx_k__22, sizeof(__pyx_k__22), 0, 1, 0, 0},
- {&__pyx_kp_b__25, __pyx_k__25, sizeof(__pyx_k__25), 0, 0, 0, 0},
+ {&__pyx_kp_s__25, __pyx_k__25, sizeof(__pyx_k__25), 0, 0, 1, 0},
{&__pyx_kp_u__25, __pyx_k__25, sizeof(__pyx_k__25), 0, 1, 0, 0},
{&__pyx_kp_b__26, __pyx_k__26, sizeof(__pyx_k__26), 0, 0, 0, 0},
{&__pyx_kp_u__26, __pyx_k__26, sizeof(__pyx_k__26), 0, 1, 0, 0},
+ {&__pyx_kp_b__27, __pyx_k__27, sizeof(__pyx_k__27), 0, 0, 0, 0},
+ {&__pyx_kp_u__27, __pyx_k__27, sizeof(__pyx_k__27), 0, 1, 0, 0},
{&__pyx_kp_u__3, __pyx_k__3, sizeof(__pyx_k__3), 0, 1, 0, 0},
- {&__pyx_kp_s__30, __pyx_k__30, sizeof(__pyx_k__30), 0, 0, 1, 0},
- {&__pyx_kp_b__35, __pyx_k__35, sizeof(__pyx_k__35), 0, 0, 0, 0},
- {&__pyx_kp_s__35, __pyx_k__35, sizeof(__pyx_k__35), 0, 0, 1, 0},
+ {&__pyx_kp_s__31, __pyx_k__31, sizeof(__pyx_k__31), 0, 0, 1, 0},
+ {&__pyx_kp_b__36, __pyx_k__36, sizeof(__pyx_k__36), 0, 0, 0, 0},
{&__pyx_kp_s__36, __pyx_k__36, sizeof(__pyx_k__36), 0, 0, 1, 0},
+ {&__pyx_kp_s__37, __pyx_k__37, sizeof(__pyx_k__37), 0, 0, 1, 0},
{&__pyx_kp_b__4, __pyx_k__4, sizeof(__pyx_k__4), 0, 0, 0, 0},
{&__pyx_kp_s__4, __pyx_k__4, sizeof(__pyx_k__4), 0, 0, 1, 0},
{&__pyx_kp_u__4, __pyx_k__4, sizeof(__pyx_k__4), 0, 1, 0, 0},
- {&__pyx_n_s__47, __pyx_k__47, sizeof(__pyx_k__47), 0, 0, 1, 1},
- {&__pyx_n_u__47, __pyx_k__47, sizeof(__pyx_k__47), 0, 1, 0, 1},
- {&__pyx_kp_u__54, __pyx_k__54, sizeof(__pyx_k__54), 0, 1, 0, 0},
- {&__pyx_kp_b__62, __pyx_k__62, sizeof(__pyx_k__62), 0, 0, 0, 0},
- {&__pyx_kp_u__65, __pyx_k__65, sizeof(__pyx_k__65), 0, 1, 0, 0},
- {&__pyx_kp_u__93, __pyx_k__93, sizeof(__pyx_k__93), 0, 1, 0, 0},
+ {&__pyx_n_s__48, __pyx_k__48, sizeof(__pyx_k__48), 0, 0, 1, 1},
+ {&__pyx_n_u__48, __pyx_k__48, sizeof(__pyx_k__48), 0, 1, 0, 1},
+ {&__pyx_kp_b__63, __pyx_k__63, sizeof(__pyx_k__63), 0, 0, 0, 0},
+ {&__pyx_kp_u__66, __pyx_k__66, sizeof(__pyx_k__66), 0, 1, 0, 0},
+ {&__pyx_kp_u__94, __pyx_k__94, sizeof(__pyx_k__94), 0, 1, 0, 0},
{&__pyx_n_s_abspath, __pyx_k_abspath, sizeof(__pyx_k_abspath), 0, 0, 1, 1},
{&__pyx_n_s_accepted_domains, __pyx_k_accepted_domains, sizeof(__pyx_k_accepted_domains), 0, 0, 1, 1},
{&__pyx_n_s_access_control, __pyx_k_access_control, sizeof(__pyx_k_access_control), 0, 0, 1, 1},
{&__pyx_kp_u_s, __pyx_k_s, sizeof(__pyx_k_s), 0, 1, 0, 0},
{&__pyx_kp_u_s_2, __pyx_k_s_2, sizeof(__pyx_k_s_2), 0, 1, 0, 0},
{&__pyx_kp_u_s_3, __pyx_k_s_3, sizeof(__pyx_k_s_3), 0, 1, 0, 0},
- {&__pyx_n_s_s_4, __pyx_k_s_4, sizeof(__pyx_k_s_4), 0, 0, 1, 1},
+ {&__pyx_kp_u_s_4, __pyx_k_s_4, sizeof(__pyx_k_s_4), 0, 1, 0, 0},
+ {&__pyx_kp_u_s_5, __pyx_k_s_5, sizeof(__pyx_k_s_5), 0, 1, 0, 0},
+ {&__pyx_n_s_s_6, __pyx_k_s_6, sizeof(__pyx_k_s_6), 0, 0, 1, 1},
{&__pyx_kp_u_s_a_zA_Z0_9__s_s_0_9, __pyx_k_s_a_zA_Z0_9__s_s_0_9, sizeof(__pyx_k_s_a_zA_Z0_9__s_s_0_9), 0, 1, 0, 0},
{&__pyx_kp_s_s_d, __pyx_k_s_d, sizeof(__pyx_k_s_d), 0, 0, 1, 0},
{&__pyx_kp_u_s_d_d_s_s_s_s, __pyx_k_s_d_d_s_s_s_s, sizeof(__pyx_k_s_d_d_s_s_s_s), 0, 1, 0, 0},
__pyx_builtin_UnicodeEncodeError = __Pyx_GetBuiltinName(__pyx_n_s_UnicodeEncodeError); if (!__pyx_builtin_UnicodeEncodeError) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 1435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_UnicodeDecodeError = __Pyx_GetBuiltinName(__pyx_n_s_UnicodeDecodeError); if (!__pyx_builtin_UnicodeDecodeError) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 1453; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_enumerate = __Pyx_GetBuiltinName(__pyx_n_s_enumerate); if (!__pyx_builtin_enumerate) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 298; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 665; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_builtin_FutureWarning = __Pyx_GetBuiltinName(__pyx_n_s_FutureWarning); if (!__pyx_builtin_FutureWarning) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1107; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_builtin_NotImplemented = __Pyx_GetBuiltinName(__pyx_n_s_NotImplemented); if (!__pyx_builtin_NotImplemented) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_builtin_StopIteration = __Pyx_GetBuiltinName(__pyx_n_s_StopIteration); if (!__pyx_builtin_StopIteration) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError); if (!__pyx_builtin_IndexError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_builtin_FutureWarning = __Pyx_GetBuiltinName(__pyx_n_s_FutureWarning); if (!__pyx_builtin_FutureWarning) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_builtin_NotImplemented = __Pyx_GetBuiltinName(__pyx_n_s_NotImplemented); if (!__pyx_builtin_NotImplemented) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1758; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_builtin_StopIteration = __Pyx_GetBuiltinName(__pyx_n_s_StopIteration); if (!__pyx_builtin_StopIteration) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2458; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_ReferenceError = __Pyx_GetBuiltinName(__pyx_n_s_ReferenceError); if (!__pyx_builtin_ReferenceError) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_IOError = __Pyx_GetBuiltinName(__pyx_n_s_IOError); if (!__pyx_builtin_IOError) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 618; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_LookupError = __Pyx_GetBuiltinName(__pyx_n_s_LookupError); if (!__pyx_builtin_LookupError) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 802; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_builtin_open = __Pyx_GetBuiltinName(__pyx_n_s_open); if (!__pyx_builtin_open) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 460; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_builtin_open = __Pyx_GetBuiltinName(__pyx_n_s_open); if (!__pyx_builtin_open) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_NotImplementedError = __Pyx_GetBuiltinName(__pyx_n_s_NotImplementedError); if (!__pyx_builtin_NotImplementedError) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 633; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_BaseException = __Pyx_GetBuiltinName(__pyx_n_s_BaseException); if (!__pyx_builtin_BaseException) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 125; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_builtin_AssertionError = __Pyx_GetBuiltinName(__pyx_n_s_AssertionError); if (!__pyx_builtin_AssertionError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3375; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_builtin_AssertionError = __Pyx_GetBuiltinName(__pyx_n_s_AssertionError); if (!__pyx_builtin_AssertionError) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3384; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
return 0;
__pyx_L1_error:;
return -1;
__Pyx_GOTREF(__pyx_tuple__24);
__Pyx_GIVEREF(__pyx_tuple__24);
- /* "src/lxml/lxml.etree.pyx":1907
+ /* "src/lxml/lxml.etree.pyx":1916
* if method == 'c14n':
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N") # <<<<<<<<<<<<<<
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N")
*/
- __pyx_tuple__27 = PyTuple_Pack(1, __pyx_kp_s_Cannot_specify_encoding_with_C14); if (unlikely(!__pyx_tuple__27)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1907; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__27);
- __Pyx_GIVEREF(__pyx_tuple__27);
+ __pyx_tuple__28 = PyTuple_Pack(1, __pyx_kp_s_Cannot_specify_encoding_with_C14); if (unlikely(!__pyx_tuple__28)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1916; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__28);
+ __Pyx_GIVEREF(__pyx_tuple__28);
- /* "src/lxml/lxml.etree.pyx":1909
+ /* "src/lxml/lxml.etree.pyx":1918
* raise ValueError("Cannot specify encoding with C14N")
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N") # <<<<<<<<<<<<<<
*
* _tofilelikeC14N(file, self._context_node, exclusive, with_comments,
*/
- __pyx_tuple__28 = PyTuple_Pack(1, __pyx_kp_s_Cannot_enable_XML_declaration_in); if (unlikely(!__pyx_tuple__28)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__28);
- __Pyx_GIVEREF(__pyx_tuple__28);
+ __pyx_tuple__29 = PyTuple_Pack(1, __pyx_kp_s_Cannot_enable_XML_declaration_in); if (unlikely(!__pyx_tuple__29)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1918; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__29);
+ __Pyx_GIVEREF(__pyx_tuple__29);
- /* "src/lxml/lxml.etree.pyx":1915
+ /* "src/lxml/lxml.etree.pyx":1924
* return
* if not with_comments:
* raise ValueError("Can only discard comments in C14N serialisation") # <<<<<<<<<<<<<<
* # suppress decl. in default case (purely for ElementTree compatibility)
* if xml_declaration is not None:
*/
- __pyx_tuple__29 = PyTuple_Pack(1, __pyx_kp_s_Can_only_discard_comments_in_C14); if (unlikely(!__pyx_tuple__29)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__29);
- __Pyx_GIVEREF(__pyx_tuple__29);
+ __pyx_tuple__30 = PyTuple_Pack(1, __pyx_kp_s_Can_only_discard_comments_in_C14); if (unlikely(!__pyx_tuple__30)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1924; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__30);
+ __Pyx_GIVEREF(__pyx_tuple__30);
- /* "src/lxml/lxml.etree.pyx":2099
+ /* "src/lxml/lxml.etree.pyx":2108
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.find(path, namespaces)
*/
- __pyx_slice__31 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__31)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__31);
- __Pyx_GIVEREF(__pyx_slice__31);
+ __pyx_slice__32 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__32)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__32);
+ __Pyx_GIVEREF(__pyx_slice__32);
- /* "src/lxml/lxml.etree.pyx":2116
+ /* "src/lxml/lxml.etree.pyx":2125
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.findtext(path, default, namespaces)
*/
- __pyx_slice__32 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__32)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__32);
- __Pyx_GIVEREF(__pyx_slice__32);
+ __pyx_slice__33 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__33)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2125; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__33);
+ __Pyx_GIVEREF(__pyx_slice__33);
- /* "src/lxml/lxml.etree.pyx":2133
+ /* "src/lxml/lxml.etree.pyx":2142
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.findall(path, namespaces)
*/
- __pyx_slice__33 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__33)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__33);
- __Pyx_GIVEREF(__pyx_slice__33);
+ __pyx_slice__34 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__34)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__34);
+ __Pyx_GIVEREF(__pyx_slice__34);
- /* "src/lxml/lxml.etree.pyx":2150
+ /* "src/lxml/lxml.etree.pyx":2159
* root = self.getroot()
* if _isString(path):
* if path[:1] == "/": # <<<<<<<<<<<<<<
* path = "." + path
* return root.iterfind(path, namespaces)
*/
- __pyx_slice__34 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__34)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2150; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__34);
- __Pyx_GIVEREF(__pyx_slice__34);
+ __pyx_slice__35 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__35)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__35);
+ __Pyx_GIVEREF(__pyx_slice__35);
- /* "src/lxml/lxml.etree.pyx":2851
+ /* "src/lxml/lxml.etree.pyx":2860
* _assertValidNode(element)
* if with_tail:
* events = (u"start", u"end") # <<<<<<<<<<<<<<
* else:
* events = (u"start",)
*/
- __pyx_tuple__37 = PyTuple_Pack(2, __pyx_n_u_start, __pyx_n_u_end); if (unlikely(!__pyx_tuple__37)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2851; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__37);
- __Pyx_GIVEREF(__pyx_tuple__37);
+ __pyx_tuple__38 = PyTuple_Pack(2, __pyx_n_u_start, __pyx_n_u_end); if (unlikely(!__pyx_tuple__38)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2860; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__38);
+ __Pyx_GIVEREF(__pyx_tuple__38);
- /* "src/lxml/lxml.etree.pyx":2853
+ /* "src/lxml/lxml.etree.pyx":2862
* events = (u"start", u"end")
* else:
* events = (u"start",) # <<<<<<<<<<<<<<
* self._start_element = element
* self._nextEvent = iterwalk(element, events=events, tag=tag).__next__
*/
- __pyx_tuple__38 = PyTuple_Pack(1, __pyx_n_u_start); if (unlikely(!__pyx_tuple__38)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2853; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__38);
- __Pyx_GIVEREF(__pyx_tuple__38);
+ __pyx_tuple__39 = PyTuple_Pack(1, __pyx_n_u_start); if (unlikely(!__pyx_tuple__39)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2862; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__39);
+ __Pyx_GIVEREF(__pyx_tuple__39);
- /* "src/lxml/lxml.etree.pyx":3110
+ /* "src/lxml/lxml.etree.pyx":3119
* cdef _Document doc
* if isinstance(strings, (bytes, unicode)):
* raise ValueError("passing a single string into fromstringlist() is not" # <<<<<<<<<<<<<<
* " efficient, use fromstring() instead")
* if parser is None:
*/
- __pyx_tuple__39 = PyTuple_Pack(1, __pyx_kp_s_passing_a_single_string_into_fro); if (unlikely(!__pyx_tuple__39)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__39);
- __Pyx_GIVEREF(__pyx_tuple__39);
+ __pyx_tuple__40 = PyTuple_Pack(1, __pyx_kp_s_passing_a_single_string_into_fro); if (unlikely(!__pyx_tuple__40)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__40);
+ __Pyx_GIVEREF(__pyx_tuple__40);
- /* "src/lxml/lxml.etree.pyx":3189
+ /* "src/lxml/lxml.etree.pyx":3198
* if method == 'c14n':
* if encoding is not None:
* raise ValueError("Cannot specify encoding with C14N") # <<<<<<<<<<<<<<
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N")
*/
- __pyx_tuple__40 = PyTuple_Pack(1, __pyx_kp_s_Cannot_specify_encoding_with_C14); if (unlikely(!__pyx_tuple__40)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__40);
- __Pyx_GIVEREF(__pyx_tuple__40);
+ __pyx_tuple__41 = PyTuple_Pack(1, __pyx_kp_s_Cannot_specify_encoding_with_C14); if (unlikely(!__pyx_tuple__41)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3198; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__41);
+ __Pyx_GIVEREF(__pyx_tuple__41);
- /* "src/lxml/lxml.etree.pyx":3191
+ /* "src/lxml/lxml.etree.pyx":3200
* raise ValueError("Cannot specify encoding with C14N")
* if xml_declaration:
* raise ValueError("Cannot enable XML declaration in C14N") # <<<<<<<<<<<<<<
* return _tostringC14N(element_or_tree, exclusive, with_comments, inclusive_ns_prefixes)
* if not with_comments:
*/
- __pyx_tuple__41 = PyTuple_Pack(1, __pyx_kp_s_Cannot_enable_XML_declaration_in); if (unlikely(!__pyx_tuple__41)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3191; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__41);
- __Pyx_GIVEREF(__pyx_tuple__41);
+ __pyx_tuple__42 = PyTuple_Pack(1, __pyx_kp_s_Cannot_enable_XML_declaration_in); if (unlikely(!__pyx_tuple__42)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3200; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__42);
+ __Pyx_GIVEREF(__pyx_tuple__42);
- /* "src/lxml/lxml.etree.pyx":3194
+ /* "src/lxml/lxml.etree.pyx":3203
* return _tostringC14N(element_or_tree, exclusive, with_comments, inclusive_ns_prefixes)
* if not with_comments:
* raise ValueError("Can only discard comments in C14N serialisation") # <<<<<<<<<<<<<<
* if encoding is _unicode or (encoding is not None and encoding.upper() == 'UNICODE'):
* if xml_declaration:
*/
- __pyx_tuple__42 = PyTuple_Pack(1, __pyx_kp_s_Can_only_discard_comments_in_C14); if (unlikely(!__pyx_tuple__42)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3194; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__42);
- __Pyx_GIVEREF(__pyx_tuple__42);
+ __pyx_tuple__43 = PyTuple_Pack(1, __pyx_kp_s_Can_only_discard_comments_in_C14); if (unlikely(!__pyx_tuple__43)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__43);
+ __Pyx_GIVEREF(__pyx_tuple__43);
/* "src/lxml/readonlytree.pxi":18
* """
* return 0
*
*/
- __pyx_tuple__43 = PyTuple_Pack(1, __pyx_kp_s_Proxy_invalidated); if (unlikely(!__pyx_tuple__43)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__43);
- __Pyx_GIVEREF(__pyx_tuple__43);
+ __pyx_tuple__44 = PyTuple_Pack(1, __pyx_kp_s_Proxy_invalidated); if (unlikely(!__pyx_tuple__44)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__44);
+ __Pyx_GIVEREF(__pyx_tuple__44);
/* "src/lxml/readonlytree.pxi":196
* children = [ el for el in children if el.tag == tag ]
* return iter(children)
*
*/
- __pyx_slice__44 = PySlice_New(Py_None, Py_None, __pyx_int_neg_1); if (unlikely(!__pyx_slice__44)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 196; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__44);
- __Pyx_GIVEREF(__pyx_slice__44);
+ __pyx_slice__45 = PySlice_New(Py_None, Py_None, __pyx_int_neg_1); if (unlikely(!__pyx_slice__45)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 196; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__45);
+ __Pyx_GIVEREF(__pyx_slice__45);
/* "src/lxml/classlookup.pxi":61
* tag = _utf8(_getattr(_getattr(self, '__class__'), '__name__'))
* try:
* parser = _getattr(self, 'PARSER')
*/
- __pyx_tuple__45 = PyTuple_Pack(1, __pyx_kp_b__4); if (unlikely(!__pyx_tuple__45)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 61; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__45);
- __Pyx_GIVEREF(__pyx_tuple__45);
+ __pyx_tuple__46 = PyTuple_Pack(1, __pyx_kp_b__4); if (unlikely(!__pyx_tuple__46)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 61; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__46);
+ __Pyx_GIVEREF(__pyx_tuple__46);
/* "src/lxml/nsclasses.pxi":46
* class_dict_iterable = class_dict_iterable.items()
* self[name] = item
*
*/
- __pyx_slice__46 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__46)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 46; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__46);
- __Pyx_GIVEREF(__pyx_slice__46);
+ __pyx_slice__47 = PySlice_New(Py_None, __pyx_int_1, Py_None); if (unlikely(!__pyx_slice__47)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 46; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__47);
+ __Pyx_GIVEREF(__pyx_slice__47);
/* "src/lxml/parser.pxi":1506
* XMLParser.__init__(self, **kwargs)
* self._setBaseURL(base_url)
* self._collectEvents(events, tag)
*/
- __pyx_tuple__48 = PyTuple_Pack(1, __pyx_n_s_end); if (unlikely(!__pyx_tuple__48)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1506; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__48);
- __Pyx_GIVEREF(__pyx_tuple__48);
+ __pyx_tuple__49 = PyTuple_Pack(1, __pyx_n_s_end); if (unlikely(!__pyx_tuple__49)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1506; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__49);
+ __Pyx_GIVEREF(__pyx_tuple__49);
/* "src/lxml/parser.pxi":1670
* HTMLParser.__init__(self, **kwargs)
* self._setBaseURL(base_url)
* self._collectEvents(events, tag)
*/
- __pyx_tuple__49 = PyTuple_Pack(1, __pyx_n_s_end); if (unlikely(!__pyx_tuple__49)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__49);
- __Pyx_GIVEREF(__pyx_tuple__49);
+ __pyx_tuple__50 = PyTuple_Pack(1, __pyx_n_s_end); if (unlikely(!__pyx_tuple__50)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1670; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__50);
+ __Pyx_GIVEREF(__pyx_tuple__50);
/* "src/lxml/parser.pxi":1823
* if isinstance(text, unicode):
* u"Unicode strings with encoding declaration are not supported. "
* u"Please use bytes input or XML fragments without declaration.")
*/
- __pyx_tuple__50 = PyTuple_Pack(1, __pyx_kp_u_Unicode_strings_with_encoding_de); if (unlikely(!__pyx_tuple__50)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__50);
- __Pyx_GIVEREF(__pyx_tuple__50);
+ __pyx_tuple__51 = PyTuple_Pack(1, __pyx_kp_u_Unicode_strings_with_encoding_de); if (unlikely(!__pyx_tuple__51)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1823; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__51);
+ __Pyx_GIVEREF(__pyx_tuple__51);
/* "src/lxml/serializer.pxi":115
* if enchandler is NULL and c_enc is not NULL:
* raise LookupError, u"unknown encoding: '%s'" % encoding
* c_buffer = tree.xmlAllocOutputBuffer(enchandler)
*/
- __pyx_tuple__51 = PyTuple_Pack(1, __pyx_kp_s_UTF_8); if (unlikely(!__pyx_tuple__51)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__51);
- __Pyx_GIVEREF(__pyx_tuple__51);
+ __pyx_tuple__52 = PyTuple_Pack(1, __pyx_kp_s_UTF_8); if (unlikely(!__pyx_tuple__52)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__52);
+ __Pyx_GIVEREF(__pyx_tuple__52);
- /* "src/lxml/serializer.pxi":577
+ /* "src/lxml/serializer.pxi":586
* writer = _FilelikeWriter(f, compression=compression)
* c_buffer = writer._createOutputBuffer(NULL)
* with writer.error_log: # <<<<<<<<<<<<<<
* bytes_count = c14n.xmlC14NDocSaveTo(
* c_doc, NULL, exclusive, c_inclusive_ns_prefixes,
*/
- __pyx_tuple__58 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__58)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 577; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__58);
- __Pyx_GIVEREF(__pyx_tuple__58);
+ __pyx_tuple__59 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__59)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 586; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__59);
+ __Pyx_GIVEREF(__pyx_tuple__59);
- /* "src/lxml/serializer.pxi":731
+ /* "src/lxml/serializer.pxi":740
* cdef int c_standalone
* if self._method != OUTPUT_METHOD_XML:
* raise LxmlSyntaxError("only XML documents have declarations") # <<<<<<<<<<<<<<
* if self._status >= WRITER_DECL_WRITTEN:
* raise LxmlSyntaxError("XML declaration already written")
*/
- __pyx_tuple__59 = PyTuple_Pack(1, __pyx_kp_s_only_XML_documents_have_declarat); if (unlikely(!__pyx_tuple__59)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 731; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__59);
- __Pyx_GIVEREF(__pyx_tuple__59);
+ __pyx_tuple__60 = PyTuple_Pack(1, __pyx_kp_s_only_XML_documents_have_declarat); if (unlikely(!__pyx_tuple__60)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__60);
+ __Pyx_GIVEREF(__pyx_tuple__60);
- /* "src/lxml/serializer.pxi":733
+ /* "src/lxml/serializer.pxi":742
* raise LxmlSyntaxError("only XML documents have declarations")
* if self._status >= WRITER_DECL_WRITTEN:
* raise LxmlSyntaxError("XML declaration already written") # <<<<<<<<<<<<<<
* version = _utf8orNone(version)
* c_version = _xcstr(version) if version is not None else NULL
*/
- __pyx_tuple__60 = PyTuple_Pack(1, __pyx_kp_s_XML_declaration_already_written); if (unlikely(!__pyx_tuple__60)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__60);
- __Pyx_GIVEREF(__pyx_tuple__60);
+ __pyx_tuple__61 = PyTuple_Pack(1, __pyx_kp_s_XML_declaration_already_written); if (unlikely(!__pyx_tuple__61)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__61);
+ __Pyx_GIVEREF(__pyx_tuple__61);
- /* "src/lxml/serializer.pxi":760
+ /* "src/lxml/serializer.pxi":769
* return
* if self._status >= WRITER_DTD_WRITTEN:
* raise LxmlSyntaxError("DOCTYPE already written or cannot write it here") # <<<<<<<<<<<<<<
* doctype = _utf8(doctype)
* _writeDoctype(self._c_out, _xcstr(doctype))
*/
- __pyx_tuple__61 = PyTuple_Pack(1, __pyx_kp_s_DOCTYPE_already_written_or_canno); if (unlikely(!__pyx_tuple__61)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__61);
- __Pyx_GIVEREF(__pyx_tuple__61);
+ __pyx_tuple__62 = PyTuple_Pack(1, __pyx_kp_s_DOCTYPE_already_written_or_canno); if (unlikely(!__pyx_tuple__62)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__62);
+ __Pyx_GIVEREF(__pyx_tuple__62);
- /* "src/lxml/serializer.pxi":804
+ /* "src/lxml/serializer.pxi":813
* cdef _write_start_element(self, element_config):
* if self._status > WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("cannot append trailing element to complete XML document") # <<<<<<<<<<<<<<
* ns, name, attributes, nsmap = element_config
* flat_namespace_map, new_namespaces = self._collect_namespaces(nsmap)
*/
- __pyx_tuple__63 = PyTuple_Pack(1, __pyx_kp_s_cannot_append_trailing_element_t); if (unlikely(!__pyx_tuple__63)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 804; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__63);
- __Pyx_GIVEREF(__pyx_tuple__63);
+ __pyx_tuple__64 = PyTuple_Pack(1, __pyx_kp_s_cannot_append_trailing_element_t); if (unlikely(!__pyx_tuple__64)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 813; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__64);
+ __Pyx_GIVEREF(__pyx_tuple__64);
- /* "src/lxml/serializer.pxi":846
+ /* "src/lxml/serializer.pxi":855
* cdef _write_end_element(self, element_config):
* if self._status != WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("not in an element") # <<<<<<<<<<<<<<
* if not self._element_stack or self._element_stack[-1][:2] != element_config[:2]:
* raise LxmlSyntaxError("inconsistent exit action in context manager")
*/
- __pyx_tuple__67 = PyTuple_Pack(1, __pyx_kp_s_not_in_an_element); if (unlikely(!__pyx_tuple__67)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__67);
- __Pyx_GIVEREF(__pyx_tuple__67);
+ __pyx_tuple__68 = PyTuple_Pack(1, __pyx_kp_s_not_in_an_element); if (unlikely(!__pyx_tuple__68)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 855; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__68);
+ __Pyx_GIVEREF(__pyx_tuple__68);
- /* "src/lxml/serializer.pxi":847
+ /* "src/lxml/serializer.pxi":856
* if self._status != WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("not in an element")
* if not self._element_stack or self._element_stack[-1][:2] != element_config[:2]: # <<<<<<<<<<<<<<
* raise LxmlSyntaxError("inconsistent exit action in context manager")
*
*/
- __pyx_slice__68 = PySlice_New(Py_None, __pyx_int_2, Py_None); if (unlikely(!__pyx_slice__68)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__68);
- __Pyx_GIVEREF(__pyx_slice__68);
- __pyx_slice__69 = PySlice_New(Py_None, __pyx_int_2, Py_None); if (unlikely(!__pyx_slice__69)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 847; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_slice__69 = PySlice_New(Py_None, __pyx_int_2, Py_None); if (unlikely(!__pyx_slice__69)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_slice__69);
__Pyx_GIVEREF(__pyx_slice__69);
+ __pyx_slice__70 = PySlice_New(Py_None, __pyx_int_2, Py_None); if (unlikely(!__pyx_slice__70)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 856; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__70);
+ __Pyx_GIVEREF(__pyx_slice__70);
- /* "src/lxml/serializer.pxi":848
+ /* "src/lxml/serializer.pxi":857
* raise LxmlSyntaxError("not in an element")
* if not self._element_stack or self._element_stack[-1][:2] != element_config[:2]:
* raise LxmlSyntaxError("inconsistent exit action in context manager") # <<<<<<<<<<<<<<
*
* name, prefix = self._element_stack.pop()[1:3]
*/
- __pyx_tuple__70 = PyTuple_Pack(1, __pyx_kp_s_inconsistent_exit_action_in_cont); if (unlikely(!__pyx_tuple__70)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 848; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__70);
- __Pyx_GIVEREF(__pyx_tuple__70);
+ __pyx_tuple__71 = PyTuple_Pack(1, __pyx_kp_s_inconsistent_exit_action_in_cont); if (unlikely(!__pyx_tuple__71)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 857; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__71);
+ __Pyx_GIVEREF(__pyx_tuple__71);
- /* "src/lxml/serializer.pxi":850
+ /* "src/lxml/serializer.pxi":859
* raise LxmlSyntaxError("inconsistent exit action in context manager")
*
* name, prefix = self._element_stack.pop()[1:3] # <<<<<<<<<<<<<<
* tree.xmlOutputBufferWrite(self._c_out, 2, '</')
* self._write_qname(name, prefix)
*/
- __pyx_slice__71 = PySlice_New(__pyx_int_1, __pyx_int_3, Py_None); if (unlikely(!__pyx_slice__71)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 850; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__71);
- __Pyx_GIVEREF(__pyx_slice__71);
+ __pyx_slice__72 = PySlice_New(__pyx_int_1, __pyx_int_3, Py_None); if (unlikely(!__pyx_slice__72)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 859; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__72);
+ __Pyx_GIVEREF(__pyx_slice__72);
- /* "src/lxml/serializer.pxi":904
+ /* "src/lxml/serializer.pxi":914
* if self._status != WRITER_IN_ELEMENT:
* if self._status > WRITER_IN_ELEMENT or content.strip():
* raise LxmlSyntaxError("not in an element") # <<<<<<<<<<<<<<
* content = _utf8(content)
* tree.xmlOutputBufferWriteEscape(self._c_out, _xcstr(content), NULL)
*/
- __pyx_tuple__73 = PyTuple_Pack(1, __pyx_kp_s_not_in_an_element); if (unlikely(!__pyx_tuple__73)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 904; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__73);
- __Pyx_GIVEREF(__pyx_tuple__73);
+ __pyx_tuple__74 = PyTuple_Pack(1, __pyx_kp_s_not_in_an_element); if (unlikely(!__pyx_tuple__74)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 914; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__74);
+ __Pyx_GIVEREF(__pyx_tuple__74);
- /* "src/lxml/serializer.pxi":909
+ /* "src/lxml/serializer.pxi":919
* elif iselement(content):
* if self._status > WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("cannot append trailing element to complete XML document") # <<<<<<<<<<<<<<
* _writeNodeToBuffer(self._c_out, (<_Element>content)._c_node,
* self._c_encoding, NULL, self._method,
*/
- __pyx_tuple__74 = PyTuple_Pack(1, __pyx_kp_s_cannot_append_trailing_element_t); if (unlikely(!__pyx_tuple__74)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 909; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__74);
- __Pyx_GIVEREF(__pyx_tuple__74);
+ __pyx_tuple__75 = PyTuple_Pack(1, __pyx_kp_s_cannot_append_trailing_element_t); if (unlikely(!__pyx_tuple__75)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 919; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__75);
+ __Pyx_GIVEREF(__pyx_tuple__75);
- /* "src/lxml/serializer.pxi":933
+ /* "src/lxml/serializer.pxi":943
* if raise_on_error:
* if self._status < WRITER_IN_ELEMENT:
* raise LxmlSyntaxError("no content written") # <<<<<<<<<<<<<<
* if self._element_stack:
* raise LxmlSyntaxError("pending open tags on close")
*/
- __pyx_tuple__75 = PyTuple_Pack(1, __pyx_kp_s_no_content_written); if (unlikely(!__pyx_tuple__75)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 933; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__75);
- __Pyx_GIVEREF(__pyx_tuple__75);
+ __pyx_tuple__76 = PyTuple_Pack(1, __pyx_kp_s_no_content_written); if (unlikely(!__pyx_tuple__76)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 943; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__76);
+ __Pyx_GIVEREF(__pyx_tuple__76);
- /* "src/lxml/serializer.pxi":935
+ /* "src/lxml/serializer.pxi":945
* raise LxmlSyntaxError("no content written")
* if self._element_stack:
* raise LxmlSyntaxError("pending open tags on close") # <<<<<<<<<<<<<<
* error_result = self._c_out.error
* if error_result == xmlerror.XML_ERR_OK:
*/
- __pyx_tuple__76 = PyTuple_Pack(1, __pyx_kp_s_pending_open_tags_on_close); if (unlikely(!__pyx_tuple__76)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 935; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__76);
- __Pyx_GIVEREF(__pyx_tuple__76);
+ __pyx_tuple__77 = PyTuple_Pack(1, __pyx_kp_s_pending_open_tags_on_close); if (unlikely(!__pyx_tuple__77)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__77);
+ __Pyx_GIVEREF(__pyx_tuple__77);
/* "src/lxml/iterparse.pxi":66
* cdef bint _close_source_after_read
* attribute_defaults=False, dtd_validation=False,
* load_dtd=False, no_network=True, remove_blank_text=False,
*/
- __pyx_tuple__77 = PyTuple_Pack(1, __pyx_n_u_end); if (unlikely(!__pyx_tuple__77)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 66; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__77);
- __Pyx_GIVEREF(__pyx_tuple__77);
+ __pyx_tuple__78 = PyTuple_Pack(1, __pyx_n_u_end); if (unlikely(!__pyx_tuple__78)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 66; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__78);
+ __Pyx_GIVEREF(__pyx_tuple__78);
/* "src/lxml/iterparse.pxi":218
* @cython.final
* if not isinstance(data, bytes):
* self._close_source()
*/
- __pyx_tuple__78 = PyTuple_Pack(1, __pyx_int_32768); if (unlikely(!__pyx_tuple__78)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 218; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__78);
- __Pyx_GIVEREF(__pyx_tuple__78);
+ __pyx_tuple__79 = PyTuple_Pack(1, __pyx_int_32768); if (unlikely(!__pyx_tuple__79)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 218; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__79);
+ __Pyx_GIVEREF(__pyx_tuple__79);
/* "src/lxml/iterparse.pxi":221
* if not isinstance(data, bytes):
* if not data:
* try:
*/
- __pyx_tuple__79 = PyTuple_Pack(1, __pyx_kp_s_reading_file_objects_must_return); if (unlikely(!__pyx_tuple__79)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__79);
- __Pyx_GIVEREF(__pyx_tuple__79);
+ __pyx_tuple__80 = PyTuple_Pack(1, __pyx_kp_s_reading_file_objects_must_return); if (unlikely(!__pyx_tuple__80)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__80);
+ __Pyx_GIVEREF(__pyx_tuple__80);
/* "src/lxml/iterparse.pxi":245
* cdef int _event_filter
* cdef _Element root
* cdef int ns_count
*/
- __pyx_tuple__80 = PyTuple_Pack(1, __pyx_n_u_end); if (unlikely(!__pyx_tuple__80)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 245; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__80);
- __Pyx_GIVEREF(__pyx_tuple__80);
+ __pyx_tuple__81 = PyTuple_Pack(1, __pyx_n_u_end); if (unlikely(!__pyx_tuple__81)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 245; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__81);
+ __Pyx_GIVEREF(__pyx_tuple__81);
/* "src/lxml/iterparse.pxi":274
* cdef int ns_count = 0
* if self._matcher is not None and self._index >= 0:
* node = self._node_stack[self._index][0]
*/
- __pyx_tuple__81 = PyTuple_Pack(1, __pyx_int_0); if (unlikely(!__pyx_tuple__81)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 274; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__81);
- __Pyx_GIVEREF(__pyx_tuple__81);
+ __pyx_tuple__82 = PyTuple_Pack(1, __pyx_int_0); if (unlikely(!__pyx_tuple__82)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 274; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__82);
+ __Pyx_GIVEREF(__pyx_tuple__82);
/* "src/lxml/iterparse.pxi":306
* self._index += 1
* raise StopIteration
*
*/
- __pyx_tuple__82 = PyTuple_Pack(1, __pyx_int_0); if (unlikely(!__pyx_tuple__82)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__82);
- __Pyx_GIVEREF(__pyx_tuple__82);
+ __pyx_tuple__83 = PyTuple_Pack(1, __pyx_int_0); if (unlikely(!__pyx_tuple__83)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 306; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__83);
+ __Pyx_GIVEREF(__pyx_tuple__83);
/* "src/lxml/iterparse.pxi":330
* self._events.append( (u"end", node) )
* for i from 0 <= i < ns_count:
* self._events.append(event)
*/
- __pyx_tuple__83 = PyTuple_Pack(2, __pyx_kp_u_end_ns, Py_None); if (unlikely(!__pyx_tuple__83)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 330; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__83);
- __Pyx_GIVEREF(__pyx_tuple__83);
+ __pyx_tuple__84 = PyTuple_Pack(2, __pyx_kp_u_end_ns, Py_None); if (unlikely(!__pyx_tuple__84)) {__pyx_filename = __pyx_f[14]; __pyx_lineno = 330; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__84);
+ __Pyx_GIVEREF(__pyx_tuple__84);
/* "src/lxml/xmlid.pxi":15
* global _find_id_attributes
*
* # ElementTree compatible implementation: parse and look for 'id' attributes
*/
- __pyx_tuple__84 = PyTuple_Pack(1, __pyx_kp_u_string_id); if (unlikely(!__pyx_tuple__84)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 15; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__84);
- __Pyx_GIVEREF(__pyx_tuple__84);
+ __pyx_tuple__85 = PyTuple_Pack(1, __pyx_kp_u_string_id); if (unlikely(!__pyx_tuple__85)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 15; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__85);
+ __Pyx_GIVEREF(__pyx_tuple__85);
/* "src/lxml/xmlid.pxi":21
* dic = {}
* return (root, dic)
*
*/
- __pyx_tuple__85 = PyTuple_Pack(1, __pyx_n_u_id); if (unlikely(!__pyx_tuple__85)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__85);
- __Pyx_GIVEREF(__pyx_tuple__85);
+ __pyx_tuple__86 = PyTuple_Pack(1, __pyx_n_u_id); if (unlikely(!__pyx_tuple__86)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 21; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__86);
+ __Pyx_GIVEREF(__pyx_tuple__86);
/* "src/lxml/xmlid.pxi":114
* if self._keys is None:
*
* def __iter__(self):
*/
- __pyx_slice__86 = PySlice_New(Py_None, Py_None, Py_None); if (unlikely(!__pyx_slice__86)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__86);
- __Pyx_GIVEREF(__pyx_slice__86);
+ __pyx_slice__87 = PySlice_New(Py_None, Py_None, Py_None); if (unlikely(!__pyx_slice__87)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__87);
+ __Pyx_GIVEREF(__pyx_slice__87);
/* "src/lxml/xmlid.pxi":132
* if self._items is None:
*
* def iteritems(self):
*/
- __pyx_slice__87 = PySlice_New(Py_None, Py_None, Py_None); if (unlikely(!__pyx_slice__87)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__87);
- __Pyx_GIVEREF(__pyx_slice__87);
+ __pyx_slice__88 = PySlice_New(Py_None, Py_None, Py_None); if (unlikely(!__pyx_slice__88)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__88);
+ __Pyx_GIVEREF(__pyx_slice__88);
/* "src/lxml/extensions.pxi":446
* if function_mapping is None:
* for function_name in function_mapping:
* functions[(ns, function_name)] = getattr(module, function_name)
*/
- __pyx_tuple__88 = PyTuple_Pack(1, __pyx_n_u__47); if (unlikely(!__pyx_tuple__88)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 446; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__88);
- __Pyx_GIVEREF(__pyx_tuple__88);
+ __pyx_tuple__89 = PyTuple_Pack(1, __pyx_n_u__48); if (unlikely(!__pyx_tuple__89)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 446; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__89);
+ __Pyx_GIVEREF(__pyx_tuple__89);
/* "src/lxml/extensions.pxi":521
* return ()
* result_list = []
* root = Element(u'matches')
*/
- __pyx_tuple__89 = PyTuple_Pack(1, __pyx_kp_u__15); if (unlikely(!__pyx_tuple__89)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__89);
- __Pyx_GIVEREF(__pyx_tuple__89);
+ __pyx_tuple__90 = PyTuple_Pack(1, __pyx_kp_u__15); if (unlikely(!__pyx_tuple__90)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 521; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__90);
+ __Pyx_GIVEREF(__pyx_tuple__90);
/* "src/lxml/extensions.pxi":523
* results.extend( result.groups(u'') )
* join_groups = u''.join
* for s_match in results:
*/
- __pyx_tuple__90 = PyTuple_Pack(1, __pyx_n_u_matches); if (unlikely(!__pyx_tuple__90)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__90);
- __Pyx_GIVEREF(__pyx_tuple__90);
+ __pyx_tuple__91 = PyTuple_Pack(1, __pyx_n_u_matches); if (unlikely(!__pyx_tuple__91)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 523; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__91);
+ __Pyx_GIVEREF(__pyx_tuple__91);
/* "src/lxml/xpath.pxi":499
* i += 1
* namespace = (<bytes>namespace).decode('utf8')
* namespaces[prefix.decode('utf8')] = namespace
*/
- __pyx_slice__91 = PySlice_New(__pyx_int_1, __pyx_int_neg_1, Py_None); if (unlikely(!__pyx_slice__91)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 499; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_slice__91);
- __Pyx_GIVEREF(__pyx_slice__91);
+ __pyx_slice__92 = PySlice_New(__pyx_int_1, __pyx_int_neg_1, Py_None); if (unlikely(!__pyx_slice__92)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 499; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_slice__92);
+ __Pyx_GIVEREF(__pyx_slice__92);
/* "src/lxml/xpath.pxi":505
* # FIXME: this also replaces {namespaces} within strings!
* path = path_utf.decode('utf8') # <<<<<<<<<<<<<<
* return path, namespaces
*/
- __pyx_tuple__92 = PyTuple_Pack(1, __pyx_n_s_utf8); if (unlikely(!__pyx_tuple__92)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 505; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__92);
- __Pyx_GIVEREF(__pyx_tuple__92);
+ __pyx_tuple__93 = PyTuple_Pack(1, __pyx_n_s_utf8); if (unlikely(!__pyx_tuple__93)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 505; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__93);
+ __Pyx_GIVEREF(__pyx_tuple__93);
/* "src/lxml/xslt.pxi":398
* c_doc._private = <python.PyObject*>self._xslt_resolver_context
* c_style = xslt.xsltParseStylesheetDoc(c_doc)
*
*/
- __pyx_tuple__94 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__94)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__94);
- __Pyx_GIVEREF(__pyx_tuple__94);
+ __pyx_tuple__95 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__95)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__95);
+ __Pyx_GIVEREF(__pyx_tuple__95);
/* "src/lxml/xslt.pxi":465
* """
* xslt.xsltMaxDepth = max_depth
*
*/
- __pyx_tuple__95 = PyTuple_Pack(1, __pyx_kp_s_cannot_set_a_maximum_stylesheet); if (unlikely(!__pyx_tuple__95)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 465; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__95);
- __Pyx_GIVEREF(__pyx_tuple__95);
+ __pyx_tuple__96 = PyTuple_Pack(1, __pyx_kp_s_cannot_set_a_maximum_stylesheet); if (unlikely(!__pyx_tuple__96)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 465; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__96);
+ __Pyx_GIVEREF(__pyx_tuple__96);
- /* "src/lxml/xslt.pxi":844
+ /* "src/lxml/xslt.pxi":846
* global __findStylesheetByID
* if __findStylesheetByID is None:
* __findStylesheetByID = XPath( # <<<<<<<<<<<<<<
* u"//xsl:stylesheet[@xml:id = $id]",
* namespaces={u"xsl" : u"http://www.w3.org/1999/XSL/Transform"})
*/
- __pyx_tuple__96 = PyTuple_Pack(1, __pyx_kp_u_xsl_stylesheet_xml_id_id); if (unlikely(!__pyx_tuple__96)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 844; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__96);
- __Pyx_GIVEREF(__pyx_tuple__96);
+ __pyx_tuple__97 = PyTuple_Pack(1, __pyx_kp_u_xsl_stylesheet_xml_id_id); if (unlikely(!__pyx_tuple__97)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 846; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__97);
+ __Pyx_GIVEREF(__pyx_tuple__97);
/* "src/lxml/xsltext.pxi":225
* e = unicode(e).encode(u"UTF-8")
* message = python.PyBytes_FromFormat(
* "Error executing extension element '%s': %s",
*/
- __pyx_tuple__97 = PyTuple_Pack(1, __pyx_kp_u_UTF_8); if (unlikely(!__pyx_tuple__97)) {__pyx_filename = __pyx_f[19]; __pyx_lineno = 225; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__97);
- __Pyx_GIVEREF(__pyx_tuple__97);
+ __pyx_tuple__98 = PyTuple_Pack(1, __pyx_kp_u_UTF_8); if (unlikely(!__pyx_tuple__98)) {__pyx_filename = __pyx_f[19]; __pyx_lineno = 225; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__98);
+ __Pyx_GIVEREF(__pyx_tuple__98);
/* "src/lxml/dtd.pxi":281
* if _isString(file):
* self._c_dtd = xmlparser.xmlParseDTD(NULL, _xcstr(file))
* elif hasattr(file, 'read'):
*/
- __pyx_tuple__98 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__98)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 281; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__98);
- __Pyx_GIVEREF(__pyx_tuple__98);
+ __pyx_tuple__99 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__99)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 281; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__99);
+ __Pyx_GIVEREF(__pyx_tuple__99);
/* "src/lxml/dtd.pxi":288
* raise DTDParseError, u"file must be a filename or file-like object"
* self._c_dtd = xmlparser.xmlParseDTD(<const_xmlChar*>external_id, NULL)
* else:
*/
- __pyx_tuple__99 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__99)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 288; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__99);
- __Pyx_GIVEREF(__pyx_tuple__99);
+ __pyx_tuple__100 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__100)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 288; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__100);
+ __Pyx_GIVEREF(__pyx_tuple__100);
/* "src/lxml/dtd.pxi":364
* valid_ctxt = dtdvalid.xmlNewValidCtxt()
*
* # work around error reporting bug in libxml2 <= 2.9.1 (and later?)
*/
- __pyx_tuple__100 = PyTuple_Pack(1, __pyx_kp_u_Failed_to_create_validation_cont); if (unlikely(!__pyx_tuple__100)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__100);
- __Pyx_GIVEREF(__pyx_tuple__100);
+ __pyx_tuple__101 = PyTuple_Pack(1, __pyx_kp_u_Failed_to_create_validation_cont); if (unlikely(!__pyx_tuple__101)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 364; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__101);
+ __Pyx_GIVEREF(__pyx_tuple__101);
/* "src/lxml/dtd.pxi":372
*
* c_doc = _fakeRootDoc(doc._c_doc, root_node._c_node)
* ret = dtdvalid.xmlValidateDtd(valid_ctxt, c_doc, self._c_dtd)
*/
- __pyx_tuple__101 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__101)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 372; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__101);
- __Pyx_GIVEREF(__pyx_tuple__101);
+ __pyx_tuple__102 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__102)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 372; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__102);
+ __Pyx_GIVEREF(__pyx_tuple__102);
/* "src/lxml/dtd.pxi":394
* error_log = _ErrorLog()
* c_dtd = dtd_parser._readDtd()
*
*/
- __pyx_tuple__102 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__102)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 394; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__102);
- __Pyx_GIVEREF(__pyx_tuple__102);
+ __pyx_tuple__103 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__103)) {__pyx_filename = __pyx_f[20]; __pyx_lineno = 394; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__103);
+ __Pyx_GIVEREF(__pyx_tuple__103);
/* "src/lxml/relaxng.pxi":51
* doc = None
* parser_ctxt = relaxng.xmlRelaxNGNewParserCtxt(_cstr(filename))
* else:
*/
- __pyx_tuple__103 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__103)) {__pyx_filename = __pyx_f[21]; __pyx_lineno = 51; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__103);
- __Pyx_GIVEREF(__pyx_tuple__103);
+ __pyx_tuple__104 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__104)) {__pyx_filename = __pyx_f[21]; __pyx_lineno = 51; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__104);
+ __Pyx_GIVEREF(__pyx_tuple__104);
/* "src/lxml/schematron.pxi":98
* filename = file
* parser_ctxt = schematron.xmlSchematronNewParserCtxt(_cstr(filename))
* else:
*/
- __pyx_tuple__104 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__104)) {__pyx_filename = __pyx_f[23]; __pyx_lineno = 98; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__104);
- __Pyx_GIVEREF(__pyx_tuple__104);
+ __pyx_tuple__105 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__105)) {__pyx_filename = __pyx_f[23]; __pyx_lineno = 98; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__105);
+ __Pyx_GIVEREF(__pyx_tuple__105);
/* "src/lxml/schematron.pxi":110
*
* self._c_schema = schematron.xmlSchematronParse(parser_ctxt)
* finally:
*/
- __pyx_tuple__105 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__105)) {__pyx_filename = __pyx_f[23]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__105);
- __Pyx_GIVEREF(__pyx_tuple__105);
+ __pyx_tuple__106 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__106)) {__pyx_filename = __pyx_f[23]; __pyx_lineno = 110; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__106);
+ __Pyx_GIVEREF(__pyx_tuple__106);
/* "src/lxml/lxml.etree.pyx":103
*
* raise KeyError, key
*
*/
- __pyx_tuple__106 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_key); if (unlikely(!__pyx_tuple__106)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__106);
- __Pyx_GIVEREF(__pyx_tuple__106);
- __pyx_codeobj__107 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__106, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_getitem, 103, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__107)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__107 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_key); if (unlikely(!__pyx_tuple__107)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__107);
+ __Pyx_GIVEREF(__pyx_tuple__107);
+ __pyx_codeobj__108 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__107, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_getitem, 103, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__108)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/lxml.etree.pyx":106
* raise KeyError, key
* raise KeyError, key
*
*/
- __pyx_tuple__108 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_key, __pyx_n_s_value); if (unlikely(!__pyx_tuple__108)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__108);
- __Pyx_GIVEREF(__pyx_tuple__108);
- __pyx_codeobj__109 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__108, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_setitem, 106, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__109)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__109 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_key, __pyx_n_s_value); if (unlikely(!__pyx_tuple__109)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__109);
+ __Pyx_GIVEREF(__pyx_tuple__109);
+ __pyx_codeobj__110 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__109, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_setitem, 106, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__110)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/lxml.etree.pyx":109
* raise KeyError, key
* raise KeyError, key
*
*/
- __pyx_tuple__110 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_key); if (unlikely(!__pyx_tuple__110)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__110);
- __Pyx_GIVEREF(__pyx_tuple__110);
- __pyx_codeobj__111 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__110, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_delitem, 109, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__111)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__111 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_key); if (unlikely(!__pyx_tuple__111)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__111);
+ __Pyx_GIVEREF(__pyx_tuple__111);
+ __pyx_codeobj__112 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__111, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_delitem, 109, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__112)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/lxml.etree.pyx":112
* raise KeyError, key
* return False
*
*/
- __pyx_tuple__112 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_key); if (unlikely(!__pyx_tuple__112)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__112);
- __Pyx_GIVEREF(__pyx_tuple__112);
- __pyx_codeobj__113 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__112, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_contains, 112, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__113)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__113 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_key); if (unlikely(!__pyx_tuple__113)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__113);
+ __Pyx_GIVEREF(__pyx_tuple__113);
+ __pyx_codeobj__114 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__113, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_contains, 112, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__114)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/lxml.etree.pyx":115
* return False
* return 0
*
*/
- __pyx_tuple__114 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__114)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__114);
- __Pyx_GIVEREF(__pyx_tuple__114);
- __pyx_codeobj__115 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__114, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_len, 115, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__115)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__115 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__115)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__115);
+ __Pyx_GIVEREF(__pyx_tuple__115);
+ __pyx_codeobj__116 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__115, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_len, 115, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__116)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/lxml.etree.pyx":118
* return 0
* return ITER_EMPTY
* iterkeys = itervalues = iteritems = __iter__
*/
- __pyx_tuple__116 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__116)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__116);
- __Pyx_GIVEREF(__pyx_tuple__116);
- __pyx_codeobj__117 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__116, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_iter_2, 118, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__117)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__117 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__117)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__117);
+ __Pyx_GIVEREF(__pyx_tuple__117);
+ __pyx_codeobj__118 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__117, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_iter_2, 118, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__118)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/lxml.etree.pyx":161
*
* cdef char* _C_FILENAME_ENCODING = _cstr(_FILENAME_ENCODING)
*
*/
- __pyx_tuple__118 = PyTuple_Pack(1, __pyx_kp_u_UTF_8); if (unlikely(!__pyx_tuple__118)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__118);
- __Pyx_GIVEREF(__pyx_tuple__118);
+ __pyx_tuple__119 = PyTuple_Pack(1, __pyx_kp_u_UTF_8); if (unlikely(!__pyx_tuple__119)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__119);
+ __Pyx_GIVEREF(__pyx_tuple__119);
/* "src/lxml/lxml.etree.pyx":180
* }
*
* def register_namespace(prefix, uri):
*/
- __pyx_tuple__119 = PyTuple_Pack(1, __pyx_kp_b_ns_d_2); if (unlikely(!__pyx_tuple__119)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__119);
- __Pyx_GIVEREF(__pyx_tuple__119);
+ __pyx_tuple__120 = PyTuple_Pack(1, __pyx_kp_b_ns_d_2); if (unlikely(!__pyx_tuple__120)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__120);
+ __Pyx_GIVEREF(__pyx_tuple__120);
/* "src/lxml/lxml.etree.pyx":182
* cdef object _check_internal_prefix = re.compile(b"ns\d+$").match
* u"""Registers a namespace prefix that newly created Elements in that
* namespace will use. The registry is global, and any existing
*/
- __pyx_tuple__120 = PyTuple_Pack(6, __pyx_n_s_prefix, __pyx_n_s_uri, __pyx_n_s_prefix_utf, __pyx_n_s_uri_utf, __pyx_n_s_k, __pyx_n_s_v); if (unlikely(!__pyx_tuple__120)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__120);
- __Pyx_GIVEREF(__pyx_tuple__120);
- __pyx_codeobj__121 = (PyObject*)__Pyx_PyCode_New(2, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__120, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_register_namespace, 182, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__121)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__121 = PyTuple_Pack(6, __pyx_n_s_prefix, __pyx_n_s_uri, __pyx_n_s_prefix_utf, __pyx_n_s_uri_utf, __pyx_n_s_k, __pyx_n_s_v); if (unlikely(!__pyx_tuple__121)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__121);
+ __Pyx_GIVEREF(__pyx_tuple__121);
+ __pyx_codeobj__122 = (PyObject*)__Pyx_PyCode_New(2, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__121, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_register_namespace, 182, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__122)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 182; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/lxml.etree.pyx":208
* this one.
* super(_Error, self).__init__(message)
* if error_log is None:
*/
- __pyx_tuple__122 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_message, __pyx_n_s_error_log); if (unlikely(!__pyx_tuple__122)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__122);
- __Pyx_GIVEREF(__pyx_tuple__122);
- __pyx_codeobj__123 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__122, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_init, 208, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__123)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_tuple__124 = PyTuple_Pack(1, ((PyObject *)Py_None)); if (unlikely(!__pyx_tuple__124)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__124);
- __Pyx_GIVEREF(__pyx_tuple__124);
+ __pyx_tuple__123 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_message, __pyx_n_s_error_log); if (unlikely(!__pyx_tuple__123)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__123);
+ __Pyx_GIVEREF(__pyx_tuple__123);
+ __pyx_codeobj__124 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__123, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_init, 208, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__124)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__125 = PyTuple_Pack(1, ((PyObject *)Py_None)); if (unlikely(!__pyx_tuple__125)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__125);
+ __Pyx_GIVEREF(__pyx_tuple__125);
/* "src/lxml/lxml.etree.pyx":263
* try:
* except Exception:
* print u"Unknown libxml2 version: %s" % (<unsigned char*>tree.xmlParserVersion).decode("ascii")
*/
- __pyx_tuple__125 = PyTuple_Pack(1, __pyx_int_0); if (unlikely(!__pyx_tuple__125)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 263; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__125);
- __Pyx_GIVEREF(__pyx_tuple__125);
+ __pyx_tuple__126 = PyTuple_Pack(1, __pyx_int_0); if (unlikely(!__pyx_tuple__126)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 263; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__126);
+ __Pyx_GIVEREF(__pyx_tuple__126);
/* "src/lxml/xmlerror.pxi":8
* # module level API functions
* u"""clear_error_log()
*
*/
- __pyx_codeobj__126 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_2, __pyx_n_s_clear_error_log_2, 8, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__126)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 8; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_codeobj__127 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_2, __pyx_n_s_clear_error_log_2, 8, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__127)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 8; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xmlerror.pxi":545
*
*
* cdef _BaseErrorLog _getGlobalErrorLog():
*/
- __pyx_tuple__127 = PyTuple_Pack(1, __pyx_int_100); if (unlikely(!__pyx_tuple__127)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__127);
- __Pyx_GIVEREF(__pyx_tuple__127);
+ __pyx_tuple__128 = PyTuple_Pack(1, __pyx_int_100); if (unlikely(!__pyx_tuple__128)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__128);
+ __Pyx_GIVEREF(__pyx_tuple__128);
/* "src/lxml/xmlerror.pxi":574
* return _getGlobalErrorLog().copy()
* u"""use_global_python_log(log)
*
*/
- __pyx_tuple__128 = PyTuple_Pack(1, __pyx_n_s_log); if (unlikely(!__pyx_tuple__128)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__128);
- __Pyx_GIVEREF(__pyx_tuple__128);
- __pyx_codeobj__129 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__128, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_2, __pyx_n_s_use_global_python_log, 574, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__129)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__129 = PyTuple_Pack(1, __pyx_n_s_log); if (unlikely(!__pyx_tuple__129)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__129);
+ __Pyx_GIVEREF(__pyx_tuple__129);
+ __pyx_codeobj__130 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__129, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_2, __pyx_n_s_use_global_python_log, 574, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__130)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 574; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xmlerror.pxi":739
* # cannot handle strings that are a few thousand bytes in length.
* NONE=0
* WARNING=1
*/
- __pyx_tuple__130 = PyTuple_Pack(1, __pyx_kp_u_NONE_0_WARNING_1_ERROR_2_FATAL_3); if (unlikely(!__pyx_tuple__130)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__130);
- __Pyx_GIVEREF(__pyx_tuple__130);
+ __pyx_tuple__131 = PyTuple_Pack(1, __pyx_kp_u_NONE_0_WARNING_1_ERROR_2_FATAL_3); if (unlikely(!__pyx_tuple__131)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__131);
+ __Pyx_GIVEREF(__pyx_tuple__131);
/* "src/lxml/xmlerror.pxi":746
* """,)
* NONE=0
* PARSER=1
*/
- __pyx_tuple__131 = PyTuple_Pack(1, __pyx_kp_u_NONE_0_PARSER_1_TREE_2_NAMESPACE); if (unlikely(!__pyx_tuple__131)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__131);
- __Pyx_GIVEREF(__pyx_tuple__131);
+ __pyx_tuple__132 = PyTuple_Pack(1, __pyx_kp_u_NONE_0_PARSER_1_TREE_2_NAMESPACE); if (unlikely(!__pyx_tuple__132)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__132);
+ __Pyx_GIVEREF(__pyx_tuple__132);
/* "src/lxml/xmlerror.pxi":780
* """,)
* ERR_OK=0
* ERR_INTERNAL_ERROR=1
*/
- __pyx_tuple__132 = PyTuple_Pack(11, __pyx_kp_u_ERR_OK_0_ERR_INTERNAL_ERROR_1_ER, __pyx_kp_u_ERR_ENCODING_NAME_79_ERR_HYPHEN, __pyx_kp_u_RNGP_ATTRIBUTE_CONTENT_1003_RNGP, __pyx_kp_u_RNGP_PAT_DATA_EXCEPT_ONEMORE_107, __pyx_kp_u_TREE_NOT_UTF8_1303_SAVE_NOT_UTF8, __pyx_kp_u_SCHEMAP_EXTENSION_NO_BASE_1707_S, __pyx_kp_u_SCHEMAP_DEF_AND_PREFIX_1768_SCHE, __pyx_kp_u_SCHEMAV_CVC_MINLENGTH_VALID_1831, __pyx_kp_u_SCHEMAP_SRC_RESOLVE_3004_SCHEMAP, __pyx_kp_u_SCHEMAP_CVC_SIMPLE_TYPE_3062_SCH, __pyx_kp_u_I18N_NO_OUTPUT_6004_BUF_OVERFLOW); if (unlikely(!__pyx_tuple__132)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__132);
- __Pyx_GIVEREF(__pyx_tuple__132);
+ __pyx_tuple__133 = PyTuple_Pack(11, __pyx_kp_u_ERR_OK_0_ERR_INTERNAL_ERROR_1_ER, __pyx_kp_u_ERR_ENCODING_NAME_79_ERR_HYPHEN, __pyx_kp_u_RNGP_ATTRIBUTE_CONTENT_1003_RNGP, __pyx_kp_u_RNGP_PAT_DATA_EXCEPT_ONEMORE_107, __pyx_kp_u_TREE_NOT_UTF8_1303_SAVE_NOT_UTF8, __pyx_kp_u_SCHEMAP_EXTENSION_NO_BASE_1707_S, __pyx_kp_u_SCHEMAP_DEF_AND_PREFIX_1768_SCHE, __pyx_kp_u_SCHEMAV_CVC_MINLENGTH_VALID_1831, __pyx_kp_u_SCHEMAP_SRC_RESOLVE_3004_SCHEMAP, __pyx_kp_u_SCHEMAP_CVC_SIMPLE_TYPE_3062_SCH, __pyx_kp_u_I18N_NO_OUTPUT_6004_BUF_OVERFLOW); if (unlikely(!__pyx_tuple__133)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 780; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__133);
+ __Pyx_GIVEREF(__pyx_tuple__133);
/* "src/lxml/xmlerror.pxi":1537
* """,)
* RELAXNG_OK=0
* RELAXNG_ERR_MEMORY=1
*/
- __pyx_tuple__133 = PyTuple_Pack(1, __pyx_kp_u_RELAXNG_OK_0_RELAXNG_ERR_MEMORY); if (unlikely(!__pyx_tuple__133)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 1537; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__133);
- __Pyx_GIVEREF(__pyx_tuple__133);
+ __pyx_tuple__134 = PyTuple_Pack(1, __pyx_kp_u_RELAXNG_OK_0_RELAXNG_ERR_MEMORY); if (unlikely(!__pyx_tuple__134)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 1537; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__134);
+ __Pyx_GIVEREF(__pyx_tuple__134);
- /* "src/lxml/lxml.etree.pyx":2893
+ /* "src/lxml/lxml.etree.pyx":2902
* # module-level API for ElementTree
*
* def Element(_tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
* u"""Element(_tag, attrib=None, nsmap=None, **_extra)
*
*/
- __pyx_tuple__134 = PyTuple_Pack(4, __pyx_n_s_tag_2, __pyx_n_s_attrib, __pyx_n_s_nsmap, __pyx_n_s_extra); if (unlikely(!__pyx_tuple__134)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__134);
- __Pyx_GIVEREF(__pyx_tuple__134);
- __pyx_codeobj__135 = (PyObject*)__Pyx_PyCode_New(3, 0, 4, 0, CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__134, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_Element, 2893, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__135)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__135 = PyTuple_Pack(4, __pyx_n_s_tag_2, __pyx_n_s_attrib, __pyx_n_s_nsmap, __pyx_n_s_extra); if (unlikely(!__pyx_tuple__135)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__135);
+ __Pyx_GIVEREF(__pyx_tuple__135);
+ __pyx_codeobj__136 = (PyObject*)__Pyx_PyCode_New(3, 0, 4, 0, CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__135, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_Element, 2902, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__136)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2906
+ /* "src/lxml/lxml.etree.pyx":2915
* attrib, nsmap, _extra)
*
* def Comment(text=None): # <<<<<<<<<<<<<<
* u"""Comment(text=None)
*
*/
- __pyx_tuple__136 = PyTuple_Pack(4, __pyx_n_s_text, __pyx_n_s_doc_2, __pyx_n_s_c_node, __pyx_n_s_c_doc); if (unlikely(!__pyx_tuple__136)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2906; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__136);
- __Pyx_GIVEREF(__pyx_tuple__136);
- __pyx_codeobj__137 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__136, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_Comment, 2906, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__137)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2906; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__137 = PyTuple_Pack(4, __pyx_n_s_text, __pyx_n_s_doc_2, __pyx_n_s_c_node, __pyx_n_s_c_doc); if (unlikely(!__pyx_tuple__137)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__137);
+ __Pyx_GIVEREF(__pyx_tuple__137);
+ __pyx_codeobj__138 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__137, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_Comment, 2915, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__138)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2925
+ /* "src/lxml/lxml.etree.pyx":2934
* return _elementFactory(doc, c_node)
*
* def ProcessingInstruction(target, text=None): # <<<<<<<<<<<<<<
* u"""ProcessingInstruction(target, text=None)
*
*/
- __pyx_tuple__138 = PyTuple_Pack(5, __pyx_n_s_target, __pyx_n_s_text, __pyx_n_s_doc_2, __pyx_n_s_c_node, __pyx_n_s_c_doc); if (unlikely(!__pyx_tuple__138)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__138);
- __Pyx_GIVEREF(__pyx_tuple__138);
- __pyx_codeobj__139 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__138, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_ProcessingInstruction, 2925, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__139)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__139 = PyTuple_Pack(5, __pyx_n_s_target, __pyx_n_s_text, __pyx_n_s_doc_2, __pyx_n_s_c_node, __pyx_n_s_c_doc); if (unlikely(!__pyx_tuple__139)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2934; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__139);
+ __Pyx_GIVEREF(__pyx_tuple__139);
+ __pyx_codeobj__140 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__139, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_ProcessingInstruction, 2934, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__140)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2934; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2965
+ /* "src/lxml/lxml.etree.pyx":2974
* self._utf8_data = _utf8(data)
*
* def Entity(name): # <<<<<<<<<<<<<<
* u"""Entity(name)
*
*/
- __pyx_tuple__140 = PyTuple_Pack(6, __pyx_n_s_name_2, __pyx_n_s_doc_2, __pyx_n_s_c_node, __pyx_n_s_c_doc, __pyx_n_s_name_utf, __pyx_n_s_c_name); if (unlikely(!__pyx_tuple__140)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__140);
- __Pyx_GIVEREF(__pyx_tuple__140);
- __pyx_codeobj__141 = (PyObject*)__Pyx_PyCode_New(1, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__140, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_Entity, 2965, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__141)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__141 = PyTuple_Pack(6, __pyx_n_s_name_2, __pyx_n_s_doc_2, __pyx_n_s_c_node, __pyx_n_s_c_doc, __pyx_n_s_name_utf, __pyx_n_s_c_name); if (unlikely(!__pyx_tuple__141)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2974; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__141);
+ __Pyx_GIVEREF(__pyx_tuple__141);
+ __pyx_codeobj__142 = (PyObject*)__Pyx_PyCode_New(1, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__141, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_Entity, 2974, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__142)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2974; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2990
+ /* "src/lxml/lxml.etree.pyx":2999
* return _elementFactory(doc, c_node)
*
* def SubElement(_Element _parent not None, _tag, # <<<<<<<<<<<<<<
* attrib=None, nsmap=None, **_extra):
* u"""SubElement(_parent, _tag, attrib=None, nsmap=None, **_extra)
*/
- __pyx_tuple__142 = PyTuple_Pack(5, __pyx_n_s_parent, __pyx_n_s_tag_2, __pyx_n_s_attrib, __pyx_n_s_nsmap, __pyx_n_s_extra); if (unlikely(!__pyx_tuple__142)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__142);
- __Pyx_GIVEREF(__pyx_tuple__142);
- __pyx_codeobj__143 = (PyObject*)__Pyx_PyCode_New(4, 0, 5, 0, CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__142, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_SubElement, 2990, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__143)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__143 = PyTuple_Pack(5, __pyx_n_s_parent, __pyx_n_s_tag_2, __pyx_n_s_attrib, __pyx_n_s_nsmap, __pyx_n_s_extra); if (unlikely(!__pyx_tuple__143)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__143);
+ __Pyx_GIVEREF(__pyx_tuple__143);
+ __pyx_codeobj__144 = (PyObject*)__Pyx_PyCode_New(4, 0, 5, 0, CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__143, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_SubElement, 2999, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__144)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":2999
+ /* "src/lxml/lxml.etree.pyx":3008
* return _makeSubElement(_parent, _tag, None, None, attrib, nsmap, _extra)
*
* def ElementTree(_Element element=None, *, file=None, _BaseParser parser=None): # <<<<<<<<<<<<<<
* u"""ElementTree(element=None, file=None, parser=None)
*
*/
- __pyx_tuple__144 = PyTuple_Pack(10, __pyx_n_s_element, __pyx_n_s_file, __pyx_n_s_parser, __pyx_n_s_c_next, __pyx_n_s_c_node, __pyx_n_s_c_node_copy, __pyx_n_s_c_doc, __pyx_n_s_etree, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__144)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__144);
- __Pyx_GIVEREF(__pyx_tuple__144);
- __pyx_codeobj__145 = (PyObject*)__Pyx_PyCode_New(1, 2, 10, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__144, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_ElementTree, 2999, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__145)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__145 = PyTuple_Pack(10, __pyx_n_s_element, __pyx_n_s_file, __pyx_n_s_parser, __pyx_n_s_c_next, __pyx_n_s_c_node, __pyx_n_s_c_node_copy, __pyx_n_s_c_doc, __pyx_n_s_etree, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__145)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__145);
+ __Pyx_GIVEREF(__pyx_tuple__145);
+ __pyx_codeobj__146 = (PyObject*)__Pyx_PyCode_New(1, 2, 10, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__145, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_ElementTree, 3008, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__146)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3024
+ /* "src/lxml/lxml.etree.pyx":3033
* return _elementTreeFactory(doc, element)
*
* def HTML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""HTML(text, parser=None, base_url=None)
*
*/
- __pyx_tuple__146 = PyTuple_Pack(5, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__146)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__146);
- __Pyx_GIVEREF(__pyx_tuple__146);
- __pyx_codeobj__147 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__146, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_HTML, 3024, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__147)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__147 = PyTuple_Pack(5, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__147)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__147);
+ __Pyx_GIVEREF(__pyx_tuple__147);
+ __pyx_codeobj__148 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__147, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_HTML, 3033, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__148)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3049
+ /* "src/lxml/lxml.etree.pyx":3058
* return result_container.result
*
* def XML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""XML(text, parser=None, base_url=None)
*
*/
- __pyx_tuple__148 = PyTuple_Pack(5, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__148)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__148);
- __Pyx_GIVEREF(__pyx_tuple__148);
- __pyx_codeobj__149 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__148, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_XML, 3049, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__149)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__149 = PyTuple_Pack(5, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__149)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3058; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__149);
+ __Pyx_GIVEREF(__pyx_tuple__149);
+ __pyx_codeobj__150 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__149, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_XML, 3058, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__150)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3058; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3079
+ /* "src/lxml/lxml.etree.pyx":3088
* return result_container.result
*
* def fromstring(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""fromstring(text, parser=None, base_url=None)
*
*/
- __pyx_tuple__150 = PyTuple_Pack(5, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__150)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__150);
- __Pyx_GIVEREF(__pyx_tuple__150);
- __pyx_codeobj__151 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__150, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_fromstring, 3079, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__151)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__151 = PyTuple_Pack(5, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__151)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__151);
+ __Pyx_GIVEREF(__pyx_tuple__151);
+ __pyx_codeobj__152 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__151, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_fromstring, 3088, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__152)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3099
+ /* "src/lxml/lxml.etree.pyx":3108
* return result_container.result
*
* def fromstringlist(strings, _BaseParser parser=None): # <<<<<<<<<<<<<<
* u"""fromstringlist(strings, parser=None)
*
*/
- __pyx_tuple__152 = PyTuple_Pack(5, __pyx_n_s_strings, __pyx_n_s_parser, __pyx_n_s_doc_2, __pyx_n_s_feed, __pyx_n_s_data); if (unlikely(!__pyx_tuple__152)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__152);
- __Pyx_GIVEREF(__pyx_tuple__152);
- __pyx_codeobj__153 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__152, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_fromstringlist, 3099, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__153)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__153 = PyTuple_Pack(5, __pyx_n_s_strings, __pyx_n_s_parser, __pyx_n_s_doc_2, __pyx_n_s_feed, __pyx_n_s_data); if (unlikely(!__pyx_tuple__153)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__153);
+ __Pyx_GIVEREF(__pyx_tuple__153);
+ __pyx_codeobj__154 = (PyObject*)__Pyx_PyCode_New(2, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__153, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_fromstringlist, 3108, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__154)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3119
+ /* "src/lxml/lxml.etree.pyx":3128
* return parser.close()
*
* def iselement(element): # <<<<<<<<<<<<<<
* u"""iselement(element)
*
*/
- __pyx_tuple__154 = PyTuple_Pack(1, __pyx_n_s_element); if (unlikely(!__pyx_tuple__154)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__154);
- __Pyx_GIVEREF(__pyx_tuple__154);
- __pyx_codeobj__155 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__154, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_iselement, 3119, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__155)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__155 = PyTuple_Pack(1, __pyx_n_s_element); if (unlikely(!__pyx_tuple__155)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__155);
+ __Pyx_GIVEREF(__pyx_tuple__155);
+ __pyx_codeobj__156 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__155, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_iselement, 3128, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__156)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3126
+ /* "src/lxml/lxml.etree.pyx":3135
* return isinstance(element, _Element) and (<_Element>element)._c_node is not NULL
*
* def dump(_Element elem not None, *, bint pretty_print=True, with_tail=True): # <<<<<<<<<<<<<<
* u"""dump(elem, pretty_print=True, with_tail=True)
*
*/
- __pyx_tuple__156 = PyTuple_Pack(4, __pyx_n_s_elem, __pyx_n_s_pretty_print, __pyx_n_s_with_tail, __pyx_n_s_xml); if (unlikely(!__pyx_tuple__156)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__156);
- __Pyx_GIVEREF(__pyx_tuple__156);
- __pyx_codeobj__157 = (PyObject*)__Pyx_PyCode_New(1, 2, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__156, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_dump, 3126, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__157)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__157 = PyTuple_Pack(4, __pyx_n_s_elem, __pyx_n_s_pretty_print, __pyx_n_s_with_tail, __pyx_n_s_xml); if (unlikely(!__pyx_tuple__157)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__157);
+ __Pyx_GIVEREF(__pyx_tuple__157);
+ __pyx_codeobj__158 = (PyObject*)__Pyx_PyCode_New(1, 2, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__157, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_dump, 3135, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__158)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3138
+ /* "src/lxml/lxml.etree.pyx":3147
* sys.stdout.write(xml)
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
* xml_declaration=None, bint pretty_print=False, bint with_tail=True,
* standalone=None, doctype=None,
*/
- __pyx_tuple__158 = PyTuple_Pack(13, __pyx_n_s_element_or_tree, __pyx_n_s_encoding, __pyx_n_s_method, __pyx_n_s_xml_declaration, __pyx_n_s_pretty_print, __pyx_n_s_with_tail, __pyx_n_s_standalone, __pyx_n_s_doctype, __pyx_n_s_exclusive, __pyx_n_s_with_comments, __pyx_n_s_inclusive_ns_prefixes, __pyx_n_s_write_declaration, __pyx_n_s_is_standalone); if (unlikely(!__pyx_tuple__158)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3138; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__158);
- __Pyx_GIVEREF(__pyx_tuple__158);
- __pyx_codeobj__159 = (PyObject*)__Pyx_PyCode_New(1, 10, 13, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__158, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_tostring, 3138, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__159)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3138; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__159 = PyTuple_Pack(13, __pyx_n_s_element_or_tree, __pyx_n_s_encoding, __pyx_n_s_method, __pyx_n_s_xml_declaration, __pyx_n_s_pretty_print, __pyx_n_s_with_tail, __pyx_n_s_standalone, __pyx_n_s_doctype, __pyx_n_s_exclusive, __pyx_n_s_with_comments, __pyx_n_s_inclusive_ns_prefixes, __pyx_n_s_write_declaration, __pyx_n_s_is_standalone); if (unlikely(!__pyx_tuple__159)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__159);
+ __Pyx_GIVEREF(__pyx_tuple__159);
+ __pyx_codeobj__160 = (PyObject*)__Pyx_PyCode_New(1, 10, 13, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__159, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_tostring, 3147, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__160)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3230
+ /* "src/lxml/lxml.etree.pyx":3239
* python._fqtypename(element_or_tree).decode('utf8')
*
* def tostringlist(element_or_tree, *args, **kwargs): # <<<<<<<<<<<<<<
* u"""tostringlist(element_or_tree, *args, **kwargs)
*
*/
- __pyx_tuple__160 = PyTuple_Pack(3, __pyx_n_s_element_or_tree, __pyx_n_s_args, __pyx_n_s_kwargs); if (unlikely(!__pyx_tuple__160)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__160);
- __Pyx_GIVEREF(__pyx_tuple__160);
- __pyx_codeobj__161 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_VARARGS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__160, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_tostringlist, 3230, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__161)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__161 = PyTuple_Pack(3, __pyx_n_s_element_or_tree, __pyx_n_s_args, __pyx_n_s_kwargs); if (unlikely(!__pyx_tuple__161)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__161);
+ __Pyx_GIVEREF(__pyx_tuple__161);
+ __pyx_codeobj__162 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, CO_VARARGS|CO_VARKEYWORDS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__161, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_tostringlist, 3239, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__162)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3241
+ /* "src/lxml/lxml.etree.pyx":3250
* return [tostring(element_or_tree, *args, **kwargs)]
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False, # <<<<<<<<<<<<<<
* bint with_tail=True, doctype=None):
* u"""tounicode(element_or_tree, method="xml", pretty_print=False,
*/
- __pyx_tuple__162 = PyTuple_Pack(5, __pyx_n_s_element_or_tree, __pyx_n_s_method, __pyx_n_s_pretty_print, __pyx_n_s_with_tail, __pyx_n_s_doctype); if (unlikely(!__pyx_tuple__162)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__162);
- __Pyx_GIVEREF(__pyx_tuple__162);
- __pyx_codeobj__163 = (PyObject*)__Pyx_PyCode_New(1, 4, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__162, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_tounicode, 3241, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__163)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__163 = PyTuple_Pack(5, __pyx_n_s_element_or_tree, __pyx_n_s_method, __pyx_n_s_pretty_print, __pyx_n_s_with_tail, __pyx_n_s_doctype); if (unlikely(!__pyx_tuple__163)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3250; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__163);
+ __Pyx_GIVEREF(__pyx_tuple__163);
+ __pyx_codeobj__164 = (PyObject*)__Pyx_PyCode_New(1, 4, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__163, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_tounicode, 3250, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__164)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3250; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/lxml.etree.pyx":3275
+ /* "src/lxml/lxml.etree.pyx":3284
* type(element_or_tree)
*
* def parse(source, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""parse(source, parser=None, base_url=None)
*
*/
- __pyx_tuple__164 = PyTuple_Pack(5, __pyx_n_s_source, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__164)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3275; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__164);
- __Pyx_GIVEREF(__pyx_tuple__164);
- __pyx_codeobj__165 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__164, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_parse, 3275, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__165)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3275; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__165 = PyTuple_Pack(5, __pyx_n_s_source, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2, __pyx_n_s_result_container); if (unlikely(!__pyx_tuple__165)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3284; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__165);
+ __Pyx_GIVEREF(__pyx_tuple__165);
+ __pyx_codeobj__166 = (PyObject*)__Pyx_PyCode_New(2, 1, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__165, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml, __pyx_n_s_parse, 3284, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__166)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3284; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/classlookup.pxi":551
* LOOKUP_ELEMENT_CLASS = function
* u"""set_element_class_lookup(lookup = None)
*
*/
- __pyx_tuple__166 = PyTuple_Pack(1, __pyx_n_s_lookup); if (unlikely(!__pyx_tuple__166)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 551; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__166);
- __Pyx_GIVEREF(__pyx_tuple__166);
- __pyx_codeobj__167 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__166, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_3, __pyx_n_s_set_element_class_lookup, 551, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__167)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 551; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__167 = PyTuple_Pack(1, __pyx_n_s_lookup); if (unlikely(!__pyx_tuple__167)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 551; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__167);
+ __Pyx_GIVEREF(__pyx_tuple__167);
+ __pyx_codeobj__168 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__167, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_3, __pyx_n_s_set_element_class_lookup, 551, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__168)) {__pyx_filename = __pyx_f[9]; __pyx_lineno = 551; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/nsclasses.pxi":175
* __FUNCTION_NAMESPACE_REGISTRIES = {}
* u"""FunctionNamespace(ns_uri)
*
*/
- __pyx_tuple__168 = PyTuple_Pack(3, __pyx_n_s_ns_uri, __pyx_n_s_ns_utf, __pyx_n_s_registry); if (unlikely(!__pyx_tuple__168)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__168);
- __Pyx_GIVEREF(__pyx_tuple__168);
- __pyx_codeobj__169 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__168, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_4, __pyx_n_s_FunctionNamespace, 175, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__169)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__169 = PyTuple_Pack(3, __pyx_n_s_ns_uri, __pyx_n_s_ns_utf, __pyx_n_s_registry); if (unlikely(!__pyx_tuple__169)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__169);
+ __Pyx_GIVEREF(__pyx_tuple__169);
+ __pyx_codeobj__170 = (PyObject*)__Pyx_PyCode_New(1, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__169, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_4, __pyx_n_s_FunctionNamespace, 175, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__170)) {__pyx_filename = __pyx_f[10]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/parser.pxi":18
* For compatibility with ElementTree 1.3 and later.
* super(_ParseError, self).__init__(message)
* self.position = (line, column)
*/
- __pyx_tuple__170 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_message, __pyx_n_s_code, __pyx_n_s_line, __pyx_n_s_column); if (unlikely(!__pyx_tuple__170)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__170);
- __Pyx_GIVEREF(__pyx_tuple__170);
- __pyx_codeobj__171 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__170, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_5, __pyx_n_s_init, 18, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__171)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__171 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_message, __pyx_n_s_code, __pyx_n_s_line, __pyx_n_s_column); if (unlikely(!__pyx_tuple__171)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__171);
+ __Pyx_GIVEREF(__pyx_tuple__171);
+ __pyx_codeobj__172 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__171, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_5, __pyx_n_s_init, 18, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__172)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/parser.pxi":1562
* __GLOBAL_PARSER_CONTEXT.setDefaultParser(__DEFAULT_XML_PARSER)
* u"""set_default_parser(parser=None)
*
*/
- __pyx_tuple__172 = PyTuple_Pack(1, __pyx_n_s_parser); if (unlikely(!__pyx_tuple__172)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1562; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__172);
- __Pyx_GIVEREF(__pyx_tuple__172);
- __pyx_codeobj__173 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__172, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_5, __pyx_n_s_set_default_parser, 1562, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__173)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1562; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__173 = PyTuple_Pack(1, __pyx_n_s_parser); if (unlikely(!__pyx_tuple__173)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1562; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__173);
+ __Pyx_GIVEREF(__pyx_tuple__173);
+ __pyx_codeobj__174 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__173, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_5, __pyx_n_s_set_default_parser, 1562, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__174)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1562; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/parser.pxi":1578
* __GLOBAL_PARSER_CONTEXT.setDefaultParser(parser)
* u"get_default_parser()"
* return __GLOBAL_PARSER_CONTEXT.getDefaultParser()
*/
- __pyx_codeobj__174 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_5, __pyx_n_s_get_default_parser, 1578, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__174)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1578; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_codeobj__175 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_5, __pyx_n_s_get_default_parser, 1578, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__175)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 1578; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/saxparser.pxi":468
*
*
*
*/
- __pyx_tuple__175 = PyTuple_Pack(2, __pyx_kp_s_end_ns, Py_None); if (unlikely(!__pyx_tuple__175)) {__pyx_filename = __pyx_f[12]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__175);
- __Pyx_GIVEREF(__pyx_tuple__175);
+ __pyx_tuple__176 = PyTuple_Pack(2, __pyx_kp_s_end_ns, Py_None); if (unlikely(!__pyx_tuple__176)) {__pyx_filename = __pyx_f[12]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__176);
+ __Pyx_GIVEREF(__pyx_tuple__176);
/* "src/lxml/parsertarget.pxi":10
* # to push the Python level parser result through the parser
* self.result = result
*
*/
- __pyx_tuple__176 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_result); if (unlikely(!__pyx_tuple__176)) {__pyx_filename = __pyx_f[13]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__176);
- __Pyx_GIVEREF(__pyx_tuple__176);
- __pyx_codeobj__177 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__176, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_6, __pyx_n_s_init, 10, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__177)) {__pyx_filename = __pyx_f[13]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__177 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_result); if (unlikely(!__pyx_tuple__177)) {__pyx_filename = __pyx_f[13]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__177);
+ __Pyx_GIVEREF(__pyx_tuple__177);
+ __pyx_codeobj__178 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__177, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_6, __pyx_n_s_init, 10, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__178)) {__pyx_filename = __pyx_f[13]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xmlid.pxi":3
* cdef object _find_id_attributes
* u"""XMLID(text, parser=None, base_url=None)
*
*/
- __pyx_tuple__178 = PyTuple_Pack(6, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_dic, __pyx_n_s_root, __pyx_n_s_elem); if (unlikely(!__pyx_tuple__178)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__178);
- __Pyx_GIVEREF(__pyx_tuple__178);
- __pyx_codeobj__179 = (PyObject*)__Pyx_PyCode_New(2, 1, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__178, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_7, __pyx_n_s_XMLID, 3, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__179)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__179 = PyTuple_Pack(6, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_dic, __pyx_n_s_root, __pyx_n_s_elem); if (unlikely(!__pyx_tuple__179)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__179);
+ __Pyx_GIVEREF(__pyx_tuple__179);
+ __pyx_codeobj__180 = (PyObject*)__Pyx_PyCode_New(2, 1, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__179, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_7, __pyx_n_s_XMLID, 3, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__180)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xmlid.pxi":24
* return (root, dic)
* u"""XMLDTDID(text, parser=None, base_url=None)
*
*/
- __pyx_tuple__180 = PyTuple_Pack(4, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_root); if (unlikely(!__pyx_tuple__180)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 24; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__180);
- __Pyx_GIVEREF(__pyx_tuple__180);
- __pyx_codeobj__181 = (PyObject*)__Pyx_PyCode_New(2, 1, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__180, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_7, __pyx_n_s_XMLDTDID, 24, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__181)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 24; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__181 = PyTuple_Pack(4, __pyx_n_s_text, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_root); if (unlikely(!__pyx_tuple__181)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 24; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__181);
+ __Pyx_GIVEREF(__pyx_tuple__181);
+ __pyx_codeobj__182 = (PyObject*)__Pyx_PyCode_New(2, 1, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__181, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_7, __pyx_n_s_XMLDTDID, 24, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__182)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 24; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xmlid.pxi":44
* return (root, _IDDict(root))
* u"""parseid(source, parser=None)
*
*/
- __pyx_tuple__182 = PyTuple_Pack(4, __pyx_n_s_source, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2); if (unlikely(!__pyx_tuple__182)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 44; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__182);
- __Pyx_GIVEREF(__pyx_tuple__182);
- __pyx_codeobj__183 = (PyObject*)__Pyx_PyCode_New(2, 1, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__182, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_7, __pyx_n_s_parseid, 44, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__183)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 44; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__183 = PyTuple_Pack(4, __pyx_n_s_source, __pyx_n_s_parser, __pyx_n_s_base_url, __pyx_n_s_doc_2); if (unlikely(!__pyx_tuple__183)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 44; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__183);
+ __Pyx_GIVEREF(__pyx_tuple__183);
+ __pyx_codeobj__184 = (PyObject*)__Pyx_PyCode_New(2, 1, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__183, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_7, __pyx_n_s_parseid, 44, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__184)) {__pyx_filename = __pyx_f[15]; __pyx_lineno = 44; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/cleanup.pxi":3
* # functions for tree cleanup and removing elements from subtrees
* u"""cleanup_namespaces(tree_or_element)
*
*/
- __pyx_tuple__184 = PyTuple_Pack(2, __pyx_n_s_tree_or_element, __pyx_n_s_element); if (unlikely(!__pyx_tuple__184)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__184);
- __Pyx_GIVEREF(__pyx_tuple__184);
- __pyx_codeobj__185 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__184, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_cleanup_namespaces, 3, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__185)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__185 = PyTuple_Pack(2, __pyx_n_s_tree_or_element, __pyx_n_s_element); if (unlikely(!__pyx_tuple__185)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__185);
+ __Pyx_GIVEREF(__pyx_tuple__185);
+ __pyx_codeobj__186 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__185, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_cleanup_namespaces, 3, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__186)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 3; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/cleanup.pxi":13
* _removeUnusedNamespaceDeclarations(element._c_node)
* u"""strip_attributes(tree_or_element, *attribute_names)
*
*/
- __pyx_tuple__186 = PyTuple_Pack(4, __pyx_n_s_tree_or_element, __pyx_n_s_attribute_names, __pyx_n_s_matcher, __pyx_n_s_element); if (unlikely(!__pyx_tuple__186)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 13; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__186);
- __Pyx_GIVEREF(__pyx_tuple__186);
- __pyx_codeobj__187 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_VARARGS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__186, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_strip_attributes, 13, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__187)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 13; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__187 = PyTuple_Pack(4, __pyx_n_s_tree_or_element, __pyx_n_s_attribute_names, __pyx_n_s_matcher, __pyx_n_s_element); if (unlikely(!__pyx_tuple__187)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 13; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__187);
+ __Pyx_GIVEREF(__pyx_tuple__187);
+ __pyx_codeobj__188 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, CO_VARARGS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__187, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_strip_attributes, 13, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__188)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 13; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/cleanup.pxi":54
* tree.END_FOR_EACH_ELEMENT_FROM(c_node)
* u"""strip_elements(tree_or_element, *tag_names, with_tail=True)
*
*/
- __pyx_tuple__188 = PyTuple_Pack(12, __pyx_n_s_tree_or_element, __pyx_n_s_with_tail, __pyx_n_s_tag_names, __pyx_n_s_matcher, __pyx_n_s_element, __pyx_n_s_doc_2, __pyx_n_s_ns_tags, __pyx_n_s_c_ns_tags, __pyx_n_s_c_tag_count, __pyx_n_s_strip_comments, __pyx_n_s_strip_pis, __pyx_n_s_strip_entities); if (unlikely(!__pyx_tuple__188)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 54; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__188);
- __Pyx_GIVEREF(__pyx_tuple__188);
- __pyx_codeobj__189 = (PyObject*)__Pyx_PyCode_New(1, 1, 12, 0, CO_VARARGS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__188, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_strip_elements, 54, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__189)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 54; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__189 = PyTuple_Pack(12, __pyx_n_s_tree_or_element, __pyx_n_s_with_tail, __pyx_n_s_tag_names, __pyx_n_s_matcher, __pyx_n_s_element, __pyx_n_s_doc_2, __pyx_n_s_ns_tags, __pyx_n_s_c_ns_tags, __pyx_n_s_c_tag_count, __pyx_n_s_strip_comments, __pyx_n_s_strip_pis, __pyx_n_s_strip_entities); if (unlikely(!__pyx_tuple__189)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 54; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__189);
+ __Pyx_GIVEREF(__pyx_tuple__189);
+ __pyx_codeobj__190 = (PyObject*)__Pyx_PyCode_New(1, 1, 12, 0, CO_VARARGS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__189, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_strip_elements, 54, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__190)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 54; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/cleanup.pxi":132
*
* u"""strip_tags(tree_or_element, *tag_names)
*
*/
- __pyx_tuple__190 = PyTuple_Pack(11, __pyx_n_s_tree_or_element, __pyx_n_s_tag_names, __pyx_n_s_matcher, __pyx_n_s_element, __pyx_n_s_doc_2, __pyx_n_s_ns_tags, __pyx_n_s_strip_comments, __pyx_n_s_strip_pis, __pyx_n_s_strip_entities, __pyx_n_s_c_ns_tags, __pyx_n_s_c_tag_count); if (unlikely(!__pyx_tuple__190)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__190);
- __Pyx_GIVEREF(__pyx_tuple__190);
- __pyx_codeobj__191 = (PyObject*)__Pyx_PyCode_New(1, 0, 11, 0, CO_VARARGS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__190, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_strip_tags, 132, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__191)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__191 = PyTuple_Pack(11, __pyx_n_s_tree_or_element, __pyx_n_s_tag_names, __pyx_n_s_matcher, __pyx_n_s_element, __pyx_n_s_doc_2, __pyx_n_s_ns_tags, __pyx_n_s_strip_comments, __pyx_n_s_strip_pis, __pyx_n_s_strip_entities, __pyx_n_s_c_ns_tags, __pyx_n_s_c_tag_count); if (unlikely(!__pyx_tuple__191)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__191);
+ __Pyx_GIVEREF(__pyx_tuple__191);
+ __pyx_codeobj__192 = (PyObject*)__Pyx_PyCode_New(1, 0, 11, 0, CO_VARARGS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__191, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_8, __pyx_n_s_strip_tags, 132, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__192)) {__pyx_filename = __pyx_f[17]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/extensions.pxi":371
*
* b"Number encoding",
* b"Unfinished literal",
*/
- __pyx_tuple__192 = PyTuple_Pack(24, __pyx_n_b_Ok, __pyx_kp_b_Number_encoding, __pyx_kp_b_Unfinished_literal, __pyx_kp_b_Start_of_literal, __pyx_kp_b_Expected_for_variable_reference, __pyx_kp_b_Undefined_variable, __pyx_kp_b_Invalid_predicate, __pyx_kp_b_Invalid_expression, __pyx_kp_b_Missing_closing_curly_brace, __pyx_kp_b_Unregistered_function, __pyx_kp_b_Invalid_operand, __pyx_kp_b_Invalid_type, __pyx_kp_b_Invalid_number_of_arguments, __pyx_kp_b_Invalid_context_size, __pyx_kp_b_Invalid_context_position, __pyx_kp_b_Memory_allocation_error, __pyx_kp_b_Syntax_error, __pyx_kp_b_Resource_error, __pyx_kp_b_Sub_resource_error, __pyx_kp_b_Undefined_namespace_prefix, __pyx_kp_b_Encoding_error, __pyx_kp_b_Char_out_of_XML_range, __pyx_kp_b_Invalid_or_incomplete_context, __pyx_kp_b_Stack_usage_error); if (unlikely(!__pyx_tuple__192)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 371; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__192);
- __Pyx_GIVEREF(__pyx_tuple__192);
+ __pyx_tuple__193 = PyTuple_Pack(24, __pyx_n_b_Ok, __pyx_kp_b_Number_encoding, __pyx_kp_b_Unfinished_literal, __pyx_kp_b_Start_of_literal, __pyx_kp_b_Expected_for_variable_reference, __pyx_kp_b_Undefined_variable, __pyx_kp_b_Invalid_predicate, __pyx_kp_b_Invalid_expression, __pyx_kp_b_Missing_closing_curly_brace, __pyx_kp_b_Unregistered_function, __pyx_kp_b_Invalid_operand, __pyx_kp_b_Invalid_type, __pyx_kp_b_Invalid_number_of_arguments, __pyx_kp_b_Invalid_context_size, __pyx_kp_b_Invalid_context_position, __pyx_kp_b_Memory_allocation_error, __pyx_kp_b_Syntax_error, __pyx_kp_b_Resource_error, __pyx_kp_b_Sub_resource_error, __pyx_kp_b_Undefined_namespace_prefix, __pyx_kp_b_Encoding_error, __pyx_kp_b_Char_out_of_XML_range, __pyx_kp_b_Invalid_or_incomplete_context, __pyx_kp_b_Stack_usage_error); if (unlikely(!__pyx_tuple__193)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 371; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__193);
+ __Pyx_GIVEREF(__pyx_tuple__193);
/* "src/lxml/extensions.pxi":426
*
* u"""Extension(module, function_mapping=None, ns=None)
*
*/
- __pyx_tuple__193 = PyTuple_Pack(7, __pyx_n_s_module, __pyx_n_s_function_mapping, __pyx_n_s_ns, __pyx_n_s_functions, __pyx_n_s_function_name, __pyx_n_s_xpath_name, __pyx_n_s_name_2); if (unlikely(!__pyx_tuple__193)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__193);
- __Pyx_GIVEREF(__pyx_tuple__193);
- __pyx_codeobj__194 = (PyObject*)__Pyx_PyCode_New(2, 1, 7, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__193, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_9, __pyx_n_s_Extension, 426, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__194)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__194 = PyTuple_Pack(7, __pyx_n_s_module, __pyx_n_s_function_mapping, __pyx_n_s_ns, __pyx_n_s_functions, __pyx_n_s_function_name, __pyx_n_s_xpath_name, __pyx_n_s_name_2); if (unlikely(!__pyx_tuple__194)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__194);
+ __Pyx_GIVEREF(__pyx_tuple__194);
+ __pyx_codeobj__195 = (PyObject*)__Pyx_PyCode_New(2, 1, 7, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__194, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_9, __pyx_n_s_Extension, 426, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__195)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/extensions.pxi":737
* # we need to use a Python class here, bytes cannot be C-subclassed
* return self._parent
*
*/
- __pyx_tuple__195 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__195)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__195);
- __Pyx_GIVEREF(__pyx_tuple__195);
- __pyx_codeobj__196 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__195, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_9, __pyx_n_s_getparent, 737, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__196)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__196 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__196)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__196);
+ __Pyx_GIVEREF(__pyx_tuple__196);
+ __pyx_codeobj__197 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__196, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_9, __pyx_n_s_getparent, 737, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__197)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xpath.pxi":369
*
* regexp=True, smart_strings=True):
* u"""XPathEvaluator(etree_or_element, namespaces=None, extensions=None, regexp=True, smart_strings=True)
*/
- __pyx_tuple__197 = PyTuple_Pack(5, __pyx_n_s_etree_or_element, __pyx_n_s_namespaces, __pyx_n_s_extensions, __pyx_n_s_regexp, __pyx_n_s_smart_strings); if (unlikely(!__pyx_tuple__197)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 369; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__197);
- __Pyx_GIVEREF(__pyx_tuple__197);
- __pyx_codeobj__198 = (PyObject*)__Pyx_PyCode_New(1, 4, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__197, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_10, __pyx_n_s_XPathEvaluator, 369, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__198)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 369; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__198 = PyTuple_Pack(5, __pyx_n_s_etree_or_element, __pyx_n_s_namespaces, __pyx_n_s_extensions, __pyx_n_s_regexp, __pyx_n_s_smart_strings); if (unlikely(!__pyx_tuple__198)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 369; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__198);
+ __Pyx_GIVEREF(__pyx_tuple__198);
+ __pyx_codeobj__199 = (PyObject*)__Pyx_PyCode_New(1, 4, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__198, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_10, __pyx_n_s_XPathEvaluator, 369, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__199)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 369; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xpath.pxi":467
* cdef object _replace_strings
* _find_namespaces = re.compile(b'({[^}]+})').findall
*
*/
- __pyx_tuple__200 = PyTuple_Pack(1, __pyx_kp_b__199); if (unlikely(!__pyx_tuple__200)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__200);
- __Pyx_GIVEREF(__pyx_tuple__200);
+ __pyx_tuple__201 = PyTuple_Pack(1, __pyx_kp_b__200); if (unlikely(!__pyx_tuple__201)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__201);
+ __Pyx_GIVEREF(__pyx_tuple__201);
/* "src/lxml/xpath.pxi":468
* cdef object _find_namespaces
*
* cdef class ETXPath(XPath):
*/
- __pyx_tuple__202 = PyTuple_Pack(1, __pyx_kp_b__201); if (unlikely(!__pyx_tuple__202)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__202);
- __Pyx_GIVEREF(__pyx_tuple__202);
+ __pyx_tuple__203 = PyTuple_Pack(1, __pyx_kp_b__202); if (unlikely(!__pyx_tuple__203)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__203);
+ __Pyx_GIVEREF(__pyx_tuple__203);
/* "src/lxml/xslt.pxi":435
*
* u"""strparam(strval)
*
*/
- __pyx_tuple__203 = PyTuple_Pack(1, __pyx_n_s_strval); if (unlikely(!__pyx_tuple__203)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__203);
- __Pyx_GIVEREF(__pyx_tuple__203);
- __pyx_codeobj__204 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__203, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_11, __pyx_n_s_strparam, 435, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__204)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__204 = PyTuple_Pack(1, __pyx_n_s_strval); if (unlikely(!__pyx_tuple__204)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__204);
+ __Pyx_GIVEREF(__pyx_tuple__204);
+ __pyx_codeobj__205 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__204, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_11, __pyx_n_s_strparam, 435, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__205)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 435; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
/* "src/lxml/xslt.pxi":449
*
* u"""set_global_max_depth(max_depth)
*
*/
- __pyx_tuple__205 = PyTuple_Pack(1, __pyx_n_s_max_depth); if (unlikely(!__pyx_tuple__205)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__205);
- __Pyx_GIVEREF(__pyx_tuple__205);
- __pyx_codeobj__206 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__205, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_11, __pyx_n_s_set_global_max_depth, 449, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__206)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_tuple__206 = PyTuple_Pack(1, __pyx_n_s_max_depth); if (unlikely(!__pyx_tuple__206)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__206);
+ __Pyx_GIVEREF(__pyx_tuple__206);
+ __pyx_codeobj__207 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__206, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_stefan_source_Python_lxml_11, __pyx_n_s_set_global_max_depth, 449, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__207)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "src/lxml/xslt.pxi":836
+ /* "src/lxml/xslt.pxi":838
* # XSLT PI support
*
* cdef object _RE_PI_HREF = re.compile(ur'\s+href\s*=\s*(?:\'([^\']*)\'|"([^"]*)")') # <<<<<<<<<<<<<<
* cdef object _FIND_PI_HREF = _RE_PI_HREF.findall
* cdef object _REPLACE_PI_HREF = _RE_PI_HREF.sub
*/
- __pyx_tuple__207 = PyTuple_Pack(1, __pyx_kp_u_s_href_s_s); if (unlikely(!__pyx_tuple__207)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__207);
- __Pyx_GIVEREF(__pyx_tuple__207);
+ __pyx_tuple__208 = PyTuple_Pack(1, __pyx_kp_u_s_href_s_s); if (unlikely(!__pyx_tuple__208)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__208);
+ __Pyx_GIVEREF(__pyx_tuple__208);
/* "src/lxml/xmlschema.pxi":22
* # XMLSchema
* u"boolean(//xs:attribute[@default or @fixed][1])",
* namespaces={u'xs': u'http://www.w3.org/2001/XMLSchema'})
*/
- __pyx_tuple__208 = PyTuple_Pack(1, __pyx_kp_u_boolean_xs_attribute_default_or); if (unlikely(!__pyx_tuple__208)) {__pyx_filename = __pyx_f[22]; __pyx_lineno = 22; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_tuple__208);
- __Pyx_GIVEREF(__pyx_tuple__208);
+ __pyx_tuple__209 = PyTuple_Pack(1, __pyx_kp_u_boolean_xs_attribute_default_or); if (unlikely(!__pyx_tuple__209)) {__pyx_filename = __pyx_f[22]; __pyx_lineno = 22; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_tuple__209);
+ __Pyx_GIVEREF(__pyx_tuple__209);
__Pyx_RefNannyFinishContext();
return 0;
__pyx_L1_error:;
if (__Pyx_SetVtable(LxmlDocumentType.tp_dict, __pyx_vtabptr_4lxml_5etree__Document) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 339; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (PyObject_SetAttrString(__pyx_m, "_Document", (PyObject *)&LxmlDocumentType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 339; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__Document = &LxmlDocumentType;
- if (PyType_Ready(&LxmlElementType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&LxmlElementType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
LxmlElementType.tp_print = 0;
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__setitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__setitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_8_Element_4__setitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_8_Element_4__setitem__.doc = __pyx_doc_4lxml_5etree_8_Element_4__setitem__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__delitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__delitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_8_Element_6__delitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_8_Element_6__delitem__.doc = __pyx_doc_4lxml_5etree_8_Element_6__delitem__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__repr__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__repr__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_8_Element_30__repr__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_8_Element_30__repr__.doc = __pyx_doc_4lxml_5etree_8_Element_30__repr__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__getitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__getitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_8_Element_32__getitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_8_Element_32__getitem__.doc = __pyx_doc_4lxml_5etree_8_Element_32__getitem__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__len__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__len__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_8_Element_34__len__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_8_Element_34__len__.doc = __pyx_doc_4lxml_5etree_8_Element_34__len__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__contains__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__contains__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_8_Element_38__contains__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_8_Element_38__contains__.doc = __pyx_doc_4lxml_5etree_8_Element_38__contains__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__iter__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&LxmlElementType, "__iter__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_8_Element_40__iter__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_8_Element_40__iter__.doc = __pyx_doc_4lxml_5etree_8_Element_40__iter__;
}
}
#endif
- if (PyObject_SetAttrString(__pyx_m, "_Element", (PyObject *)&LxmlElementType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_Element", (PyObject *)&LxmlElementType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 616; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__Element = &LxmlElementType;
__pyx_vtabptr_4lxml_5etree__BaseParser = &__pyx_vtable_4lxml_5etree__BaseParser;
__pyx_vtable_4lxml_5etree__BaseParser._setBaseURL = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__BaseParser *, PyObject *))__pyx_f_4lxml_5etree_11_BaseParser__setBaseURL;
__pyx_type_4lxml_5etree__BaseParser.tp_print = 0;
if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__BaseParser.tp_dict, __pyx_vtabptr_4lxml_5etree__BaseParser) < 0) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__BaseParser = &__pyx_type_4lxml_5etree__BaseParser;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_QName) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1685; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_QName) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1694; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_QName.tp_print = 0;
- if (PyObject_SetAttrString(__pyx_m, "QName", (PyObject *)&__pyx_type_4lxml_5etree_QName) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1685; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "QName", (PyObject *)&__pyx_type_4lxml_5etree_QName) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1694; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_QName = &__pyx_type_4lxml_5etree_QName;
__pyx_vtabptr_4lxml_5etree__LogEntry = &__pyx_vtable_4lxml_5etree__LogEntry;
__pyx_vtable_4lxml_5etree__LogEntry._setError = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__LogEntry *, xmlError *))__pyx_f_4lxml_5etree_9_LogEntry__setError;
__pyx_vtabptr_4lxml_5etree___ContentOnlyElement = &__pyx_vtable_4lxml_5etree___ContentOnlyElement;
__pyx_vtable_4lxml_5etree___ContentOnlyElement._raiseImmutable = (int (*)(struct __pyx_obj_4lxml_5etree___ContentOnlyElement *))__pyx_f_4lxml_5etree_20__ContentOnlyElement__raiseImmutable;
__pyx_type_4lxml_5etree___ContentOnlyElement.tp_base = __pyx_ptype_4lxml_5etree__Element;
- if (PyType_Ready(&__pyx_type_4lxml_5etree___ContentOnlyElement) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree___ContentOnlyElement) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree___ContentOnlyElement.tp_print = 0;
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_4lxml_5etree___ContentOnlyElement, "__setitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_4lxml_5etree___ContentOnlyElement, "__setitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_20__ContentOnlyElement_6__setitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_20__ContentOnlyElement_6__setitem__.doc = __pyx_doc_4lxml_5etree_20__ContentOnlyElement_6__setitem__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_4lxml_5etree___ContentOnlyElement, "__getitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_4lxml_5etree___ContentOnlyElement, "__getitem__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_20__ContentOnlyElement_8__getitem__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_20__ContentOnlyElement_8__getitem__.doc = __pyx_doc_4lxml_5etree_20__ContentOnlyElement_8__getitem__;
#endif
#if CYTHON_COMPILING_IN_CPYTHON
{
- PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_4lxml_5etree___ContentOnlyElement, "__len__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ PyObject *wrapper = PyObject_GetAttrString((PyObject *)&__pyx_type_4lxml_5etree___ContentOnlyElement, "__len__"); if (unlikely(!wrapper)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (Py_TYPE(wrapper) == &PyWrapperDescr_Type) {
__pyx_wrapperbase_4lxml_5etree_20__ContentOnlyElement_10__len__ = *((PyWrapperDescrObject *)wrapper)->d_base;
__pyx_wrapperbase_4lxml_5etree_20__ContentOnlyElement_10__len__.doc = __pyx_doc_4lxml_5etree_20__ContentOnlyElement_10__len__;
}
}
#endif
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree___ContentOnlyElement.tp_dict, __pyx_vtabptr_4lxml_5etree___ContentOnlyElement) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1531; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree___ContentOnlyElement.tp_dict, __pyx_vtabptr_4lxml_5etree___ContentOnlyElement) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1540; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree___ContentOnlyElement = &__pyx_type_4lxml_5etree___ContentOnlyElement;
__pyx_vtabptr_4lxml_5etree__Comment = &__pyx_vtable_4lxml_5etree__Comment;
__pyx_vtable_4lxml_5etree__Comment.__pyx_base = *__pyx_vtabptr_4lxml_5etree___ContentOnlyElement;
__pyx_type_4lxml_5etree__Comment.tp_base = __pyx_ptype_4lxml_5etree___ContentOnlyElement;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__Comment) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__Comment) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__Comment.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__Comment.tp_dict, __pyx_vtabptr_4lxml_5etree__Comment) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_Comment", (PyObject *)&__pyx_type_4lxml_5etree__Comment) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1598; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__Comment.tp_dict, __pyx_vtabptr_4lxml_5etree__Comment) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_Comment", (PyObject *)&__pyx_type_4lxml_5etree__Comment) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1607; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__Comment = &__pyx_type_4lxml_5etree__Comment;
__pyx_vtabptr_4lxml_5etree__ProcessingInstruction = &__pyx_vtable_4lxml_5etree__ProcessingInstruction;
__pyx_vtable_4lxml_5etree__ProcessingInstruction.__pyx_base = *__pyx_vtabptr_4lxml_5etree___ContentOnlyElement;
__pyx_type_4lxml_5etree__ProcessingInstruction.tp_base = __pyx_ptype_4lxml_5etree___ContentOnlyElement;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__ProcessingInstruction) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1606; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__ProcessingInstruction) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__ProcessingInstruction.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__ProcessingInstruction.tp_dict, __pyx_vtabptr_4lxml_5etree__ProcessingInstruction) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1606; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_ProcessingInstruction", (PyObject *)&__pyx_type_4lxml_5etree__ProcessingInstruction) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1606; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__ProcessingInstruction.tp_dict, __pyx_vtabptr_4lxml_5etree__ProcessingInstruction) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_ProcessingInstruction", (PyObject *)&__pyx_type_4lxml_5etree__ProcessingInstruction) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1615; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__ProcessingInstruction = &__pyx_type_4lxml_5etree__ProcessingInstruction;
__pyx_vtabptr_4lxml_5etree__Entity = &__pyx_vtable_4lxml_5etree__Entity;
__pyx_vtable_4lxml_5etree__Entity.__pyx_base = *__pyx_vtabptr_4lxml_5etree___ContentOnlyElement;
__pyx_type_4lxml_5etree__Entity.tp_base = __pyx_ptype_4lxml_5etree___ContentOnlyElement;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__Entity) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__Entity) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1665; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__Entity.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__Entity.tp_dict, __pyx_vtabptr_4lxml_5etree__Entity) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_Entity", (PyObject *)&__pyx_type_4lxml_5etree__Entity) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1656; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__Entity.tp_dict, __pyx_vtabptr_4lxml_5etree__Entity) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1665; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_Entity", (PyObject *)&__pyx_type_4lxml_5etree__Entity) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1665; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__Entity = &__pyx_type_4lxml_5etree__Entity;
__pyx_vtabptr_4lxml_5etree__ElementTree = &__pyx_vtable_4lxml_5etree__ElementTree;
__pyx_vtable_4lxml_5etree__ElementTree._assertHasRoot = (int (*)(struct LxmlElementTree *))__pyx_f_4lxml_5etree_12_ElementTree__assertHasRoot;
- if (PyType_Ready(&LxmlElementTreeType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1753; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&LxmlElementTreeType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1762; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
LxmlElementTreeType.tp_print = 0;
- if (__Pyx_SetVtable(LxmlElementTreeType.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementTree) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1753; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_ElementTree", (PyObject *)&LxmlElementTreeType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1753; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(LxmlElementTreeType.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementTree) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1762; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_ElementTree", (PyObject *)&LxmlElementTreeType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1762; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__ElementTree = &LxmlElementTreeType;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__Attrib) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2296; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__Attrib) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2305; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__Attrib.tp_print = 0;
- if (PyObject_SetAttrString(__pyx_m, "_Attrib", (PyObject *)&__pyx_type_4lxml_5etree__Attrib) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2296; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_Attrib", (PyObject *)&__pyx_type_4lxml_5etree__Attrib) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2305; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__Attrib = &__pyx_type_4lxml_5etree__Attrib;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__AttribIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2436; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__AttribIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2445; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__AttribIterator.tp_print = 0;
__pyx_ptype_4lxml_5etree__AttribIterator = &__pyx_type_4lxml_5etree__AttribIterator;
__pyx_vtabptr_4lxml_5etree__ElementTagMatcher = &__pyx_vtable_4lxml_5etree__ElementTagMatcher;
__pyx_vtable_4lxml_5etree__ElementTagMatcher._initTagMatch = (PyObject *(*)(struct LxmlElementTagMatcher *, PyObject *))__pyx_f_4lxml_5etree_18_ElementTagMatcher__initTagMatch;
- if (PyType_Ready(&LxmlElementTagMatcherType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2477; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&LxmlElementTagMatcherType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2486; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
LxmlElementTagMatcherType.tp_print = 0;
- if (__Pyx_SetVtable(LxmlElementTagMatcherType.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementTagMatcher) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2477; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_ElementTagMatcher", (PyObject *)&LxmlElementTagMatcherType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2477; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(LxmlElementTagMatcherType.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementTagMatcher) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2486; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_ElementTagMatcher", (PyObject *)&LxmlElementTagMatcherType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2486; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__ElementTagMatcher = &LxmlElementTagMatcherType;
__pyx_vtabptr_4lxml_5etree__ElementIterator = &__pyx_vtable_4lxml_5etree__ElementIterator;
__pyx_vtable_4lxml_5etree__ElementIterator.__pyx_base = *__pyx_vtabptr_4lxml_5etree__ElementTagMatcher;
__pyx_vtable_4lxml_5etree__ElementIterator._storeNext = (void (*)(struct LxmlElementIterator *, struct LxmlElement *))__pyx_f_4lxml_5etree_16_ElementIterator__storeNext;
LxmlElementIteratorType.tp_base = __pyx_ptype_4lxml_5etree__ElementTagMatcher;
- if (PyType_Ready(&LxmlElementIteratorType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2508; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&LxmlElementIteratorType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2517; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
LxmlElementIteratorType.tp_print = 0;
- if (__Pyx_SetVtable(LxmlElementIteratorType.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2508; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_ElementIterator", (PyObject *)&LxmlElementIteratorType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2508; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(LxmlElementIteratorType.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2517; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_ElementIterator", (PyObject *)&LxmlElementIteratorType) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2517; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__ElementIterator = &LxmlElementIteratorType;
__pyx_vtabptr_4lxml_5etree__MultiTagMatcher = &__pyx_vtable_4lxml_5etree__MultiTagMatcher;
__pyx_vtable_4lxml_5etree__MultiTagMatcher.rejectsAll = (int (*)(struct __pyx_obj_4lxml_5etree__MultiTagMatcher *))__pyx_f_4lxml_5etree_16_MultiTagMatcher_rejectsAll;
__pyx_vtable_4lxml_5etree__MultiTagMatcher.matches = (int (*)(struct __pyx_obj_4lxml_5etree__MultiTagMatcher *, xmlNode *))__pyx_f_4lxml_5etree_16_MultiTagMatcher_matches;
__pyx_vtable_4lxml_5etree__MultiTagMatcher.matchesNsTag = (int (*)(struct __pyx_obj_4lxml_5etree__MultiTagMatcher *, const xmlChar *, const xmlChar *))__pyx_f_4lxml_5etree_16_MultiTagMatcher_matchesNsTag;
__pyx_vtable_4lxml_5etree__MultiTagMatcher.matchesAttribute = (int (*)(struct __pyx_obj_4lxml_5etree__MultiTagMatcher *, xmlAttr *))__pyx_f_4lxml_5etree_16_MultiTagMatcher_matchesAttribute;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__MultiTagMatcher) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2545; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__MultiTagMatcher) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2554; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__MultiTagMatcher.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__MultiTagMatcher.tp_dict, __pyx_vtabptr_4lxml_5etree__MultiTagMatcher) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2545; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__MultiTagMatcher.tp_dict, __pyx_vtabptr_4lxml_5etree__MultiTagMatcher) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2554; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__MultiTagMatcher = &__pyx_type_4lxml_5etree__MultiTagMatcher;
__pyx_vtabptr_4lxml_5etree__ElementMatchIterator = &__pyx_vtable_4lxml_5etree__ElementMatchIterator;
__pyx_vtable_4lxml_5etree__ElementMatchIterator._initTagMatcher = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__ElementMatchIterator *, PyObject *))__pyx_f_4lxml_5etree_21_ElementMatchIterator__initTagMatcher;
__pyx_vtable_4lxml_5etree__ElementMatchIterator._storeNext = (int (*)(struct __pyx_obj_4lxml_5etree__ElementMatchIterator *, struct LxmlElement *))__pyx_f_4lxml_5etree_21_ElementMatchIterator__storeNext;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__ElementMatchIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2686; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__ElementMatchIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2695; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__ElementMatchIterator.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__ElementMatchIterator.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementMatchIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2686; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_ElementMatchIterator", (PyObject *)&__pyx_type_4lxml_5etree__ElementMatchIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2686; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__ElementMatchIterator.tp_dict, __pyx_vtabptr_4lxml_5etree__ElementMatchIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2695; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_ElementMatchIterator", (PyObject *)&__pyx_type_4lxml_5etree__ElementMatchIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2695; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__ElementMatchIterator = &__pyx_type_4lxml_5etree__ElementMatchIterator;
__pyx_vtabptr_4lxml_5etree_ElementChildIterator = &__pyx_vtable_4lxml_5etree_ElementChildIterator;
__pyx_vtable_4lxml_5etree_ElementChildIterator.__pyx_base = *__pyx_vtabptr_4lxml_5etree__ElementMatchIterator;
__pyx_type_4lxml_5etree_ElementChildIterator.tp_base = __pyx_ptype_4lxml_5etree__ElementMatchIterator;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_ElementChildIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_ElementChildIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_ElementChildIterator.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_ElementChildIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_ElementChildIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "ElementChildIterator", (PyObject *)&__pyx_type_4lxml_5etree_ElementChildIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2715; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_ElementChildIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_ElementChildIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "ElementChildIterator", (PyObject *)&__pyx_type_4lxml_5etree_ElementChildIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2724; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_ElementChildIterator = &__pyx_type_4lxml_5etree_ElementChildIterator;
__pyx_vtabptr_4lxml_5etree_SiblingsIterator = &__pyx_vtable_4lxml_5etree_SiblingsIterator;
__pyx_vtable_4lxml_5etree_SiblingsIterator.__pyx_base = *__pyx_vtabptr_4lxml_5etree__ElementMatchIterator;
__pyx_type_4lxml_5etree_SiblingsIterator.tp_base = __pyx_ptype_4lxml_5etree__ElementMatchIterator;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_SiblingsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_SiblingsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_SiblingsIterator.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_SiblingsIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_SiblingsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "SiblingsIterator", (PyObject *)&__pyx_type_4lxml_5etree_SiblingsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_SiblingsIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_SiblingsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "SiblingsIterator", (PyObject *)&__pyx_type_4lxml_5etree_SiblingsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_SiblingsIterator = &__pyx_type_4lxml_5etree_SiblingsIterator;
__pyx_vtabptr_4lxml_5etree_AncestorsIterator = &__pyx_vtable_4lxml_5etree_AncestorsIterator;
__pyx_vtable_4lxml_5etree_AncestorsIterator.__pyx_base = *__pyx_vtabptr_4lxml_5etree__ElementMatchIterator;
__pyx_type_4lxml_5etree_AncestorsIterator.tp_base = __pyx_ptype_4lxml_5etree__ElementMatchIterator;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_AncestorsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2750; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_AncestorsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2759; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_AncestorsIterator.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_AncestorsIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_AncestorsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2750; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "AncestorsIterator", (PyObject *)&__pyx_type_4lxml_5etree_AncestorsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2750; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_AncestorsIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_AncestorsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2759; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "AncestorsIterator", (PyObject *)&__pyx_type_4lxml_5etree_AncestorsIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2759; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_AncestorsIterator = &__pyx_type_4lxml_5etree_AncestorsIterator;
__pyx_vtabptr_4lxml_5etree_ElementDepthFirstIterator = &__pyx_vtable_4lxml_5etree_ElementDepthFirstIterator;
__pyx_vtable_4lxml_5etree_ElementDepthFirstIterator._nextNodeAnyTag = (xmlNode *(*)(struct __pyx_obj_4lxml_5etree_ElementDepthFirstIterator *, xmlNode *))__pyx_f_4lxml_5etree_25ElementDepthFirstIterator__nextNodeAnyTag;
__pyx_vtable_4lxml_5etree_ElementDepthFirstIterator._nextNodeMatchTag = (xmlNode *(*)(struct __pyx_obj_4lxml_5etree_ElementDepthFirstIterator *, xmlNode *))__pyx_f_4lxml_5etree_25ElementDepthFirstIterator__nextNodeMatchTag;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_ElementDepthFirstIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_ElementDepthFirstIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_ElementDepthFirstIterator.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_ElementDepthFirstIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_ElementDepthFirstIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "ElementDepthFirstIterator", (PyObject *)&__pyx_type_4lxml_5etree_ElementDepthFirstIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2760; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree_ElementDepthFirstIterator.tp_dict, __pyx_vtabptr_4lxml_5etree_ElementDepthFirstIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "ElementDepthFirstIterator", (PyObject *)&__pyx_type_4lxml_5etree_ElementDepthFirstIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2769; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_ElementDepthFirstIterator = &__pyx_type_4lxml_5etree_ElementDepthFirstIterator;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_ElementTextIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_ElementTextIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2845; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_ElementTextIterator.tp_print = 0;
- if (PyObject_SetAttrString(__pyx_m, "ElementTextIterator", (PyObject *)&__pyx_type_4lxml_5etree_ElementTextIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "ElementTextIterator", (PyObject *)&__pyx_type_4lxml_5etree_ElementTextIterator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2845; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_ElementTextIterator = &__pyx_type_4lxml_5etree_ElementTextIterator;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_CDATA) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2947; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_CDATA) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2956; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_CDATA.tp_print = 0;
- if (PyObject_SetAttrString(__pyx_m, "CDATA", (PyObject *)&__pyx_type_4lxml_5etree_CDATA) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2947; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "CDATA", (PyObject *)&__pyx_type_4lxml_5etree_CDATA) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2956; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_CDATA = &__pyx_type_4lxml_5etree_CDATA;
__pyx_vtabptr_4lxml_5etree__ReadOnlyProxy = &__pyx_vtable_4lxml_5etree__ReadOnlyProxy;
__pyx_vtable_4lxml_5etree__ReadOnlyProxy._assertNode = (int (*)(struct __pyx_obj_4lxml_5etree__ReadOnlyProxy *))__pyx_f_4lxml_5etree_14_ReadOnlyProxy__assertNode;
__pyx_vtabptr_4lxml_5etree__Validator = &__pyx_vtable_4lxml_5etree__Validator;
__pyx_vtable_4lxml_5etree__Validator._append_log_message = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__Validator *, int, int, int, int, PyObject *, PyObject *, int __pyx_skip_dispatch))__pyx_f_4lxml_5etree_10_Validator__append_log_message;
__pyx_vtable_4lxml_5etree__Validator._clear_error_log = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__Validator *, int __pyx_skip_dispatch))__pyx_f_4lxml_5etree_10_Validator__clear_error_log;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__Validator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3344; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__Validator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__Validator.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__Validator.tp_dict, __pyx_vtabptr_4lxml_5etree__Validator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3344; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_Validator", (PyObject *)&__pyx_type_4lxml_5etree__Validator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3344; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__Validator.tp_dict, __pyx_vtabptr_4lxml_5etree__Validator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_Validator", (PyObject *)&__pyx_type_4lxml_5etree__Validator) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3353; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__Validator = &__pyx_type_4lxml_5etree__Validator;
__pyx_vtabptr_4lxml_5etree_XMLSchema = &__pyx_vtable_4lxml_5etree_XMLSchema;
__pyx_vtable_4lxml_5etree_XMLSchema.__pyx_base = *__pyx_vtabptr_4lxml_5etree__Validator;
__pyx_vtable_4lxml_5etree__FilelikeWriter._createOutputBuffer = (xmlOutputBuffer *(*)(struct __pyx_obj_4lxml_5etree__FilelikeWriter *, xmlCharEncodingHandler *))__pyx_f_4lxml_5etree_15_FilelikeWriter__createOutputBuffer;
__pyx_vtable_4lxml_5etree__FilelikeWriter.write = (int (*)(struct __pyx_obj_4lxml_5etree__FilelikeWriter *, char *, int))__pyx_f_4lxml_5etree_15_FilelikeWriter_write;
__pyx_vtable_4lxml_5etree__FilelikeWriter.close = (int (*)(struct __pyx_obj_4lxml_5etree__FilelikeWriter *))__pyx_f_4lxml_5etree_15_FilelikeWriter_close;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__FilelikeWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__FilelikeWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__FilelikeWriter.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__FilelikeWriter.tp_dict, __pyx_vtabptr_4lxml_5etree__FilelikeWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 374; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__FilelikeWriter.tp_dict, __pyx_vtabptr_4lxml_5etree__FilelikeWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 381; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__FilelikeWriter = &__pyx_type_4lxml_5etree__FilelikeWriter;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_xmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_xmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_xmlfile.tp_print = 0;
- if (PyObject_SetAttrString(__pyx_m, "xmlfile", (PyObject *)&__pyx_type_4lxml_5etree_xmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 605; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "xmlfile", (PyObject *)&__pyx_type_4lxml_5etree_xmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 614; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_xmlfile = &__pyx_type_4lxml_5etree_xmlfile;
__pyx_type_4lxml_5etree_htmlfile.tp_base = __pyx_ptype_4lxml_5etree_xmlfile;
- if (PyType_Ready(&__pyx_type_4lxml_5etree_htmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree_htmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree_htmlfile.tp_print = 0;
- if (PyObject_SetAttrString(__pyx_m, "htmlfile", (PyObject *)&__pyx_type_4lxml_5etree_htmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 674; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "htmlfile", (PyObject *)&__pyx_type_4lxml_5etree_htmlfile) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 683; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree_htmlfile = &__pyx_type_4lxml_5etree_htmlfile;
__pyx_vtabptr_4lxml_5etree__IncrementalFileWriter = &__pyx_vtable_4lxml_5etree__IncrementalFileWriter;
__pyx_vtable_4lxml_5etree__IncrementalFileWriter._write_qname = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__IncrementalFileWriter *, PyObject *, PyObject *))__pyx_f_4lxml_5etree_22_IncrementalFileWriter__write_qname;
__pyx_vtable_4lxml_5etree__IncrementalFileWriter._collect_namespaces = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__IncrementalFileWriter *, PyObject *))__pyx_f_4lxml_5etree_22_IncrementalFileWriter__collect_namespaces;
__pyx_vtable_4lxml_5etree__IncrementalFileWriter._close = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__IncrementalFileWriter *, int))__pyx_f_4lxml_5etree_22_IncrementalFileWriter__close;
__pyx_vtable_4lxml_5etree__IncrementalFileWriter._handle_error = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__IncrementalFileWriter *, int))__pyx_f_4lxml_5etree_22_IncrementalFileWriter__handle_error;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__IncrementalFileWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 695; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__IncrementalFileWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 704; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__IncrementalFileWriter.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__IncrementalFileWriter.tp_dict, __pyx_vtabptr_4lxml_5etree__IncrementalFileWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 695; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__IncrementalFileWriter.tp_dict, __pyx_vtabptr_4lxml_5etree__IncrementalFileWriter) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 704; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__IncrementalFileWriter = &__pyx_type_4lxml_5etree__IncrementalFileWriter;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__FileWriterElement) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 958; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__FileWriterElement) < 0) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 968; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__FileWriterElement.tp_print = 0;
__pyx_ptype_4lxml_5etree__FileWriterElement = &__pyx_type_4lxml_5etree__FileWriterElement;
__pyx_vtabptr_4lxml_5etree_iterparse = &__pyx_vtable_4lxml_5etree_iterparse;
__pyx_vtable_4lxml_5etree__XSLTResultTree.__pyx_base = *__pyx_vtabptr_4lxml_5etree__ElementTree;
__pyx_vtable_4lxml_5etree__XSLTResultTree._saveToStringAndSize = (PyObject *(*)(struct __pyx_obj_4lxml_5etree__XSLTResultTree *, xmlChar **, int *))__pyx_f_4lxml_5etree_15_XSLTResultTree__saveToStringAndSize;
__pyx_type_4lxml_5etree__XSLTResultTree.tp_base = __pyx_ptype_4lxml_5etree__ElementTree;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__XSLTResultTree) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 698; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__XSLTResultTree) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 700; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__XSLTResultTree.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__XSLTResultTree.tp_dict, __pyx_vtabptr_4lxml_5etree__XSLTResultTree) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 698; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_XSLTResultTree", (PyObject *)&__pyx_type_4lxml_5etree__XSLTResultTree) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 698; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__XSLTResultTree.tp_dict, __pyx_vtabptr_4lxml_5etree__XSLTResultTree) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 700; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_XSLTResultTree", (PyObject *)&__pyx_type_4lxml_5etree__XSLTResultTree) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 700; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__XSLTResultTree = &__pyx_type_4lxml_5etree__XSLTResultTree;
__pyx_vtabptr_4lxml_5etree__XSLTProcessingInstruction = &__pyx_vtable_4lxml_5etree__XSLTProcessingInstruction;
__pyx_vtable_4lxml_5etree__XSLTProcessingInstruction.__pyx_base = *__pyx_vtabptr_4lxml_5etree_PIBase;
__pyx_type_4lxml_5etree__XSLTProcessingInstruction.tp_base = __pyx_ptype_4lxml_5etree_PIBase;
- if (PyType_Ready(&__pyx_type_4lxml_5etree__XSLTProcessingInstruction) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_4lxml_5etree__XSLTProcessingInstruction) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 851; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_type_4lxml_5etree__XSLTProcessingInstruction.tp_print = 0;
- if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__XSLTProcessingInstruction.tp_dict, __pyx_vtabptr_4lxml_5etree__XSLTProcessingInstruction) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (PyObject_SetAttrString(__pyx_m, "_XSLTProcessingInstruction", (PyObject *)&__pyx_type_4lxml_5etree__XSLTProcessingInstruction) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 849; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_4lxml_5etree__XSLTProcessingInstruction.tp_dict, __pyx_vtabptr_4lxml_5etree__XSLTProcessingInstruction) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 851; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttrString(__pyx_m, "_XSLTProcessingInstruction", (PyObject *)&__pyx_type_4lxml_5etree__XSLTProcessingInstruction) < 0) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 851; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_4lxml_5etree__XSLTProcessingInstruction = &__pyx_type_4lxml_5etree__XSLTProcessingInstruction;
__pyx_vtabptr_4lxml_5etree_XSLTExtension = &__pyx_vtable_4lxml_5etree_XSLTExtension;
__pyx_vtable_4lxml_5etree_XSLTExtension._collectXSLTResultContent = (PyObject *(*)(struct __pyx_obj_4lxml_5etree_XSLTExtension *, struct __pyx_obj_4lxml_5etree__XSLTContext *, xmlNode *, int, int))__pyx_f_4lxml_5etree_13XSLTExtension__collectXSLTResultContent;
* raise KeyError, key
*
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_1__getitem__, 0, __pyx_n_s_ImmutableMapping___getitem, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__107)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_1__getitem__, 0, __pyx_n_s_ImmutableMapping___getitem, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__108)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_getitem, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 103; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
* raise KeyError, key
*
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_3__setitem__, 0, __pyx_n_s_ImmutableMapping___setitem, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__109)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_3__setitem__, 0, __pyx_n_s_ImmutableMapping___setitem, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__110)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_setitem, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 106; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
* raise KeyError, key
*
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_5__delitem__, 0, __pyx_n_s_ImmutableMapping___delitem, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__111)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_5__delitem__, 0, __pyx_n_s_ImmutableMapping___delitem, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__112)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_delitem, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 109; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
* return False
*
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_7__contains__, 0, __pyx_n_s_ImmutableMapping___contains, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__113)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_7__contains__, 0, __pyx_n_s_ImmutableMapping___contains, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__114)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_contains, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 112; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
* return 0
*
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_9__len__, 0, __pyx_n_s_ImmutableMapping___len, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__115)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_9__len__, 0, __pyx_n_s_ImmutableMapping___len, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__116)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_len, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
* return ITER_EMPTY
* iterkeys = itervalues = iteritems = __iter__
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_11__iter__, 0, __pyx_n_s_ImmutableMapping___iter, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__117)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_17_ImmutableMapping_11__iter__, 0, __pyx_n_s_ImmutableMapping___iter, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__118)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_iter_2, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
__pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_encode); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__118, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__119, NULL); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
if (!(likely(PyBytes_CheckExact(__pyx_t_6))||((__pyx_t_6) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "bytes", Py_TYPE(__pyx_t_6)->tp_name), 0))) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 161; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
*/
__pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_compile); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__119, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__120, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_match); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 180; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
* super(_Error, self).__init__(message)
* if error_log is None:
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_9LxmlError_1__init__, 0, __pyx_n_s_LxmlError___init, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__123)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_9LxmlError_1__init__, 0, __pyx_n_s_LxmlError___init, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__124)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
- __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_9, __pyx_tuple__124);
+ __Pyx_CyFunction_SetDefaultsTuple(__pyx_t_9, __pyx_tuple__125);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_init, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 208; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
__pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_group); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 263; __pyx_clineno = __LINE__; goto __pyx_L45_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__125, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 263; __pyx_clineno = __LINE__; goto __pyx_L45_error;}
+ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__126, NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 263; __pyx_clineno = __LINE__; goto __pyx_L45_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
*
* cdef _BaseErrorLog _getGlobalErrorLog():
*/
- __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__RotatingErrorLog)), __pyx_tuple__127, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree__RotatingErrorLog)), __pyx_tuple__128, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 545; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
__Pyx_XGOTREF(((PyObject *)__pyx_v_4lxml_5etree___GLOBAL_ERROR_LOG));
__Pyx_DECREF_SET(__pyx_v_4lxml_5etree___GLOBAL_ERROR_LOG, ((struct __pyx_obj_4lxml_5etree__BaseErrorLog *)__pyx_t_8));
* NONE=0
* WARNING=1
*/
- __Pyx_INCREF(__pyx_tuple__130);
+ __Pyx_INCREF(__pyx_tuple__131);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree___ERROR_LEVELS);
- __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___ERROR_LEVELS, __pyx_tuple__130);
- __Pyx_GIVEREF(__pyx_tuple__130);
+ __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___ERROR_LEVELS, __pyx_tuple__131);
+ __Pyx_GIVEREF(__pyx_tuple__131);
/* "src/lxml/xmlerror.pxi":746
* """,)
* NONE=0
* PARSER=1
*/
- __Pyx_INCREF(__pyx_tuple__131);
+ __Pyx_INCREF(__pyx_tuple__132);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree___ERROR_DOMAINS);
- __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___ERROR_DOMAINS, __pyx_tuple__131);
- __Pyx_GIVEREF(__pyx_tuple__131);
+ __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___ERROR_DOMAINS, __pyx_tuple__132);
+ __Pyx_GIVEREF(__pyx_tuple__132);
/* "src/lxml/xmlerror.pxi":780
* """,)
* ERR_OK=0
* ERR_INTERNAL_ERROR=1
*/
- __Pyx_INCREF(__pyx_tuple__132);
+ __Pyx_INCREF(__pyx_tuple__133);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree___PARSER_ERROR_TYPES);
- __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___PARSER_ERROR_TYPES, __pyx_tuple__132);
- __Pyx_GIVEREF(__pyx_tuple__132);
+ __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___PARSER_ERROR_TYPES, __pyx_tuple__133);
+ __Pyx_GIVEREF(__pyx_tuple__133);
/* "src/lxml/xmlerror.pxi":1537
* """,)
* RELAXNG_OK=0
* RELAXNG_ERR_MEMORY=1
*/
- __Pyx_INCREF(__pyx_tuple__133);
+ __Pyx_INCREF(__pyx_tuple__134);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree___RELAXNG_ERROR_TYPES);
- __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___RELAXNG_ERROR_TYPES, __pyx_tuple__133);
- __Pyx_GIVEREF(__pyx_tuple__133);
+ __Pyx_DECREF_SET(__pyx_v_4lxml_5etree___RELAXNG_ERROR_TYPES, __pyx_tuple__134);
+ __Pyx_GIVEREF(__pyx_tuple__134);
/* "src/lxml/xmlerror.pxi":1581
* # --- END: GENERATED CONSTANTS ---
__Pyx_GIVEREF(__pyx_t_8);
__pyx_t_8 = 0;
- /* "src/lxml/lxml.etree.pyx":1654
+ /* "src/lxml/lxml.etree.pyx":1663
* for attr, value1, value2 in _FIND_PI_ATTRIBUTES(u' ' + self.text) }
*
* cdef object _FIND_PI_ATTRIBUTES = re.compile(ur'\s+(\w+)\s*=\s*(?:\'([^\']*)\'|"([^"]*)")', re.U).findall # <<<<<<<<<<<<<<
*
* cdef class _Entity(__ContentOnlyElement):
*/
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_compile); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_compile); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1663; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_U); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_U); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1663; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__pyx_t_6 = NULL;
__pyx_t_12 = 0;
__pyx_t_12 = 1;
}
}
- __pyx_t_9 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1663; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (__pyx_t_6) {
PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_6); __Pyx_GIVEREF(__pyx_t_6); __pyx_t_6 = NULL;
PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_12, __pyx_t_7);
__Pyx_GIVEREF(__pyx_t_7);
__pyx_t_7 = 0;
- __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_9, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_9, NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1663; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_findall); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1654; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_findall); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1663; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
__Pyx_XGOTREF(__pyx_v_4lxml_5etree__FIND_PI_ATTRIBUTES);
__Pyx_GIVEREF(__pyx_t_1);
__pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2893
+ /* "src/lxml/lxml.etree.pyx":2902
* # module-level API for ElementTree
*
* def Element(_tag, attrib=None, nsmap=None, **_extra): # <<<<<<<<<<<<<<
* u"""Element(_tag, attrib=None, nsmap=None, **_extra)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_7Element, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_7Element, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_Element, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2893; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_Element, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2902; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2906
+ /* "src/lxml/lxml.etree.pyx":2915
* attrib, nsmap, _extra)
*
* def Comment(text=None): # <<<<<<<<<<<<<<
* u"""Comment(text=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_9Comment, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2906; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_9Comment, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_Comment, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2906; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_Comment, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2915; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2925
+ /* "src/lxml/lxml.etree.pyx":2934
* return _elementFactory(doc, c_node)
*
* def ProcessingInstruction(target, text=None): # <<<<<<<<<<<<<<
* u"""ProcessingInstruction(target, text=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_11ProcessingInstruction, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_11ProcessingInstruction, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2934; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_ProcessingInstruction, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2925; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_ProcessingInstruction, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2934; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2945
+ /* "src/lxml/lxml.etree.pyx":2954
* return _elementFactory(doc, c_node)
*
* PI = ProcessingInstruction # <<<<<<<<<<<<<<
*
* cdef class CDATA:
*/
- __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_ProcessingInstruction); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2954; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_PI, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2945; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_PI, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2954; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2965
+ /* "src/lxml/lxml.etree.pyx":2974
* self._utf8_data = _utf8(data)
*
* def Entity(name): # <<<<<<<<<<<<<<
* u"""Entity(name)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_13Entity, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_13Entity, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2974; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_Entity, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2965; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_Entity, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2974; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2990
+ /* "src/lxml/lxml.etree.pyx":2999
* return _elementFactory(doc, c_node)
*
* def SubElement(_Element _parent not None, _tag, # <<<<<<<<<<<<<<
* attrib=None, nsmap=None, **_extra):
* u"""SubElement(_parent, _tag, attrib=None, nsmap=None, **_extra)
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_15SubElement, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_15SubElement, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_SubElement, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2990; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_SubElement, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":2999
+ /* "src/lxml/lxml.etree.pyx":3008
* return _makeSubElement(_parent, _tag, None, None, attrib, nsmap, _extra)
*
* def ElementTree(_Element element=None, *, file=None, _BaseParser parser=None): # <<<<<<<<<<<<<<
* u"""ElementTree(element=None, file=None, parser=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_17ElementTree, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_17ElementTree, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_ElementTree, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 2999; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_ElementTree, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3008; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3024
+ /* "src/lxml/lxml.etree.pyx":3033
* return _elementTreeFactory(doc, element)
*
* def HTML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""HTML(text, parser=None, base_url=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_19HTML, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_19HTML, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_HTML, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3024; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_HTML, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3033; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3049
+ /* "src/lxml/lxml.etree.pyx":3058
* return result_container.result
*
* def XML(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""XML(text, parser=None, base_url=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_21XML, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_21XML, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3058; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_XML, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3049; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_XML, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3058; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3079
+ /* "src/lxml/lxml.etree.pyx":3088
* return result_container.result
*
* def fromstring(text, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""fromstring(text, parser=None, base_url=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_23fromstring, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_23fromstring, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_fromstring, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3079; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_fromstring, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3088; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3099
+ /* "src/lxml/lxml.etree.pyx":3108
* return result_container.result
*
* def fromstringlist(strings, _BaseParser parser=None): # <<<<<<<<<<<<<<
* u"""fromstringlist(strings, parser=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_25fromstringlist, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_25fromstringlist, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_fromstringlist, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3099; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_fromstringlist, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3108; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3119
+ /* "src/lxml/lxml.etree.pyx":3128
* return parser.close()
*
* def iselement(element): # <<<<<<<<<<<<<<
* u"""iselement(element)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_27iselement, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_27iselement, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_iselement, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_iselement, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3126
+ /* "src/lxml/lxml.etree.pyx":3135
* return isinstance(element, _Element) and (<_Element>element)._c_node is not NULL
*
* def dump(_Element elem not None, *, bint pretty_print=True, with_tail=True): # <<<<<<<<<<<<<<
* u"""dump(elem, pretty_print=True, with_tail=True)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_29dump, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_29dump, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_dump, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3126; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_dump, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3138
+ /* "src/lxml/lxml.etree.pyx":3147
* sys.stdout.write(xml)
*
* def tostring(element_or_tree, *, encoding=None, method=u"xml", # <<<<<<<<<<<<<<
* xml_declaration=None, bint pretty_print=False, bint with_tail=True,
* standalone=None, doctype=None,
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_31tostring, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3138; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_31tostring, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_tostring, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3138; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_tostring, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3147; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3230
+ /* "src/lxml/lxml.etree.pyx":3239
* python._fqtypename(element_or_tree).decode('utf8')
*
* def tostringlist(element_or_tree, *args, **kwargs): # <<<<<<<<<<<<<<
* u"""tostringlist(element_or_tree, *args, **kwargs)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_33tostringlist, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_33tostringlist, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_tostringlist, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_tostringlist, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3241
+ /* "src/lxml/lxml.etree.pyx":3250
* return [tostring(element_or_tree, *args, **kwargs)]
*
* def tounicode(element_or_tree, *, method=u"xml", bint pretty_print=False, # <<<<<<<<<<<<<<
* bint with_tail=True, doctype=None):
* u"""tounicode(element_or_tree, method="xml", pretty_print=False,
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_35tounicode, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_35tounicode, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3250; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_tounicode, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3241; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_tounicode, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3250; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "src/lxml/lxml.etree.pyx":3275
+ /* "src/lxml/lxml.etree.pyx":3284
* type(element_or_tree)
*
* def parse(source, _BaseParser parser=None, *, base_url=None): # <<<<<<<<<<<<<<
* u"""parse(source, parser=None, base_url=None)
*
*/
- __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_37parse, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3275; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_4lxml_5etree_37parse, NULL, __pyx_n_s_lxml_etree); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3284; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_parse, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3275; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_parse, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3284; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
/* "src/lxml/classlookup.pxi":551
* super(_ParseError, self).__init__(message)
* self.position = (line, column)
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_10ParseError_1__init__, 0, __pyx_n_s_ParseError___init, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__171)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_10ParseError_1__init__, 0, __pyx_n_s_ParseError___init, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__172)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_init, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 18; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
*
*
*/
- __Pyx_INCREF(__pyx_tuple__175);
+ __Pyx_INCREF(__pyx_tuple__176);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree_NS_END_EVENT);
- __Pyx_DECREF_SET(__pyx_v_4lxml_5etree_NS_END_EVENT, __pyx_tuple__175);
- __Pyx_GIVEREF(__pyx_tuple__175);
+ __Pyx_DECREF_SET(__pyx_v_4lxml_5etree_NS_END_EVENT, __pyx_tuple__176);
+ __Pyx_GIVEREF(__pyx_tuple__176);
/* "src/lxml/parsertarget.pxi":4
*
* self.result = result
*
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_19_TargetParserResult_1__init__, 0, __pyx_n_s_TargetParserResult___init, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__177)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[13]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_19_TargetParserResult_1__init__, 0, __pyx_n_s_TargetParserResult___init, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__178)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[13]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_init, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[13]; __pyx_lineno = 10; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
* b"Number encoding",
* b"Unfinished literal",
*/
- __Pyx_INCREF(__pyx_tuple__192);
+ __Pyx_INCREF(__pyx_tuple__193);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree_LIBXML2_XPATH_ERROR_MESSAGES);
- __Pyx_DECREF_SET(__pyx_v_4lxml_5etree_LIBXML2_XPATH_ERROR_MESSAGES, __pyx_tuple__192);
- __Pyx_GIVEREF(__pyx_tuple__192);
+ __Pyx_DECREF_SET(__pyx_v_4lxml_5etree_LIBXML2_XPATH_ERROR_MESSAGES, __pyx_tuple__193);
+ __Pyx_GIVEREF(__pyx_tuple__193);
/* "src/lxml/extensions.pxi":426
*
* return self._parent
*
*/
- __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_20_ElementStringResult_1getparent, 0, __pyx_n_s_ElementStringResult_getparent, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__196)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __Pyx_CyFunction_NewEx(&__pyx_mdef_4lxml_5etree_20_ElementStringResult_1getparent, 0, __pyx_n_s_ElementStringResult_getparent, NULL, __pyx_n_s_lxml_etree, __pyx_d, ((PyObject *)__pyx_codeobj__197)); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_9);
if (PyObject_SetItem(__pyx_t_7, __pyx_n_s_getparent, __pyx_t_9) < 0) {__pyx_filename = __pyx_f[8]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
*/
__pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_compile); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
- __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_16, __pyx_tuple__200, NULL); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_16, __pyx_tuple__201, NULL); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_15);
__Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
__pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_t_15, __pyx_n_s_sub); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 467; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
*/
__pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_compile); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
- __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_16, __pyx_tuple__202, NULL); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_16, __pyx_tuple__203, NULL); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_15);
__Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
__pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_t_15, __pyx_n_s_findall); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[18]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
PyType_Modified(__pyx_ptype_4lxml_5etree_XSLT);
- /* "src/lxml/xslt.pxi":827
+ /* "src/lxml/xslt.pxi":829
* # functions like "output" and "write" are a potential security risk, but we
* # rely on the user to configure XSLTAccessControl as needed
* xslt.xsltRegisterAllExtras() # <<<<<<<<<<<<<<
*/
xsltRegisterAllExtras();
- /* "src/lxml/xslt.pxi":830
+ /* "src/lxml/xslt.pxi":832
*
* # enable EXSLT support for XSLT
* xslt.exsltRegisterAll() # <<<<<<<<<<<<<<
*/
exsltRegisterAll();
- /* "src/lxml/xslt.pxi":836
+ /* "src/lxml/xslt.pxi":838
* # XSLT PI support
*
* cdef object _RE_PI_HREF = re.compile(ur'\s+href\s*=\s*(?:\'([^\']*)\'|"([^"]*)")') # <<<<<<<<<<<<<<
* cdef object _FIND_PI_HREF = _RE_PI_HREF.findall
* cdef object _REPLACE_PI_HREF = _RE_PI_HREF.sub
*/
- __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_compile); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree_re, __pyx_n_s_compile); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_15);
- __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_15, __pyx_tuple__207, NULL); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 836; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_15, __pyx_tuple__208, NULL); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
__Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0;
__Pyx_XGOTREF(__pyx_v_4lxml_5etree__RE_PI_HREF);
__Pyx_GIVEREF(__pyx_t_16);
__pyx_t_16 = 0;
- /* "src/lxml/xslt.pxi":837
+ /* "src/lxml/xslt.pxi":839
*
* cdef object _RE_PI_HREF = re.compile(ur'\s+href\s*=\s*(?:\'([^\']*)\'|"([^"]*)")')
* cdef object _FIND_PI_HREF = _RE_PI_HREF.findall # <<<<<<<<<<<<<<
* cdef object _REPLACE_PI_HREF = _RE_PI_HREF.sub
* cdef XPath __findStylesheetByID = None
*/
- __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__RE_PI_HREF, __pyx_n_s_findall); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 837; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__RE_PI_HREF, __pyx_n_s_findall); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 839; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree__FIND_PI_HREF);
__Pyx_DECREF_SET(__pyx_v_4lxml_5etree__FIND_PI_HREF, __pyx_t_16);
__Pyx_GIVEREF(__pyx_t_16);
__pyx_t_16 = 0;
- /* "src/lxml/xslt.pxi":838
+ /* "src/lxml/xslt.pxi":840
* cdef object _RE_PI_HREF = re.compile(ur'\s+href\s*=\s*(?:\'([^\']*)\'|"([^"]*)")')
* cdef object _FIND_PI_HREF = _RE_PI_HREF.findall
* cdef object _REPLACE_PI_HREF = _RE_PI_HREF.sub # <<<<<<<<<<<<<<
* cdef XPath __findStylesheetByID = None
*
*/
- __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__RE_PI_HREF, __pyx_n_s_sub); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 838; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_4lxml_5etree__RE_PI_HREF, __pyx_n_s_sub); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 840; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
__Pyx_XGOTREF(__pyx_v_4lxml_5etree__REPLACE_PI_HREF);
__Pyx_DECREF_SET(__pyx_v_4lxml_5etree__REPLACE_PI_HREF, __pyx_t_16);
__Pyx_GIVEREF(__pyx_t_16);
__pyx_t_16 = 0;
- /* "src/lxml/xslt.pxi":839
+ /* "src/lxml/xslt.pxi":841
* cdef object _FIND_PI_HREF = _RE_PI_HREF.findall
* cdef object _REPLACE_PI_HREF = _RE_PI_HREF.sub
* cdef XPath __findStylesheetByID = None # <<<<<<<<<<<<<<
__Pyx_DECREF_SET(__pyx_v_4lxml_5etree___findStylesheetByID, ((struct __pyx_obj_4lxml_5etree_XPath *)Py_None));
__Pyx_GIVEREF(Py_None);
- /* "src/lxml/lxml.etree.pyx":3336
+ /* "src/lxml/lxml.etree.pyx":3345
* # Validation
*
* class DocumentInvalid(LxmlError): # <<<<<<<<<<<<<<
* u"""Validation error.
*
*/
- __pyx_t_16 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlError); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_16 = __Pyx_GetModuleGlobalName(__pyx_n_s_LxmlError); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3345; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
- __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3345; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_15);
PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_16);
__Pyx_GIVEREF(__pyx_t_16);
__pyx_t_16 = 0;
- __pyx_t_16 = __Pyx_CalculateMetaclass(NULL, __pyx_t_15); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_16 = __Pyx_CalculateMetaclass(NULL, __pyx_t_15); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3345; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
- __pyx_t_7 = __Pyx_Py3MetaclassPrepare(__pyx_t_16, __pyx_t_15, __pyx_n_s_DocumentInvalid, __pyx_n_s_DocumentInvalid, (PyObject *) NULL, __pyx_n_s_lxml_etree, __pyx_kp_s_Validation_error_Raised_by_all_d); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = __Pyx_Py3MetaclassPrepare(__pyx_t_16, __pyx_t_15, __pyx_n_s_DocumentInvalid, __pyx_n_s_DocumentInvalid, (PyObject *) NULL, __pyx_n_s_lxml_etree, __pyx_kp_s_Validation_error_Raised_by_all_d); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3345; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
- __pyx_t_1 = __Pyx_Py3ClassCreate(__pyx_t_16, __pyx_n_s_DocumentInvalid, __pyx_t_15, __pyx_t_7, NULL, 0, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = __Pyx_Py3ClassCreate(__pyx_t_16, __pyx_n_s_DocumentInvalid, __pyx_t_15, __pyx_t_7, NULL, 0, 1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3345; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- if (PyDict_SetItem(__pyx_d, __pyx_n_s_DocumentInvalid, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3336; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_d, __pyx_n_s_DocumentInvalid, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 3345; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
__Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
* u"boolean(//xs:attribute[@default or @fixed][1])",
* namespaces={u'xs': u'http://www.w3.org/2001/XMLSchema'})
*/
- __pyx_t_15 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPath)), __pyx_tuple__208, __pyx_t_16); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[22]; __pyx_lineno = 22; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_15 = __Pyx_PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_4lxml_5etree_XPath)), __pyx_tuple__209, __pyx_t_16); if (unlikely(!__pyx_t_15)) {__pyx_filename = __pyx_f[22]; __pyx_lineno = 22; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_15);
__Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
__Pyx_XGOTREF(((PyObject *)__pyx_v_4lxml_5etree__check_for_default_attributes));
*/
__pyx_t_16 = PyDict_New(); if (unlikely(!__pyx_t_16)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_16);
- if (PyDict_SetItem(__pyx_t_16, __pyx_kp_u_XML_line_3049, __pyx_kp_u_XML_text_parser_None_base_url_No) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_t_16, __pyx_kp_u_XML_line_3058, __pyx_kp_u_XML_text_parser_None_base_url_No) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
if (PyDict_SetItem(__pyx_d, __pyx_n_s_test_2, __pyx_t_16) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0;
Py_CLEAR(__pyx_tuple__21);
Py_CLEAR(__pyx_tuple__23);
Py_CLEAR(__pyx_tuple__24);
- Py_CLEAR(__pyx_tuple__27);
Py_CLEAR(__pyx_tuple__28);
Py_CLEAR(__pyx_tuple__29);
- Py_CLEAR(__pyx_slice__31);
+ Py_CLEAR(__pyx_tuple__30);
Py_CLEAR(__pyx_slice__32);
Py_CLEAR(__pyx_slice__33);
Py_CLEAR(__pyx_slice__34);
- Py_CLEAR(__pyx_tuple__37);
+ Py_CLEAR(__pyx_slice__35);
Py_CLEAR(__pyx_tuple__38);
Py_CLEAR(__pyx_tuple__39);
Py_CLEAR(__pyx_tuple__40);
Py_CLEAR(__pyx_tuple__41);
Py_CLEAR(__pyx_tuple__42);
Py_CLEAR(__pyx_tuple__43);
- Py_CLEAR(__pyx_slice__44);
- Py_CLEAR(__pyx_tuple__45);
- Py_CLEAR(__pyx_slice__46);
- Py_CLEAR(__pyx_tuple__48);
+ Py_CLEAR(__pyx_tuple__44);
+ Py_CLEAR(__pyx_slice__45);
+ Py_CLEAR(__pyx_tuple__46);
+ Py_CLEAR(__pyx_slice__47);
Py_CLEAR(__pyx_tuple__49);
Py_CLEAR(__pyx_tuple__50);
Py_CLEAR(__pyx_tuple__51);
- Py_CLEAR(__pyx_tuple__58);
+ Py_CLEAR(__pyx_tuple__52);
Py_CLEAR(__pyx_tuple__59);
Py_CLEAR(__pyx_tuple__60);
Py_CLEAR(__pyx_tuple__61);
- Py_CLEAR(__pyx_tuple__63);
- Py_CLEAR(__pyx_tuple__67);
- Py_CLEAR(__pyx_slice__68);
+ Py_CLEAR(__pyx_tuple__62);
+ Py_CLEAR(__pyx_tuple__64);
+ Py_CLEAR(__pyx_tuple__68);
Py_CLEAR(__pyx_slice__69);
- Py_CLEAR(__pyx_tuple__70);
- Py_CLEAR(__pyx_slice__71);
- Py_CLEAR(__pyx_tuple__73);
+ Py_CLEAR(__pyx_slice__70);
+ Py_CLEAR(__pyx_tuple__71);
+ Py_CLEAR(__pyx_slice__72);
Py_CLEAR(__pyx_tuple__74);
Py_CLEAR(__pyx_tuple__75);
Py_CLEAR(__pyx_tuple__76);
Py_CLEAR(__pyx_tuple__83);
Py_CLEAR(__pyx_tuple__84);
Py_CLEAR(__pyx_tuple__85);
- Py_CLEAR(__pyx_slice__86);
+ Py_CLEAR(__pyx_tuple__86);
Py_CLEAR(__pyx_slice__87);
- Py_CLEAR(__pyx_tuple__88);
+ Py_CLEAR(__pyx_slice__88);
Py_CLEAR(__pyx_tuple__89);
Py_CLEAR(__pyx_tuple__90);
- Py_CLEAR(__pyx_slice__91);
- Py_CLEAR(__pyx_tuple__92);
- Py_CLEAR(__pyx_tuple__94);
+ Py_CLEAR(__pyx_tuple__91);
+ Py_CLEAR(__pyx_slice__92);
+ Py_CLEAR(__pyx_tuple__93);
Py_CLEAR(__pyx_tuple__95);
Py_CLEAR(__pyx_tuple__96);
Py_CLEAR(__pyx_tuple__97);
Py_CLEAR(__pyx_tuple__104);
Py_CLEAR(__pyx_tuple__105);
Py_CLEAR(__pyx_tuple__106);
- Py_CLEAR(__pyx_codeobj__107);
- Py_CLEAR(__pyx_tuple__108);
- Py_CLEAR(__pyx_codeobj__109);
- Py_CLEAR(__pyx_tuple__110);
- Py_CLEAR(__pyx_codeobj__111);
- Py_CLEAR(__pyx_tuple__112);
- Py_CLEAR(__pyx_codeobj__113);
- Py_CLEAR(__pyx_tuple__114);
- Py_CLEAR(__pyx_codeobj__115);
- Py_CLEAR(__pyx_tuple__116);
- Py_CLEAR(__pyx_codeobj__117);
- Py_CLEAR(__pyx_tuple__118);
+ Py_CLEAR(__pyx_tuple__107);
+ Py_CLEAR(__pyx_codeobj__108);
+ Py_CLEAR(__pyx_tuple__109);
+ Py_CLEAR(__pyx_codeobj__110);
+ Py_CLEAR(__pyx_tuple__111);
+ Py_CLEAR(__pyx_codeobj__112);
+ Py_CLEAR(__pyx_tuple__113);
+ Py_CLEAR(__pyx_codeobj__114);
+ Py_CLEAR(__pyx_tuple__115);
+ Py_CLEAR(__pyx_codeobj__116);
+ Py_CLEAR(__pyx_tuple__117);
+ Py_CLEAR(__pyx_codeobj__118);
Py_CLEAR(__pyx_tuple__119);
Py_CLEAR(__pyx_tuple__120);
- Py_CLEAR(__pyx_codeobj__121);
- Py_CLEAR(__pyx_tuple__122);
- Py_CLEAR(__pyx_codeobj__123);
- Py_CLEAR(__pyx_tuple__124);
+ Py_CLEAR(__pyx_tuple__121);
+ Py_CLEAR(__pyx_codeobj__122);
+ Py_CLEAR(__pyx_tuple__123);
+ Py_CLEAR(__pyx_codeobj__124);
Py_CLEAR(__pyx_tuple__125);
- Py_CLEAR(__pyx_codeobj__126);
- Py_CLEAR(__pyx_tuple__127);
+ Py_CLEAR(__pyx_tuple__126);
+ Py_CLEAR(__pyx_codeobj__127);
Py_CLEAR(__pyx_tuple__128);
- Py_CLEAR(__pyx_codeobj__129);
- Py_CLEAR(__pyx_tuple__130);
+ Py_CLEAR(__pyx_tuple__129);
+ Py_CLEAR(__pyx_codeobj__130);
Py_CLEAR(__pyx_tuple__131);
Py_CLEAR(__pyx_tuple__132);
Py_CLEAR(__pyx_tuple__133);
Py_CLEAR(__pyx_tuple__134);
- Py_CLEAR(__pyx_codeobj__135);
- Py_CLEAR(__pyx_tuple__136);
- Py_CLEAR(__pyx_codeobj__137);
- Py_CLEAR(__pyx_tuple__138);
- Py_CLEAR(__pyx_codeobj__139);
- Py_CLEAR(__pyx_tuple__140);
- Py_CLEAR(__pyx_codeobj__141);
- Py_CLEAR(__pyx_tuple__142);
- Py_CLEAR(__pyx_codeobj__143);
- Py_CLEAR(__pyx_tuple__144);
- Py_CLEAR(__pyx_codeobj__145);
- Py_CLEAR(__pyx_tuple__146);
- Py_CLEAR(__pyx_codeobj__147);
- Py_CLEAR(__pyx_tuple__148);
- Py_CLEAR(__pyx_codeobj__149);
- Py_CLEAR(__pyx_tuple__150);
- Py_CLEAR(__pyx_codeobj__151);
- Py_CLEAR(__pyx_tuple__152);
- Py_CLEAR(__pyx_codeobj__153);
- Py_CLEAR(__pyx_tuple__154);
- Py_CLEAR(__pyx_codeobj__155);
- Py_CLEAR(__pyx_tuple__156);
- Py_CLEAR(__pyx_codeobj__157);
- Py_CLEAR(__pyx_tuple__158);
- Py_CLEAR(__pyx_codeobj__159);
- Py_CLEAR(__pyx_tuple__160);
- Py_CLEAR(__pyx_codeobj__161);
- Py_CLEAR(__pyx_tuple__162);
- Py_CLEAR(__pyx_codeobj__163);
- Py_CLEAR(__pyx_tuple__164);
- Py_CLEAR(__pyx_codeobj__165);
- Py_CLEAR(__pyx_tuple__166);
- Py_CLEAR(__pyx_codeobj__167);
- Py_CLEAR(__pyx_tuple__168);
- Py_CLEAR(__pyx_codeobj__169);
- Py_CLEAR(__pyx_tuple__170);
- Py_CLEAR(__pyx_codeobj__171);
- Py_CLEAR(__pyx_tuple__172);
- Py_CLEAR(__pyx_codeobj__173);
+ Py_CLEAR(__pyx_tuple__135);
+ Py_CLEAR(__pyx_codeobj__136);
+ Py_CLEAR(__pyx_tuple__137);
+ Py_CLEAR(__pyx_codeobj__138);
+ Py_CLEAR(__pyx_tuple__139);
+ Py_CLEAR(__pyx_codeobj__140);
+ Py_CLEAR(__pyx_tuple__141);
+ Py_CLEAR(__pyx_codeobj__142);
+ Py_CLEAR(__pyx_tuple__143);
+ Py_CLEAR(__pyx_codeobj__144);
+ Py_CLEAR(__pyx_tuple__145);
+ Py_CLEAR(__pyx_codeobj__146);
+ Py_CLEAR(__pyx_tuple__147);
+ Py_CLEAR(__pyx_codeobj__148);
+ Py_CLEAR(__pyx_tuple__149);
+ Py_CLEAR(__pyx_codeobj__150);
+ Py_CLEAR(__pyx_tuple__151);
+ Py_CLEAR(__pyx_codeobj__152);
+ Py_CLEAR(__pyx_tuple__153);
+ Py_CLEAR(__pyx_codeobj__154);
+ Py_CLEAR(__pyx_tuple__155);
+ Py_CLEAR(__pyx_codeobj__156);
+ Py_CLEAR(__pyx_tuple__157);
+ Py_CLEAR(__pyx_codeobj__158);
+ Py_CLEAR(__pyx_tuple__159);
+ Py_CLEAR(__pyx_codeobj__160);
+ Py_CLEAR(__pyx_tuple__161);
+ Py_CLEAR(__pyx_codeobj__162);
+ Py_CLEAR(__pyx_tuple__163);
+ Py_CLEAR(__pyx_codeobj__164);
+ Py_CLEAR(__pyx_tuple__165);
+ Py_CLEAR(__pyx_codeobj__166);
+ Py_CLEAR(__pyx_tuple__167);
+ Py_CLEAR(__pyx_codeobj__168);
+ Py_CLEAR(__pyx_tuple__169);
+ Py_CLEAR(__pyx_codeobj__170);
+ Py_CLEAR(__pyx_tuple__171);
+ Py_CLEAR(__pyx_codeobj__172);
+ Py_CLEAR(__pyx_tuple__173);
Py_CLEAR(__pyx_codeobj__174);
- Py_CLEAR(__pyx_tuple__175);
+ Py_CLEAR(__pyx_codeobj__175);
Py_CLEAR(__pyx_tuple__176);
- Py_CLEAR(__pyx_codeobj__177);
- Py_CLEAR(__pyx_tuple__178);
- Py_CLEAR(__pyx_codeobj__179);
- Py_CLEAR(__pyx_tuple__180);
- Py_CLEAR(__pyx_codeobj__181);
- Py_CLEAR(__pyx_tuple__182);
- Py_CLEAR(__pyx_codeobj__183);
- Py_CLEAR(__pyx_tuple__184);
- Py_CLEAR(__pyx_codeobj__185);
- Py_CLEAR(__pyx_tuple__186);
- Py_CLEAR(__pyx_codeobj__187);
- Py_CLEAR(__pyx_tuple__188);
- Py_CLEAR(__pyx_codeobj__189);
- Py_CLEAR(__pyx_tuple__190);
- Py_CLEAR(__pyx_codeobj__191);
- Py_CLEAR(__pyx_tuple__192);
+ Py_CLEAR(__pyx_tuple__177);
+ Py_CLEAR(__pyx_codeobj__178);
+ Py_CLEAR(__pyx_tuple__179);
+ Py_CLEAR(__pyx_codeobj__180);
+ Py_CLEAR(__pyx_tuple__181);
+ Py_CLEAR(__pyx_codeobj__182);
+ Py_CLEAR(__pyx_tuple__183);
+ Py_CLEAR(__pyx_codeobj__184);
+ Py_CLEAR(__pyx_tuple__185);
+ Py_CLEAR(__pyx_codeobj__186);
+ Py_CLEAR(__pyx_tuple__187);
+ Py_CLEAR(__pyx_codeobj__188);
+ Py_CLEAR(__pyx_tuple__189);
+ Py_CLEAR(__pyx_codeobj__190);
+ Py_CLEAR(__pyx_tuple__191);
+ Py_CLEAR(__pyx_codeobj__192);
Py_CLEAR(__pyx_tuple__193);
- Py_CLEAR(__pyx_codeobj__194);
- Py_CLEAR(__pyx_tuple__195);
- Py_CLEAR(__pyx_codeobj__196);
- Py_CLEAR(__pyx_tuple__197);
- Py_CLEAR(__pyx_codeobj__198);
- Py_CLEAR(__pyx_tuple__200);
- Py_CLEAR(__pyx_tuple__202);
+ Py_CLEAR(__pyx_tuple__194);
+ Py_CLEAR(__pyx_codeobj__195);
+ Py_CLEAR(__pyx_tuple__196);
+ Py_CLEAR(__pyx_codeobj__197);
+ Py_CLEAR(__pyx_tuple__198);
+ Py_CLEAR(__pyx_codeobj__199);
+ Py_CLEAR(__pyx_tuple__201);
Py_CLEAR(__pyx_tuple__203);
- Py_CLEAR(__pyx_codeobj__204);
- Py_CLEAR(__pyx_tuple__205);
- Py_CLEAR(__pyx_codeobj__206);
- Py_CLEAR(__pyx_tuple__207);
+ Py_CLEAR(__pyx_tuple__204);
+ Py_CLEAR(__pyx_codeobj__205);
+ Py_CLEAR(__pyx_tuple__206);
+ Py_CLEAR(__pyx_codeobj__207);
Py_CLEAR(__pyx_tuple__208);
+ Py_CLEAR(__pyx_tuple__209);
if (__pyx_code_cache.entries) {
__Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
int i, count = __pyx_code_cache.count;
}
#endif
+static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname) {
+ PyErr_Format(PyExc_UnboundLocalError, "local variable '%s' referenced before assignment", varname);
+}
+
static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) {
#if CYTHON_COMPILING_IN_PYPY
return PyObject_RichCompareBool(s1, s2, equals);
return NULL;
}
-static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname) {
- PyErr_Format(PyExc_UnboundLocalError, "local variable '%s' referenced before assignment", varname);
-}
-
static void __Pyx_UnpackTupleError(PyObject *t, Py_ssize_t index) {
if (t == Py_None) {
__Pyx_RaiseNoneNotIterableError();