3 ms·
That's just an alternative implementation of rust's grammar for verification purposes. Rust's parser is entirely hand coded inside rustc (in Rust).
by kzrdude 11y ago
That's just an alternative implementation of rust's grammar for verification purposes. Rust's parser is entirely hand coded inside rustc (in Rust).
- e12e 11y agoAh, I thought that was something new. I remember reading something about a manual parser a while back. Thank you for clarifying. Would there be a benefit to moving from hand coded to something like parent project for rustc? IIRC the rationale for hand-coding the parser was mostly speed (and a wish to avoid external (to rust) dependencies)?
- kzrdude 11y agoSeeing this bug filed today (rather interesting/weird breaking change needed to fix it), it seems plain sanity should prefer a generated parser. https://github.com/rust-lang/rust/issues/28777 https://github.com/rust-lang/rust/issues/28777 I'm not a compiler hacker, so I don't know how to weigh it really though.