Nota: A tradução desta entrada está atualmente em revisão de qualidade, portanto parte do conteúdo é exibida temporariamente apenas em inglês.
Este verbete ainda não foi traduzido para o seu idioma, portanto o original é exibido abaixo.
lexer
This term is highly specialized technical jargon used almost exclusively within computer science, specifically in the fields of compiler design and formal language theory. It describes the first stage of a compiler's front end, where raw source code is broken down into meaningful units called tokens. It is often used interchangeably with the term scanner, though some academic contexts distinguish between the two based on whether the component merely scans characters or actively produces tokens.
Because it refers to a specific software component, it is used in a neutral, descriptive register. It typically appears in technical documentation, academic textbooks on programming languages, and discussions regarding the architecture of interpreters or compilers.
Meanings
Examples
The lexer breaks the source code into a stream of tokens.
I need to update the lexer to support the new operator.
Wait, is the lexer handling whitespace correctly?
Wait, is the lexer handling whitespace correctly?
The compiler consists of a lexer and a parser.
Maybe the bug is actually in the lexer rather than the parser.
A custom lexer was implemented to handle the unique syntax of the domain specific language.
The lexer identifies keywords and identifiers from the input string.
I wonder if I can optimize the lexer for better performance.