{unquoted_keys, true | false} now allows control of whether unquoted object keys are rejected or not by the parser/eep0018 decoder
This commit is contained in:
parent
b73e506fe2
commit
098fcbab1e
3 changed files with 61 additions and 0 deletions
1
test/cases/object_with_unquoted_keys.json
Normal file
1
test/cases/object_with_unquoted_keys.json
Normal file
|
@ -0,0 +1 @@
|
|||
{foo : "bar", baz:true, false : null,object:{ key : "value" },list:[null,null,null,[],"\n\r\\"]}
|
23
test/cases/object_with_unquoted_keys.test
Normal file
23
test/cases/object_with_unquoted_keys.test
Normal file
|
@ -0,0 +1,23 @@
|
|||
{name, "object with unquoted keys"}.
|
||||
{jsx, [start_object,
|
||||
{key,"foo"},
|
||||
{string,"bar"},
|
||||
{key,"baz"},
|
||||
{literal,true},
|
||||
{key,"false"},
|
||||
{literal,null},
|
||||
{key,"object"},
|
||||
start_object,
|
||||
{key,"key"},
|
||||
{string,"value"},
|
||||
end_object,
|
||||
{key,"list"},
|
||||
start_array,
|
||||
{literal,null},
|
||||
{literal,null},
|
||||
{literal,null},
|
||||
start_array,end_array,
|
||||
{string,"\n\r\\"},
|
||||
end_array,end_object,end_json]}.
|
||||
{json, "object_with_unquoted_keys.json"}.
|
||||
{jsx_flags, [{unquoted_keys, true}]}.
|
Loading…
Add table
Add a link
Reference in a new issue