Skip to content

V-Mann-Nick/json-parser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JSON Parser in Rust

JSON parser compliant with the JSON specification (RFC 8259).

It features:

  • Support for numbers written in scientific notation (e.g. 2e10)
  • Representation of numbers in the most suitable number type i64, u64 or f64 (no arbitrary precision supported!)
  • Support for escape sequences (\n, \r, \f, …)
  • Support for Unicode escape sequences (\u005C) as well as UTF-16 surrogate pairs (\uD834\uDD1E) for characters not in the basic multilingual plane
  • Serialization back to JSON from Rust representation

How to run

This project uses the nix package manager using nix flakes for providing the rust toolchain and building packages, as well as direnv and nix-direnv for automatic shell loading.

git clone [email protected]:V-Mann-Nick/json-parser.git
cd json-parser

# You need both direnv and nix configured for flakes for this to work
direnv allow  # will load the nix dev shell with rust toolchain

# Build with cargo
cargo build --release
./target/release/qj --help

# Build with nix
nix build

# Install into nix profile
nix profile install .

# Build OCI image
nix build '.#image'

References

About

JSON parser implemented in Rust

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published