Comments (2)
Hi @sharwell ,
Thanks for the heads-up. My original goal with this project was to make a parser that would only accept the grammar defined by json.org. I think that it is unwise to allow parsing of non-standard JSON by default. But I'm not opposed to it as long as it's integrated in a way that allows the user to disable the functionality.
Here are 3 solutions that come to mind at the moment:
- Add a setting to
TextScanner
class to tolerate relaxed syntax. - Add a new scanner class that parses the relaxed syntax.
- Add a new transducer class that streams in relaxed syntax and streams out filtered, standard JSON.
I'm not sure which one would be the best solution. I would have to do some internal testing. Let me know what you think.
from lightjson.
@MarcosLopezC Considering how easy it was to embed this, one option would be simply making a note in the readme that points users to this issue if they are looking for such a solution. Based on the way you worded the readme (i.e. "Strict adherence to JSON Standard" as a feature), it seemed like our work was more suited to inclusion as a link than inclusion as updated code.
from lightjson.
Related Issues (20)
- Add explicit conversion operators to JsonValue
- Add method `AddIfNotNull`. HOT 1
- Write wiki page
- OverflowException in JsonValue.IsInteger is unnecessary HOT 10
- JsonValue.GetHashCode throws NullReferenceException for numeric and boolean types HOT 1
- JsonValue.Parse cannot parse certain numbers HOT 1
- JsonValue.Equals does not handle non-null types correctly HOT 1
- Failure to parse JSON object where value matches an earlier key HOT 1
- JsonObject.Rename fails when old and new name are the same HOT 1
- Incorrect exception thrown for 'null' passed to JsonArray constructor HOT 1
- Error position reported by TextScanner.Assert is off by one HOT 2
- Pretty-printed arrays not indented correctly HOT 1
- JsonWriter.IsValidNumber is not used HOT 3
- JsonValue.AsNumber and JsonValue.AsString is affected by current culture
- Support read Hex HOT 3
- Incorrect `JsonParseException` for some control characters HOT 4
- Complex JSON format
- Request to decrease target framework HOT 4
- Suggestion: Release source code nuget package HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lightjson.