Crate proc_macro1.15.0[−][src]
A support library for macro authors when defining new macros.
This library, provided by the standard distribution, provides the types
consumed in the interfaces of procedurally defined macro definitions such as
function-like macros #[proc_macro]
, macro attribures #[proc_macro_attribute]
and
custom derive attributes#[proc_macro_derive]
.
Note that this crate is intentionally bare-bones currently. This functionality is intended to be expanded over time as more surface area for macro authors is stabilized.
See the book for more.
Modules
token_stream |
Public implementation details for the |
Macros
quote |
[ Experimental ]
|
Structs
Group |
A delimited token stream. |
Ident |
An identifier ( |
LexError |
Error returned from |
Literal |
A literal string ( |
Punct |
An |
Span |
A region of source code, along with macro expansion information. |
TokenStream |
The main type provided by this crate, representing an abstract stream of tokens, or, more specifically, a sequence of token trees. The type provide interfaces for iterating over those token trees and, conversely, collecting a number of token trees into one stream. |
Diagnostic |
[ Experimental ] A structure representing a diagnostic message and associated children messages. |
LineColumn |
[ Experimental ] A line-column pair representing the start or end of a |
SourceFile |
[ Experimental ] The source file of a given |
Enums
Delimiter |
Describes how a sequence of token trees is delimited. |
Spacing |
Whether an |
TokenTree |
A single token or a delimited sequence of token trees (e.g. |
Level |
[ Experimental ] An enum representing a diagnostic level. |
Functions
quote |
[ Experimental ] Quote a |
quote_span |
[ Experimental ] Quote a |