Skip to content

Latest commit

 

History

History
60 lines (59 loc) · 1.8 KB

TODO.md

File metadata and controls

60 lines (59 loc) · 1.8 KB

Todo

  • error handling
    • undelcared
      • elem/array
      • func
    • duplicated decl/def
      • elem/array
      • func
    • analyse_assign in analyze logic error
    • analyze (recursively) assign/if/while/read
    • semantic error report in analyze
    • float assigned to int
    • pass float arg to int param
    • type check in get_expr_type
    • find main
      • print main first?
    • gen_br_call params args num unmatch
  • array
    • option type
    • analyze
      • dynamic out_of_bound
      • decls negative interval num / lo_bound>upbound
      • static out_of_bound
    • codegen
      • gen_br_init_array
      • gen_br_assign
      • gen_br_read
      • gen_br_expr_array_addr
      • gen_br_expr_array_val
      • get_reg_usage
  • int_to_float
    • recursive call ref
    • check int_to_float in gen_br_expr_unop seems unuseful
  • complete line type
  • optimization
  • ifdebug dump symbol table
  • lineno seems unuserful?
    • seems used for error reporting, can be useful for semantic error report
  • begin-end -> () style
  • better to gen_main & gen_halt or init?
  • gen_comment
  • div_by_zero
    • gen_br_div_by_zero
    • label
    • get_reg_usage
  • symbol table
    • stack_cnt for a scope or a table?
      • dont understand slots_needed_for_table
    • sbValType
      • great, seems can be used to opt (update type and value)?
        • removed temporally
    • line num
      • dont know how to get it
  • analyze
  • codegen
    • gen_br_decls
      • what about bool
        • because brill is writen in c!
  • may need to alter AST