project-langx / X

A placeholder language with shareable bytecode IR.
2 stars 0 forks source link

Add value class, fix mypy issues, black reformatting #39

Closed frankhart2018 closed 2 years ago

frankhart2018 commented 2 years ago

Closes #37

Implementation

  1. Add Value class to represent values.
  2. Add subtype classes using a common TypedValue abstract class, the implementation classes of this are responsible for the actual binary operation.
  3. The main Value calls to magic methods for computing various binary operation results are just dynamic dispatching to relevant TypedValue.
frankhart2018 commented 2 years ago

TODO: