# Defects cleared in Version 8.0

966590 With the HTML output method, characters in strings produced using character maps are subjected to escaping

965882 Applications using the Java API to access namespaced attributes in a standard tree may get incorrect answers or failures

962737 When non-standard prefixes are used for standard namespaces in the result document (e.g. the XSLT namespace), Saxon may serialize them incorrectly.

962068 Casting xs:integer to xs:long returns the original xs:integer unchanged.

959979 The distinct-values() function may fail with a ClassCastException when processing a heterogeous sequence.

959940 In XQuery, unpredictable errors occur if global variables are declared in multiple query modules.

957362 In XSLT, xsl:fallback instructions within unrecognized extension elements are not properly validated.

949841 In XQuery, declaring a variable in the default clause of a typeswitch expression does not work.

949840 When objects such as variables or parameters are defined in a reserved namespace, the error is not always reported correctly.

949839 Space stripping (xsl:strip-space) does not work correctly when input is supplied in the form of a pre-built tree (DOMSource, JDOM, etc).

940778 When buiding a result tree, adjacent text nodes are not merged.

940227 When using a DOMSource, unprefixed attributes are assumed to be in the default namespace rather than the null namespace.

938531 In XQuery, a namespace prefix declared in the prolog takes precedence over one declared in an element constructor.

938530 In XQuery, an element constructor of the form <a>{1}{2}</a> causes a spurious space character to be output.

932417 In XQuery, the default collation specified in the prolog is ignored.

931599 With xs:decimal operands, the expression `A mod B` gives the wrong answer if A is less than B.

930902 In XSLT, the checks that parameters in `xsl:call-template` match the parameters in the template being called incorrectly take account of tunnel parameters.

927409 The `saxon:evaluate()` function fails if the expression uses local variables and is used in a context such as `xsl:for-each` where lazy evaluation occurs.

927057 Under particular conditions an invalid type annotation (numeric zero) can be attached to a node.

926727 In XQuery, the "empty greatest/least" functionality in `order by` does not work.

Next