Stages

  • Lexical Analysis
  • Parsing
  • Semantic Analysis
  • Optimization
  • Code Generation

Challenges

  • Error handling (“When I encounter code which is incomplete or erroneous, I would like to present the user with a helpful message for each error in the program instead of immediately dying with an unhelpful message at the first error.”)
  • Syntax challenges (“When you encounter a -, is it unary negation or a minus sign?”)
  • Semantics challenges (“Can I correctly resolve function overloads per the PL specification for each invocation?”)
  • Typing challenges (“Does the compiler determine type correctness via type inference, type checking, or ‘both’?”)