NullPointerException with a stylesheet trying to output a map
Added by Martin Honnen over 8 years ago
The stylesheet
when run with Saxon 9.7.0.5 EE and HE causes a NullPointerException, the complete stack trace is
java.lang.NullPointerException at net.sf.saxon.type.TypeHierarchy.relationship(TypeHierarchy.java:298) at net.sf.saxon.type.TypeHierarchy.isSubType(TypeHierarchy.java:280) at net.sf.saxon.expr.AtomicSequenceConverter.typeCheck(AtomicSequenceConverter.java:152) at net.sf.saxon.expr.Operand.typeCheck(Operand.java:185) at net.sf.saxon.expr.Expression.typeCheckChildren(Expression.java:428) at net.sf.saxon.expr.SystemFunctionCall.typeCheck(SystemFunctionCall.java:82) at net.sf.saxon.expr.Operand.typeCheck(Operand.java:185) at net.sf.saxon.expr.Expression.typeCheckChildren(Expression.java:428) at net.sf.saxon.expr.instruct.SimpleNodeConstructor.typeCheck(SimpleNodeConstructor.java:131) at net.sf.saxon.style.XSLTemplate.optimize(XSLTemplate.java:793) at net.sf.saxon.style.PrincipalStylesheetModule.optimizeTopLevel(PrincipalStylesheetModule.java:1349) at net.sf.saxon.style.PrincipalStylesheetModule.compile(PrincipalStylesheetModule.java:1199) at net.sf.saxon.style.Compilation.compilePackage(Compilation.java:245) at net.sf.saxon.style.StylesheetModule.loadStylesheet(StylesheetModule.java:260) at net.sf.saxon.style.Compilation.compileSingletonPackage(Compilation.java:101) at net.sf.saxon.s9api.XsltCompiler.compile(XsltCompiler.java:839) at net.sf.saxon.Transform.doTransform(Transform.java:727) at net.sf.saxon.Transform.main(Transform.java:77)
It probably does not make sense to try to output a map with the output method @xml@ but I guess the null pointer exception is not intended, if I simply use a stylesheet doing
then I get an error saying "FOTY0013: Cannot atomize a function item", I presume a similar error message should be output with the first stylesheet instead of a NullPointerException.
Replies (1)
RE: NullPointerException with a stylesheet trying to output a map - Added by Michael Kay over 8 years ago
Thanks, please track resolution here:
Please register to reply