Hello everybody,<br>
<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"> I assume that your real stylesheet creates a result tree<br>
fragment for the variable that you pass into your function.</blockquote><div>To be frank - it's not like that. We used variables just as function parameters (e.g. a float number). But using a tree is a very powerful feature, too. </div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Please give it a try (after installing<br>
Cython 0.10).</blockquote><div></div><div>lxml.etree: (2, 2, -199, 59835)<br>libxml used: (2, 6, 30)<br>libxml compiled: (2, 6, 30)<br>libxslt used: (1, 1, 22)<br>libxslt compiled: (1, 1, 22)<br></div>
<div></div><div>I've attached the test source. In brief - it works :) I tried to test the variable as a number literal, as a string and as a tree. I got expected results in all cases.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
It would be nice if you could come up with a couple of additional test cases<br>
for test_xslt.py to make sure this works (and continues to work) as expected<br>
for different variable values or <xsl:copy-of> scenarios. Currently, there is<br>
only test_variable_result_tree_fragment(), which tests for result trees<br>
returned by <xsl:apply-templates/>.</blockquote><div>I'll try to - sorry, nothing has came up to my mind yet. Maybe we'll encounter some tricky cases in our templates, then I'll report them.</div><div></div>
<div>Cheers,</div><div>Dmitri</div></div>