pure icon indicating copy to clipboard operation
pure copied to clipboard

Parsing for TypeClassLang

Open hrutvik opened this issue 2 years ago • 1 comments

Redirect parsing to target TypeClassLang

Aside from PureLang's existing constructs, this will need to handle:

  • class and instance declarations
  • contexts/type class constraints in types
  • TypeClassLang's new top-level program structure
  • pattern guards
  • type annotations at the expression-level

hrutvik avatar Sep 26 '23 15:09 hrutvik

Class and Instance declarations are included in the AST, and the types are expanded with constraints. There are incremental updates in the parser.

Design Decision

  • It is decided that the parser should raise errors when a top level type signature is found inside Instance block

Gordon-Sau avatar Oct 30 '23 05:10 Gordon-Sau