<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>29568</bug_id>
          
          <creation_ts>2016-04-10 21:03:29 +0000</creation_ts>
          <short_desc>[XQX3.1] Incorrect XQueryX conversion of &quot;\u005c&quot;</short_desc>
          <delta_ts>2016-04-16 14:27:17 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>XPath / XQuery / XSLT</product>
          <component>XQueryX 3.1</component>
          <version>Candidate Recommendation</version>
          <rep_platform>PC</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>13796</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Michael Kay">mike</reporter>
          <assigned_to name="Josh Spiegel">josh.spiegel</assigned_to>
          <cc>andrew_coleman</cc>
    
    <cc>jmdyck</cc>
          
          <qa_contact name="Mailing list for public feedback on specs from XSL and XML Query WGs">public-qt-comments</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>125792</commentid>
    <comment_count>0</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2016-04-10 21:03:29 +0000</bug_when>
    <thetext>Test case json-to-xml-043 reads:

fn:json-to-xml(&apos;&quot;\u005c&quot;&apos;)

In the XQueryX version of the test, the function call is represented as:

      &lt;xqx:functionCallExpr&gt;
        &lt;xqx:functionName xqx:prefix=&quot;fn&quot;&gt;json-to-xml&lt;/xqx:functionName&gt;
        &lt;xqx:arguments&gt;
          &lt;xqx:stringConstantExpr&gt;
            &lt;xqx:value&gt;&quot;\&quot;&lt;/xqx:value&gt;
          &lt;/xqx:stringConstantExpr&gt;
        &lt;/xqx:arguments&gt;
      &lt;/xqx:functionCallExpr&gt;

The conversion from XQuery to XQueryX appears to be incorrect. &quot;\u005c&quot; is a valid JSON string, whereas &quot;\&quot; is not.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>125793</commentid>
    <comment_count>1</comment_count>
    <who name="Michael Dyck">jmdyck</who>
    <bug_when>2016-04-10 22:23:40 +0000</bug_when>
    <thetext>This might be a duplicate of Bug 13796.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>125873</commentid>
    <comment_count>2</comment_count>
    <who name="Josh Spiegel">josh.spiegel</who>
    <bug_when>2016-04-15 20:39:32 +0000</bug_when>
    <thetext>Yes, this is a duplicate of 13796 - the w3c parser is converting \uXXXX to a character in string literals.

There are other tests besides json-to-xml-043 where this happens (e.g. json-to-xml-021, json-to-xml-022, json-to-xml-042, etc.).  You may only be noticing in this case since \u005c is the backslash and converting it makes the JSON invalid (in other cases the string is still valid JSON).

*** This bug has been marked as a duplicate of bug 13796 ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>125884</commentid>
    <comment_count>3</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2016-04-16 14:27:17 +0000</bug_when>
    <thetext>Yes, that was the first test case where I noticed the effect, but I noticed others later.

I guess that we&apos;ve established that the problem is not with the spec; it&apos;s a problem with the W3C parsing applet which in turn causes a problem with the XQueryX version of the tests.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>