Results 1 -
2 of
2
Refined typechecking with Stardust
- In Workshop on Programming Languages Meets Program Verification (PLPV
, 2007
"... We present Stardust, an implementation of a type system for a subset of ML with type refinements, intersection types, and union types, enabling programmers to legibly specify certain classes of program invariants that are verified at compile time. This is the first implementation of unrestricted int ..."
Abstract
-
Cited by 5 (4 self)
- Add to MetaCart
We present Stardust, an implementation of a type system for a subset of ML with type refinements, intersection types, and union types, enabling programmers to legibly specify certain classes of program invariants that are verified at compile time. This is the first implementation of unrestricted intersection and union types in a mainstream functional programming setting, as well as the first implementation of a system with both datasort and index refinements. The system—with the assistance of external constraint solvers—supports integer, Boolean and dimensional index refinements; we apply both value refinements (to check red-black tree invariants) and invaluable refinements (to check dimensional consistency). While typechecking with intersection and union types is intrinsically complex, our experience so far suggests that it can be practical in many instances.
Bidirectional polymorphism through greed and unions
, 2008
"... Bidirectional typechecking has become a popular technique for advanced type systems. In this paper, I show how to extend past work on bidirectional typechecking to handle parametric polymorphism bidirectionally. The first key contribution is a simple bidirectional type system that supports first-cla ..."
Abstract
- Add to MetaCart
Bidirectional typechecking has become a popular technique for advanced type systems. In this paper, I show how to extend past work on bidirectional typechecking to handle parametric polymorphism bidirectionally. The first key contribution is a simple bidirectional type system that supports first-class (higher-rank and impredicative) polymorphism; its algorithm is complete for predicative polymorphism (including ML-style polymorphism and higher-rank polymorphism). The second key contribution extends that system with subtyping; the combination of bidirectional typechecking with intersection and union types fortuitously yields a simple but fairly powerful algorithm. Both of these systems, inspired by Cardelli’s early work on System F<:, rely on a “greedy ” method for finding polymorphic instances. Finally, I present a more powerful algorithm that forms intersections and unions automatically. 1

