Types that Change: The Extensible Type Design Pattern
summary
Defines an extensible type design pattern: an ADT parameterized by a type-function applied to every field so instantiations can be identity, Either String for parse errors, type+location annotations, Maybe for diffs, etc. Uses type-compose and cites Barbies; applies the pattern to Copilot and rewrites Ogma at NASA, cutting three separate AST representations down to one and removing large duplication; reports real-world validation with good results but notes harder pattern-matching and reliance on IDE/type-tooling.
AI-written summary · about
chapters (10)
- 0:00Extensible type design pattern
- 5:36Core concept
- 9:08Practical applications in compilers
- 14:26Embedding variables and expressions
- 17:22NASA with Copilot use case
- 22:24Beyond compilers
- 26:16Limitations and alternatives
- 30:12Tooling and IDE support
- 33:23Related work
- 36:10Closing remarks & Q&A
related talks
01h 26mImplementing Dependent Pattern Matching and Type Unification Part 2
35mRestaging Domain-Specific Languages: A Flexible Design Pattern for Rapid Development of(…)
25mAdapTT: Functoriality for Dependent Type Casts
39mPattern Matching: Small Enhancement or Major Feature?
56mOn Type-Based Techniques for Program Manipulation
38mExistential Types — Make OOP Great Again!
16mA Type-and-Effect System for Object Initialization
58mPanel discussion: Types for All: From weak to strong, from static to dynamic
