Computer PPSC
Parsing is also known as:
Explanation
Parsing takes the stream of tokens produced by the lexical analyzer and checks them against the grammar of the programming language, building a parse tree or syntax tree. Because it analyzes the syntactic structure of the source program, parsing is called syntax analysis. It is distinct from lexical analysis (tokenizing), semantic analysis (meaning checks), and code generation.
Related facts:
Compiler phases in order: lexical analysis, syntax analysis, semantic analysis, intermediate code generation, code optimization, code generation.
The parser reports syntax errors such as missing semicolons or mismatched brackets.
Top-down and bottom-up are the two main parsing techniques.
Exam tip: "Parsing = syntax analysis" is a commonly tested basic fact in PPSC/FPSC computer science papers.