Tcl Library Source Code

View Ticket
Login
Ticket UUID: c601e3dc6c1a43c7ce2fbacf5f92a323991a6f69
Title: String is double does not conform to JSON specification
Type: Patch Version: 0.1.5
Submitter: anonymous Created on: 2014-09-04 21:04:08
Subsystem: huddle Assigned To: nobody
Priority: 5 Medium Severity: Important
Status: Open Last Modified: 2014-09-04 21:04:08
Resolution: None Closed By: nobody
    Closed on:
Description:
 ::huddle::jsondump command has bad json export values like 00456.
JSON specification says this is STRING but for huddle this is NUMBER.

package require huddle
set bb [huddle create a b c 00.34]
huddle jsondump $bb

returns bad json:

{
  "a": "b",
  "c": 00.34
}

Patch solves the problem:

{
  "a": "b",
  "c": "00.34"
}

Attachments: