<?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>23594</bug_id>
          
          <creation_ts>2013-10-22 12:56:23 +0000</creation_ts>
          <short_desc>[xslt 3.0] new JSON specification</short_desc>
          <delta_ts>2014-05-15 14:00:39 +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>XSLT 3.0</component>
          <version>Working drafts</version>
          <rep_platform>PC</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <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="Michael Kay">mike</assigned_to>
          <cc>abel.braaksma</cc>
    
    <cc>innovimax+w3c</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>95093</commentid>
    <comment_count>0</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2013-10-22 12:56:23 +0000</bug_when>
    <thetext>We should reference the new JSON specification ECMA-404

http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf

This isn&apos;t just a matter of changing the bibliography, because we allow parse-json to specify which spec it&apos;s dealing with. I don&apos;t know of any significant differences in this version.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96924</commentid>
    <comment_count>1</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2013-11-28 23:07:22 +0000</bug_when>
    <thetext>Because the two specifications are (as far as I can determine) identical, I have simply replaced all references to ECMA-262 with references to ECMA-404, mutatis mutandis.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102018</commentid>
    <comment_count>2</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-03-06 22:29:38 +0000</bug_when>
    <thetext>There is now yet another JSON specification at

http://rfc7159.net/rfc7159</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102053</commentid>
    <comment_count>3</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-03-07 08:36:33 +0000</bug_when>
    <thetext>See also Tim Bray&apos;s blog at

https://www.tbray.org/ongoing/When/201x/2014/03/05/RFC7159-JSON

explaining the rationale for the new RFC.

Since the JSON spec is moving in the direction that other internet specs have followed of containing lots of fuzzy interoperability advice and guidance rather than hard and fast rules, I&apos;m inclined to abandon our attempts to legislate exactly what products should do, and just point them to best practice. It&apos;s not our task to write yet another version of the JSON spec.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102054</commentid>
    <comment_count>4</comment_count>
    <who name="Innovimax">innovimax+w3c</who>
    <bug_when>2014-03-07 09:11:06 +0000</bug_when>
    <thetext>I think you can also add http://json5.org/ to this list</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>102055</commentid>
    <comment_count>5</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-03-07 09:20:30 +0000</bug_when>
    <thetext>Does JSON5 have any official backing or community momentum, or is it just one geek who has appropriated the name for his own private project?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>104366</commentid>
    <comment_count>6</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-04-24 18:43:17 +0000</bug_when>
    <thetext>The XSL WG agreed today that we will reference rfc7159 normatively; we may also include a non-normative reference to Tim Bray&apos;s blog posting. We need to get XQuery WG to agree this is the way forward.

We should remove the &quot;spec&quot; option from the relevant functions that allows the user a choice of which specification to use.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>104428</commentid>
    <comment_count>7</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-04-25 11:02:51 +0000</bug_when>
    <thetext>The change has been applied.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105295</commentid>
    <comment_count>8</comment_count>
    <who name="Abel Braaksma">abel.braaksma</who>
    <bug_when>2014-05-07 11:25:59 +0000</bug_when>
    <thetext>I understand that we now don&apos;t support RFC4627 or ECMA-404 anymore, except as an extension to liberal := yes.

Reopening, because there are still a few references left over that refer to the &quot;spec&quot; option, or refer to the old specifications or old syntax. 

Summarizing:

Validate option:
&quot;or against an implementation-defined schema if the spec option has the value liberal.&quot;

should become:
&quot;or against an implementation-defined schema if the liberal option has the value yes.

Error [ERR XTDE3240] 
&quot;It is a dynamic error if the value of $input does not conform to the JSON grammar, as selected using the explicit or implicit spec option.&quot;

should become:
&quot;It is a dynamic error if the value of $input does not conform to the JSON grammar, as specified by [RFC7159], and when liberal is set to yes.&quot;

Error [ERR XTDE3260] 
&apos;It is a dynamic error if the value of $options includes an entry whose key is &quot;spec&quot; and whose value is not a single xs:string, or an entry whose key is &quot;validate&quot; or &quot;unescape&quot; and whose value is not a single xs:boolean.&apos;

should become:
&apos;It is a dynamic error if the value of $options includes an entry whose key is &quot;liberal&quot;, &quot;validate&quot; or &quot;unescape&quot; and whose value is not a single xs:boolean, or an entry &quot;fallback&quot; whose value is not a function item that conforms to function(xs:string) as xs:string.&apos;

Errors under E. Summary of Error conditions have the same texts, currently.

Notes:
The paragraph &quot;ECMA-404 differs from RFC 4627 in two respects: [...] array.&quot; can be removed.

The paragraph &quot;Many JSON implementations allow commas [...] Representation of JSON.&quot; should be revised or removed.

Examples:
Example &quot;The expression json-to-xml(&apos;&quot;abcd&quot;&apos;, map{&apos;spec&apos;: &apos;RFC4627&apos;}) [...] not a string.).&quot; should be removed or revised.

Example &quot;The expression json-to-xml(&apos;&quot;abcd&quot;&apos;, map{&apos;spec&apos;: &apos;ECMA-404&apos;})[...] abcd&lt;/string&gt;.&quot; should be removed or revised.

Example: the last example, right under &quot;The following example illustrates ...&quot; contains the &quot;spec&quot; option, this should be revised.

Normative references
The text of the link contains &quot;4627&quot;, while the link was updated to refer to 7159: &quot;IETF. The JavaScript Object Notation (JSON) Data Interchange Format. July 2006. See http://www.ietf.org/rfc/rfc4627.txt&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105847</commentid>
    <comment_count>9</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-05-13 13:37:54 +0000</bug_when>
    <thetext>The corrections noted in comment #8 have been applied.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>