Project

Profile

Help

Bug #2483

Updated by O'Neil Delpratt about 9 years ago

Bug initially reported by Rik Smithies: 

 I have XSLT code that uses the saxon:type extension, to get the schema aware type of an element, and put that as a comment into the output. 

 It works in Oxygen 17, which has Saxon built in. But when I tried it in the java and .net command line versions of Saxon, I had some issues. 

 The exception thrown in Saxon 9.6: thrown: 


 <pre> 
 Error on line 17 of saxontest.xsl: 
   jt:java.lang.NullPointerException: Exception thrown by extension function {public static 
   net.sf.saxon.om.ZeroOrOne 
   com.saxonica.functions.extfn.Extensions.typeAnnotation(net.sf.saxon.expr.XPathContext,net.sf.saxon.om.ZeroOrOne)}: java.lang.NullPointerException 
   in built-in template rule 
 Exception thrown by extension function {public static net.sf.saxon.om.ZeroOrOne com.saxonica.functions.extfn.Extensions.typeAnnotation(net.sf.saxon.expr.XPathContext,net.sf.saxon.om.ZeroOrOne)}: java.lang.NullPointerException 
 </pre> 


 In Saxon 9.5 we get the following exception: 

 <pre> 
 Error on line 17 of saxontest.xsl: 
   jt:java.lang.NullPointerException: Exception thrown by extension function {public static 
   net.sf.saxon.value.QNameValue 
   com.saxonica.functions.extfn.Extensions.typeAnnotation(net.sf.saxon.expr.XPathContext,net.sf.saxon.om.Item)}: java.lang.NullPointerException 
 Transformation failed: Run-time errors were reported 
 </pre>

Back