avoid the pprust infrastructure in macro expansion This changes macro expansion to format the path of a macro directly instead of usng the pprust infrastructure. The pprust infrastructure tries to perform line-breaking in a slow fashion, which is undesired when formatting the path of a macro. This should to speed up expansion by a fair amount (I saw 20% on a profiler on `rustc_mir`, and 50% of the time marked as "expansion" in the profiler/time-passes is actually spent loading dependencies). r? @jseyfried |
||
|---|---|---|
| .. | ||
| diagnostics | ||
| ext | ||
| parse | ||
| util | ||
| abi.rs | ||
| ast.rs | ||
| attr.rs | ||
| build.rs | ||
| Cargo.toml | ||
| codemap.rs | ||
| config.rs | ||
| diagnostic_list.rs | ||
| entry.rs | ||
| feature_gate.rs | ||
| fold.rs | ||
| json.rs | ||
| lib.rs | ||
| ptr.rs | ||
| README.md | ||
| show_span.rs | ||
| std_inject.rs | ||
| str.rs | ||
| test.rs | ||
| test_snippet.rs | ||
| tokenstream.rs | ||
| visit.rs | ||
NB: This crate is part of the Rust compiler. For an overview of the
compiler as a whole, see
the README.md file found in librustc.
The syntax crate contains those things concerned purely with syntax
– that is, the AST ("abstract syntax tree"), parser, pretty-printer,
lexer, macro expander, and utilities for traversing ASTs.