{"action":"created","issue":{"url":"https://api.github.com/repos/zserge/jsmn/issues/17","labels_url":"https://api.github.com/repos/zserge/jsmn/issues/17/labels{/name}","comments_url":"https://api.github.com/repos/zserge/jsmn/issues/17/comments","events_url":"https://api.github.com/repos/zserge/jsmn/issues/17/events","html_url":"https://github.com/zserge/jsmn/issues/17","id":109777306,"number":17,"title":"Whitespace handling in strict mode","user":{"login":"zserge","id":1911760,"avatar_url":"https://avatars.githubusercontent.com/u/1911760?v=3","gravatar_id":"","url":"https://api.github.com/users/zserge","html_url":"https://github.com/zserge","followers_url":"https://api.github.com/users/zserge/followers","following_url":"https://api.github.com/users/zserge/following{/other_user}","gists_url":"https://api.github.com/users/zserge/gists{/gist_id}","starred_url":"https://api.github.com/users/zserge/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zserge/subscriptions","organizations_url":"https://api.github.com/users/zserge/orgs","repos_url":"https://api.github.com/users/zserge/repos","events_url":"https://api.github.com/users/zserge/events{/privacy}","received_events_url":"https://api.github.com/users/zserge/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-10-05T11:27:46Z","updated_at":"2015-10-05T11:27:47Z","closed_at":"2015-10-05T11:27:46Z","body":"In strict mode JSMN fails to parse the value of \"Year\" in the following example:\n\n{\n  \"Day\": 26,\n  \"Month\": 9,\n  \"Year\": 12\n}\n\nThis data comes straight from JSON.stringify(data, null, 2) (Firefox 15) and according to json.org (\"Whitespace can be inserted between any pair of tokens.\") this should be valid JSON.\n\nThank you for your great work!\n\n----------------------------------------\n- Bitbucket: https://bitbucket.org/zserge/jsmn/issue/7\n- Originally reported by: Anonymous\n- Originally created at: 2012-09-26T10:31:44.626\n"},"comment":{"url":"https://api.github.com/repos/zserge/jsmn/issues/comments/145500569","html_url":"https://github.com/zserge/jsmn/issues/17#issuecomment-145500569","issue_url":"https://api.github.com/repos/zserge/jsmn/issues/17","id":145500569,"user":{"login":"zserge","id":1911760,"avatar_url":"https://avatars.githubusercontent.com/u/1911760?v=3","gravatar_id":"","url":"https://api.github.com/users/zserge","html_url":"https://github.com/zserge","followers_url":"https://api.github.com/users/zserge/followers","following_url":"https://api.github.com/users/zserge/following{/other_user}","gists_url":"https://api.github.com/users/zserge/gists{/gist_id}","starred_url":"https://api.github.com/users/zserge/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zserge/subscriptions","organizations_url":"https://api.github.com/users/zserge/orgs","repos_url":"https://api.github.com/users/zserge/repos","events_url":"https://api.github.com/users/zserge/events{/privacy}","received_events_url":"https://api.github.com/users/zserge/received_events","type":"User","site_admin":false},"created_at":"2015-10-05T11:27:47Z","updated_at":"2015-10-05T11:27:47Z","body":"Thanks for reporting the issue. Check the recent version, should be fixed.\nStrict mode is not so strict, it just adds SOME extra checks that are valid for json.\nI don't think adding space characters to the primitive token is a good idea, because the last token in your example should be \"12\", not \"12\\n  \".\nSo, commas between fields and colons between key and value in object should be checked in the main loop, but I haven't done this yet.\nYour json is now parsed correctly, I've added it to the tests. And, don't forget jsmn is a primitive minimalist parser, if you need a tool to validate your JSON - consider using grownup alternatives\n\n----------------------------------------\nOriginal comment by: Serge Zaitsev\n"}}