From e4ab1755276a247aab0d525a2701a5126add31dc Mon Sep 17 00:00:00 2001 From: David Lichteblau Date: Sun, 27 Apr 2008 14:32:17 +0200 Subject: [PATCH] Fixed non-strings in format-number --- TEST | 105 ++++++++++++++++++----------------------------------- format-number.lisp | 2 +- test.lisp | 4 ++ xslt.lisp | 2 +- 4 files changed, 41 insertions(+), 72 deletions(-) diff --git a/TEST b/TEST index 9ad6a2a..5393cb5 100644 --- a/TEST +++ b/TEST @@ -15106,31 +15106,37 @@ PASS Namespace-alias_NSAlias_Inside_CallTemplate [XSLT-Structure] Expected output (1): MSFT_Conformance_Tests/Namespace-alias/Namespace-alias_NSAlias_Inside_CallTemplate.saxon Actual output: MSFT_Conformance_Tests/Namespace-alias/Namespace-alias_NSAlias_Inside_CallTemplate.xuriella -FAIL Number__10052 [XSLT-Result-Tree]: The value - #S(XURIELLA::RESULT-TREE-FRAGMENT - :NODE #.(CXML-STP:ELEMENT - #| :PARENT of type DOCUMENT |# - :CHILDREN '(#.(CXML-STP:TEXT - #| :PARENT of type ELEMENT |# - :DATA "foo")) - :LOCAL-NAME "fragment")) - is not of type - (SIMPLE-ARRAY CHARACTER). +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +FAIL Number__10052 [XSLT-Result-Tree]: output doesn't match Stylesheet: MSFT_Conformance_Tests/Number/10052.noindent-xsl Data: MSFT_Conformance_Tests/Number/91021.xml Expected output (1): MSFT_Conformance_Tests/Number/Number__10052.saxon Actual output: MSFT_Conformance_Tests/Number/Number__10052.xuriella -FAIL Number__10053 [XSLT-Result-Tree]: The value - #S(XURIELLA::RESULT-TREE-FRAGMENT - :NODE #.(CXML-STP:ELEMENT - #| :PARENT of type DOCUMENT |# - :CHILDREN '(#.(CXML-STP:TEXT - #| :PARENT of type ELEMENT |# - :DATA "foo")) - :LOCAL-NAME "fragment")) - is not of type - (SIMPLE-ARRAY CHARACTER). +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +WARNING: There is no such encoding: "UTF-16". +FAIL Number__10053 [XSLT-Result-Tree]: output doesn't match Stylesheet: MSFT_Conformance_Tests/Number/10053.noindent-xsl Data: MSFT_Conformance_Tests/Number/91021.xml Expected output (1): MSFT_Conformance_Tests/Number/Number__10053.saxon @@ -18831,12 +18837,6 @@ PASS XSLTFunctions__84048 [Mixed] Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__84048.saxon Actual output: MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__84048.xuriella -FAIL XSLTFunctions__84049 [Mixed]: output doesn't match - Stylesheet: MSFT_Conformance_Tests/XSLTFunctions/84049.noindent-xsl - Data: MSFT_Conformance_Tests/XSLTFunctions/books.xml - Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__84049.saxon - Actual output: MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__84049.xuriella - FAIL XSLTFunctions__84050 [Mixed]: output doesn't match Stylesheet: MSFT_Conformance_Tests/XSLTFunctions/84050.noindent-xsl Data: MSFT_Conformance_Tests/XSLTFunctions/books.xml @@ -18978,17 +18978,9 @@ PASS XSLTFunctions__emptyParameters [Mixed] Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__emptyParameters.saxon Actual output: MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__emptyParameters.xuriella -FAIL XSLTFunctions__EuropeanPattern [Mixed]: condition of incorrect type: -The value - #S(XURIELLA::RESULT-TREE-FRAGMENT - :NODE #.(CXML-STP:ELEMENT - #| :PARENT of type DOCUMENT |# - :CHILDREN '(#.(CXML-STP:TEXT - #| :PARENT of type ELEMENT |# - :DATA "european")) - :LOCAL-NAME "fragment")) -is not of type - (SIMPLE-ARRAY CHARACTER). +WARNING: + comparison failed: Corrupted UTF-8 input (initial byte was #b10001001) +FAIL XSLTFunctions__EuropeanPattern [Mixed]: saxon error not signalled and official output not a match Stylesheet: MSFT_Conformance_Tests/XSLTFunctions/fmt-no-eu.noindent-xsl Data: MSFT_Conformance_Tests/XSLTFunctions/fmt-no.xml Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__EuropeanPattern.saxon @@ -19018,48 +19010,21 @@ FAIL XSLTFunctions__minimumValue [Mixed]: output doesn't match Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__minimumValue.saxon Actual output: MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__minimumValue.xuriella -FAIL XSLTFunctions__Non_DigitPattern [Mixed]: condition of incorrect type: -The value - #S(XURIELLA::RESULT-TREE-FRAGMENT - :NODE #.(CXML-STP:ELEMENT - #| :PARENT of type DOCUMENT |# - :CHILDREN '(#.(CXML-STP:TEXT - #| :PARENT of type ELEMENT |# - :DATA "non_digit")) - :LOCAL-NAME "fragment")) -is not of type - (SIMPLE-ARRAY CHARACTER). +WARNING: + comparison failed: Corrupted UTF-8 input (initial byte was #b10001001) +FAIL XSLTFunctions__Non_DigitPattern [Mixed]: saxon error not signalled and official output not a match Stylesheet: MSFT_Conformance_Tests/XSLTFunctions/fmt-no-nd.noindent-xsl Data: MSFT_Conformance_Tests/XSLTFunctions/fmt-no.xml Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__Non_DigitPattern.saxon Actual output: MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__Non_DigitPattern.xuriella -FAIL XSLTFunctions__Pattern-separator [Mixed]: The value - #S(XURIELLA::RESULT-TREE-FRAGMENT - :NODE #.(CXML-STP:ELEMENT - #| :PARENT of type DOCUMENT |# - :CHILDREN '(#.(CXML-STP:TEXT - #| :PARENT of type ELEMENT |# - :DATA "pattern")) - :LOCAL-NAME "fragment")) - is not of type - (SIMPLE-ARRAY CHARACTER). +FAIL XSLTFunctions__Pattern-separator [Mixed]: output doesn't match Stylesheet: MSFT_Conformance_Tests/XSLTFunctions/fmt-no-pa.noindent-xsl Data: MSFT_Conformance_Tests/XSLTFunctions/fmt-no.xml Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__Pattern-separator.saxon Actual output: MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__Pattern-separator.xuriella -FAIL XSLTFunctions__percentPattern [Mixed]: condition of incorrect type: -The value - #S(XURIELLA::RESULT-TREE-FRAGMENT - :NODE #.(CXML-STP:ELEMENT - #| :PARENT of type DOCUMENT |# - :CHILDREN '(#.(CXML-STP:TEXT - #| :PARENT of type ELEMENT |# - :DATA "percent")) - :LOCAL-NAME "fragment")) -is not of type - (SIMPLE-ARRAY CHARACTER). +FAIL XSLTFunctions__percentPattern [Mixed]: saxon error not signalled and official output not a match Stylesheet: MSFT_Conformance_Tests/XSLTFunctions/fmt-no-pe.noindent-xsl Data: MSFT_Conformance_Tests/XSLTFunctions/fmt-no.xml Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions__percentPattern.saxon @@ -19292,4 +19257,4 @@ PASS XSLTFunctions_DocumentFuncWithEmptyArg [Mixed] Expected output (1): MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions_DocumentFuncWithEmptyArg.saxon Actual output: MSFT_Conformance_Tests/XSLTFunctions/XSLTFunctions_DocumentFuncWithEmptyArg.xuriella -Passed 2983/3070 tests (26 expected failures, 61 unexpected failures). +Passed 2983/3069 tests (26 expected failures, 60 unexpected failures). diff --git a/format-number.lisp b/format-number.lisp index 6b579bb..ff2e0c1 100644 --- a/format-number.lisp +++ b/format-number.lisp @@ -107,7 +107,7 @@ (lambda (ctx) (let ((df (if format-name - (let ((qname (funcall format-name ctx))) + (let ((qname (xpath:string-value (funcall format-name ctx)))) (multiple-value-bind (local-name uri) (decode-qname/runtime qname namespaces nil) (find-decimal-format local-name diff --git a/test.lisp b/test.lisp index 06d1d05..5e55344 100644 --- a/test.lisp +++ b/test.lisp @@ -359,6 +359,10 @@ "ConflictResolution__77833" "Include__77736" + ;; har har + "XSLTFunctions__84049" + "XSLTFunctions__84050" + ;; these test the value of generate-id(), which isn't specified "Keys__91832" "Keys__91833")) diff --git a/xslt.lisp b/xslt.lisp index 9a49f1b..a6192ba 100644 --- a/xslt.lisp +++ b/xslt.lisp @@ -1431,7 +1431,7 @@ "1") ((equal local-name "vendor") "Xuriella") - ((equal local-name "vendor-uri") + ((equal local-name "vendor-url") "http://repo.or.cz/w/xuriella.git") (t "")) -- 2.11.4.GIT