Struct kconfig_parser::lex::macro_lexer::MacroLexer
source · Expand description
The macro lexer interprets and evaluates assignment statements and expressions.
Implementations
sourceimpl<LB, U> MacroLexer<LB, U>where
LB: LexerBase,
U: Clone,
impl<LB, U> MacroLexer<LB, U>where
LB: LexerBase,
U: Clone,
sourcepub fn new(base_lexer: LB, user_object: &U) -> Self
pub fn new(base_lexer: LB, user_object: &U) -> Self
Creates a new macro lexer, given an original base lexer. This will interpret all tokens necessary for macro interpretation and expansion, and result into tokens specific for the user of this lexer.
sourcepub fn symbol_table(&self) -> HashSet<Symbol>
pub fn symbol_table(&self) -> HashSet<Symbol>
Retrieves the symbol table to be used apart from the Macro Lexer
Trait Implementations
sourceimpl<LB, U> LexerBase for MacroLexer<LB, U>where
LB: LexerBase,
U: Clone,
impl<LB, U> LexerBase for MacroLexer<LB, U>where
LB: LexerBase,
U: Clone,
sourcefn next_token(&mut self) -> Token
fn next_token(&mut self) -> Token
Goes forward to the next token in the stream, if available.
sourcefn current_stream(&self) -> Option<String>
fn current_stream(&self) -> Option<String>
Returns the current stream’s name, if any (for example, the normal
lexer does know this value) Read more
Auto Trait Implementations
impl<LB, U> RefUnwindSafe for MacroLexer<LB, U>where
LB: RefUnwindSafe,
U: RefUnwindSafe,
impl<LB, U> Send for MacroLexer<LB, U>where
LB: Send,
U: Send,
impl<LB, U> Sync for MacroLexer<LB, U>where
LB: Sync,
U: Sync,
impl<LB, U> Unpin for MacroLexer<LB, U>where
LB: Unpin,
U: Unpin,
impl<LB, U> UnwindSafe for MacroLexer<LB, U>where
LB: UnwindSafe,
U: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more