• Input: Parse tree
• Output: Abstract syntax tree
• Method:
• Semantic analyzer checks semantic aspects:
•  type checking, which may imply
   conversions (for example int-to-real)
• checking declaration of variables
• Syntax-Directed Translation:
   Parser controls:
• Semantic actions
• Generation of syntax tree
Semantic analyzer
10/17