|The stupid question is the question not asked|
Re^7: XML::XSLT problemby gellyfish (Monsignor)
|on Nov 17, 2006 at 21:21 UTC||Need Help??|
XML::XSLT should just ignore the fo stuff, though that isn't being tested.
But yes you have uncovered a bug in a code path which wasn't being tested. Basically the problem is with an outer <xsl:variable /> declaration where there is a literal value (like you have there) rather than supplied with a value attribute. It needs to create a document fragment to store the results of evaluating the literal value and createDocumentFragment() needs to be called as a method of the XML::DOM::Document object, but as the top level variables are evaluated on the first parse of the XSL document there isn't an XML::DOM::Document yet :-(.
The bottom line is that whilst your example above could quite happily be expressed as:
I can't promise a quick fix that does the right thing as surprisingly it's going to require quite a large change, You might want to check out the version in CVS but that cheats with the document fragment and elicits a warning from XML::DOM and also doesn't respect any XML in the variable value but YMMV. Caveat Emptor etc etc.
But I have a test for this now so it will get fixed eventually
Thanks for the bug report, sorry I can't help you straight away.