COMPILER DESIGN

SYNTAX ANALYSIS

ROLE OF THE PARSER

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
Compiler can diagnose
A
Logical errors only
B
Grammatical and logical errors
C
Grammatical errors only
D
All of the mentioned
Explanation: 

Detailed explanation-1: -In conclusion, a compiler can diagnose grammatical errors only. Logical errors are not detected by the compiler. Logical errors can be detected by testing the program or using debugging tools.

Detailed explanation-2: -A runtime error cannot be detected by a compiler.

There is 1 question to complete.