Open ltrzesniewski opened 9 months ago
While doing https://github.com/icsharpcode/ILSpy/pull/3138 I noticed the JSON highlighting was wrong (see the last 2 lines in the screenshot), so this PR fixes that.
EDIT: I noticed there's an issue for this, so this fixes #410.
Here's the difference for the following example:
{ "String": "Value", "Bool": true, "Null": null, "Number:": -42e10, "Object": { "Foo:": "Bar", "Multiline Key" : "Value" }, "Array": ["Foo", "Bar", "Baz"] }
Before:
After:
The rule for numbers adds support for - and reformats the regex.
-
I also kept the existing single-quoted strings and hex numbers which are not part of the JSON spec.
While doing https://github.com/icsharpcode/ILSpy/pull/3138 I noticed the JSON highlighting was wrong (see the last 2 lines in the screenshot), so this PR fixes that.
EDIT: I noticed there's an issue for this, so this fixes #410.
Here's the difference for the following example:
Before:
After:
The rule for numbers adds support for
-
and reformats the regex.I also kept the existing single-quoted strings and hex numbers which are not part of the JSON spec.