#843 Extensions expecting Item

v9.1
closed
5
2012-10-08
2008-07-09
Michael Kay
No

Saxon reports a runtime error when attempting to call an extension function whose supporting method has a parameter declared as being of type net.sf.saxon.om.Item. Although the documentation does not list this as one of the recognized parameter types, previous releases allowed it.

The message is "Cannot convert value of type XXXX to class interface net.sf.saxon.om.Item"

A patch is being placed in Subversion, and the documentation will be changed to indicate that this is an acceptable mapping.

Discussion

  • Michael Kay

    Michael Kay - 2008-07-11

    Logged In: YES
    user_id=251681
    Originator: YES

    A further patch is being placed in Subversion to handle the case where the expected type is Item and the supplied value is an empty sequence; in this case the value supplied should be null.

    Note that this bug prevents the extension function saxon:type-annotation() working.

     
  • Michael Kay

    Michael Kay - 2008-09-02

    Logged In: YES
    user_id=251681
    Originator: YES

    Fixed in 9.1.0.2