/// Lex an identifier or keyword.
///
/// Note that fully-qualified names are created at parse time (identifier + period + identifier).
Lex an identifier or keyword.
Note that fully-qualified names are created at parse time (identifier + period + identifier).
Lex an identifier or keyword . Note that fully - qualified names are created at parse time ( identifier + period + identifier ) .
pub fn lex_keyword_identifier(reader: &mut impl Reader, lexer: &mut impl Lexer) {
    while let ReaderResult::Match(source) = reader.strip_match(&*IDENTIFIER_RE) {
        let word = source.as_str();
        lexer.add(match keyword_or_reserved(word, source.clone()) {
            Ok(kw) => kw,
            Err(_err) => identifier(word, source.clone()).unwrap(),
        });
    }
}
pub fn lex_keyword_identifier ( reader : & mut impl Reader , lexer : & mut impl Lexer ) { while let ReaderResult :: Match ( source ) = reader . strip_match ( & * IDENTIFIER_RE ) { let word = source . as_str ( ) ; lexer . add ( match keyword_or_reserved ( word , source . clone ( ) ) { Ok ( kw ) => kw , Err ( _err ) => identifier ( word , source . clone ( ) ) . unwrap ( ) , } ) ; } }
Lex an identifier or keyword.
Lex an identifier or keyword .
reader
&mut impl Reader
lexer
&mut impl Lexer