Wobbly types: type inference for generalized algebraic data types (2004)

by Simon Peyton Jones, Geoffrey Washburn, Stephanie Weirich