Lexical Analysis

Answer & solution
Official answer: C
Lexical analysis groups source characters into tokens and recognizes reserved keywords, often by distinguishing them from identifier tokens using a keyword table. This precedes parsing, so C.
A scanner first isolates a lexeme such as 'while'. It then returns the reserved token WHILE rather than an ordinary identifier token. A parser consumes that token to determine grammatical structure. Code generation emits target instructions after the program has been analyzed, while dataflow analysis studies facts such as reaching definitions. These later tasks cannot be the first point at which the keyword token is recognized.