This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
<test-case name="fn-parse-json-110" xmlns="http://www.w3.org/2010/09/qt-fots-catalog"> <created by="Michael Kay" on="2016-09-29"/> <test><![CDATA[parse-json('{"'||codepoints-to-string((10, 37))||'":"x", "\n%":"y"}', map{'escape':true(), 'duplicates':'reject'})]]></test> <result> <error code="FOJS0003"/> </result> </test-case> The input to parse-json is not a valid JSON text. From RFC7159: <quote> All Unicode characters may be placed within the quotation marks, except for the characters that must be escaped: quotation mark, reverse solidus, and the control characters (U+0000 through U+001F). </quote> Therefore, passing a naked control character should raise FOJS0001.
The WG agreed the following resolution: ACTION A-657-15: O'Neil to fix the tests mentioned in this bug report, fn-parse-json-110, bug 29934
I have split the test into two, one testing for duplicates with the original intent, and one testing that raw control characters are rejected.