With XPath/XQuery 3.0 enabled, Saxon supports partial function application - a function call with placeholders, such as contains(?, 'abc'). This is failing with a type error if the placeholder is used for an argument that does not accept an empty sequence as a valid value. The error occurs because Saxon temporarily constructs a function call in which () is supplied as the parameter value, and although this function call is never evaluated, it is type-checked. A patch will be committed on the 9.3 branch. Affects Saxon-EE only.