Function rustc_expand::mbe::macro_parser::inner_parse_loop [−][src]
fn inner_parse_loop<'root, 'tt>(
sess: &ParseSess,
cur_items: &mut SmallVec<[MatcherPosHandle<'root, 'tt>; 1]>,
next_items: &mut Vec<MatcherPosHandle<'root, 'tt>>,
eof_items: &mut SmallVec<[MatcherPosHandle<'root, 'tt>; 1]>,
bb_items: &mut SmallVec<[MatcherPosHandle<'root, 'tt>; 1]>,
token: &Token
) -> ParseResult<()>
Expand description
Process the matcher positions of cur_items
until it is empty. In the process, this will
produce more items in next_items
, eof_items
, and bb_items
.
For more info about the how this happens, see the module-level doc comments and the inline comments of this function.
Parameters
cur_items
: the set of current items to be processed. This should be empty by the end of a successful execution of this function.next_items
: the set of newly generated items. These are used to replenishcur_items
in the functionparse
.eof_items
: the set of items that would be valid if this was the EOF.bb_items
: the set of items that are waiting for the black-box parser.token
: the current token of the parser.
Returns
A ParseResult
. Note that matches are kept track of through the items generated.