The Rust parser and macro expander.
This API is completely unstable and subject to change.
ast | The Rust abstract syntax tree module.
|
attr | Functions dealing with attributes and meta items.
|
diagnostics | |
early_buffered_lints | Allows the buffering of lints for later.
|
edition | |
entry | |
expand | Definitions shared by macros / syntax extensions and e.g. librustc.
|
feature_gate | |
mut_visit | A MutVisitor represents an AST modification; it accepts an AST piece and
and mutates it in place. So, for instance, macro expansion is a MutVisitor
that walks over an AST and modifies it.
|
print | |
ptr | The AST pointer.
|
sess | Contains ParseSess which holds state living beyond what one Parser might.
It also serves as an input to the parser itself.
|
show_span | Span debugger
|
source_map | The SourceMap tracks all the source code used within a single crate, mapping
from integer byte positions to the original source code location. Each bit
of source parsed during crate parsing (typically files, in-memory strings,
or various bits of macro expansion) cover a continuous range of bytes in the
SourceMap and are represented by SourceFile s. Byte positions are stored in
Span and used pervasively in the compiler. They are absolute positions
within the SourceMap , which upon request can be converted to line and column
information, source code snippets, etc.
|
symbol | An "interner" is a data structure that associates values with usize tags and
allows bidirectional lookup; i.e., given a value, one can easily find the
type, and vice versa.
|
token | |
tokenstream | Token Streams
|
util | |
visit | AST walker. Each overridden visit method has full control over what
happens with its node, it can do its own traversal of the node's children,
call visit::walk_* to apply the default traversal algorithm, or prevent
deeper traversal by doing nothing.
|
HashStableContext | Requirements for a StableHashingContext to be used in this crate.
This is a hack to allow using the HashStable_Generic derive macro
instead of implementing everything in librustc.
|