Skip to content

Source Tracking & Diagnostics Utilities for Common (Rust) Infrastructure for Parsing and Expressions

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-Apache
MIT
LICENSE-MIT
Notifications You must be signed in to change notification settings

insaneinside/cripes-source

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Source Tracking & Diagnostics Utilities in Rust

Build Status

This crate provides — or will provide — a set of types, traits, and routines useful for tracking the provenance of AST items and other intermediate values produced by a parser. Its basic operation takes inspiration from the relevant subsystems used in rustc itself, while its API is driven by the author's penchant for elegant trait-directed designs.

cripes-source is part of the "Common (Rust) Infrastructure for Parsing and Expressions" project.

Roadmap/Status

Project is in its early stages; the API has not even been fully designed (and the API that exists is certainly subject to change!). Requires nightly Rust for now.

  • Source tracking and lookup
    • Basic types for representing file locations
    • Source storage + retrieval by offset and span
    • Line and column ↔ offset conversion using per-file indexes (nearly completed)
    • Incremental indexing (insufficiently tested)
    • Support for obtaining span information while parsing (API work needed)
  • Diagnostics: have some ideas sketched out...
    • Types for storing diagnostics to be rendered
    • Traits to be implemented by different renderers
    • The renderers themselves
  • Polish pass
    • Document all the things
    • Integration tests!
    • Add prelude module?
    • Add benchmarks?
    • Increase test coverage (whatever it is, it's not high enough!)

License

cripes-source is dual-licensed under both the Apache License version 2.0 and the MIT License; derivative works may be made under the terms of either license.

About

Source Tracking & Diagnostics Utilities for Common (Rust) Infrastructure for Parsing and Expressions

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-Apache
MIT
LICENSE-MIT

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages