Skip to content
This repository has been archived by the owner on Apr 8, 2024. It is now read-only.

Add resources page with links. #24

Merged
merged 1 commit into from
Jan 24, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ the Rust language. The primary audiences for the grammar are:
The grammar tools produced here are not intended to be used directly within
rustc, or any other existing tools.

## Links
- [Meeting notes](misc/meeting-notes.md)
- [Resources](misc/resources.md)

## License

Licensed under either of
Expand Down
35 changes: 35 additions & 0 deletions misc/resources.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Resources

This is a collection of various resources that may be helpful to anyone
looking at or working on the grammar.

## Previous/Existing Grammars and Parsers
- The truth: https://github.com/rust-lang/rust/tree/master/src/libsyntax
- The reference: https://github.com/rust-lang-nursery/reference/
- The old grammar: https://doc.rust-lang.org/nightly/grammar.html ([src](https://github.com/rust-lang/rust/blob/master/src/doc/grammar.md))
- The old ANTLR grammar ([removed](https://github.com/rust-lang/rust/pull/41705)): https://github.com/rust-lang/rust/tree/12e76e24cc1466ffb2bd37cc7652a6dd7ba15735/src/grammar
- Old flex/bison grammar ([outdated](https://github.com/rust-lang/rust/issues/32723)): https://github.com/rust-lang/rust/tree/master/src/grammar
- Intellij's parser: https://github.com/intellij-rust/intellij-rust/blob/master/src/main/grammars/RustParser.bnf
- jorendorff's ANTLR grammar: https://github.com/jorendorff/rust-grammar/
- Niko's rustypop: https://github.com/nikomatsakis/rustypop
- Haskell parser: https://github.com/harpocrates/language-rust/blob/master/src/Language/Rust/Parser/Internal.y

## Grammar RFC
The call to canonicalize the grammar.

- RFC: https://github.com/rust-lang/rfcs/blob/master/text/1331-grammar-is-canonical.md
- RFC tracker: https://github.com/rust-lang/rust/issues/30942
- Original RFC discussion with interesting stuff: https://github.com/rust-lang/rfcs/pull/1331

## New Rust Parsing Projects
- Parser used here: https://github.com/rust-lang-nursery/gll
(Forked from https://github.com/lykenware/gll/)
- Lossless syntax tree: https://github.com/matklad/rowan/
- New front-end rust parser: https://github.com/matklad/rust-analyzer/

## Testing
Some other test suites for Rust parsing.

- https://github.com/brson/ctrs
- The old grammar bot: https://github.com/rust-lang/rust/issues/28592
- Intellij's test suite: https://github.com/intellij-rust/intellij-rust/tree/master/src/test/resources/org/rust/lang/core/parser/fixtures