-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Milestone
Description
Compilation of TypeClassLang uses dictionary construction (actually, tuple construction) on fully-annotated TypeClassLang programs to produce PureLang programs. This must be proved sound with respect to TypeClassLang semantics, which is defined via naive translation to PureLang. However, compilation should be much more intelligent. For example:
- declaring instances once and for all, rather than repeatedly constructing dictionaries (i.e. common subexpression elimination)
- inlining methods where possible to avoid constructing a full dictionary/tuple
- selectively monomorphising functions, bypassing dictionaries altogether
- partially applying dictionaries for derived instances
- and so on
Metadata
Metadata
Assignees
Labels
No labels