rust/mk
bors 4e4e8cff16 Auto merge of #21452 - bleibig:bison-grammar, r=nikomatsakis
This adds a new lexer/parser combo for the entire Rust language can be generated with with flex and bison, taken from my project at https://github.com/bleibig/rust-grammar. There is also a testing script that runs the generated parser with all *.rs files in the repository (except for tests in compile-fail or ones that marked as "ignore-test" or "ignore-lexer-test"). If you have flex and bison installed, you can run these tests using the new "check-grammar" make target.

This does not depend on or interact with the existing testing code in the grammar, which only provides and tests a lexer specification.

OS X users should take note that the version of bison that comes with the Xcode toolchain (2.3) is too old to work with this grammar, they need to download and install version 3.0 or later.

The parser builds up an S-expression-based AST, which can be displayed by giving the "-v" argument to parser-lalr (normally it only gives output on error). It is only a rough approximation of what is parsed and doesn't capture every detail and nuance of the program.

Hopefully this should be sufficient for issue #2234, or at least a good starting point.
2015-01-24 22:14:14 +00:00
..
cfg rollup merge of #21414: ejjeong/aarch64-linux-android 2015-01-21 09:15:59 -08:00
clean.mk debuginfo: Add a rust-gdb shell script that will start GDB with Rust pretty printers enabled. 2014-12-30 17:26:13 +01:00
crates.mk regex: Remove in-tree version 2015-01-23 21:04:10 -08:00
ctags.mk
debuggers.mk debuginfo: Add a rust-gdb shell script that will start GDB with Rust pretty printers enabled. 2014-12-30 17:26:13 +01:00
dist.mk mk: Add rustbook to source dist 2015-01-08 17:03:40 -08:00
docs.mk Ensure that the book is built after the doc/ directory. 2015-01-09 20:26:31 +11:00
grammar.mk Add a LALR grammar for Rust with testing support 2015-01-20 18:47:17 -08:00
host.mk
install.mk Fix make install dependencies 2015-01-03 09:49:51 +01:00
llvm.mk
main.mk mk: Don't set RUSTC_BOOTSTRAP_KEY on -dev and -nightly. Not needed 2015-01-17 16:37:34 -08:00
perf.mk
platform.mk powerpc: Use toolchain assembler on power 2015-01-11 21:14:30 -08:00
prepare.mk iOS: fixed install phase 2015-01-12 10:09:47 +02:00
reconfig.mk
rt.mk Initial support for aarch64-linux-android 2015-01-20 17:43:15 +09:00
rustllvm.mk
snap.mk
stage0.mk
target.mk
tests.mk rollup merge of #21289: brson/errorcodes 2015-01-21 09:13:46 -08:00
util.mk