Principal type inference for GADTs

2Citations
Citations of this article
10Readers
Mendeley users who have this article in their library.

Abstract

We present a new method for GADT type inference that improves the precision of previous approaches. In particular, our approach accepts more type-correct programs than previous approaches when they do not employ type annotations. A side benefit of our approach is that it can detect a wide range of runtime errors that are missed by previous approaches. Our method is based on the idea to represent type refinements in pattern-matching branches by choice types, which facilitate a separation of the typing and reconciliation phases and thus support case expressions. This idea is formalized in a type system, which is both sound and a conservative extension of the classical Hindley- Milner system. We present the results of an empirical evaluation that compares our algorithm with previous approaches.

References Powered by Scopus

Principal type-schemes for functional programs

699Citations
N/AReaders
Get full text

Simple unification-based type inference for GADTS

179Citations
N/AReaders
Get full text

Type inference with constrained types

156Citations
N/AReaders
Get full text

Cited by Powered by Scopus

Type inference for GADTs, outsidein and anti-unification

1Citations
N/AReaders
Get full text

Optional type classes for Haskell

0Citations
N/AReaders
Get full text

Register to see more suggestions

Mendeley helps you to discover research relevant for your work.

Already have an account?

Cite

CITATION STYLE

APA

Chen, S., & Erwig, M. (2016). Principal type inference for GADTs. ACM SIGPLAN Notices, 51(1), 416–428. https://doi.org/10.1145/2837614.2837665

Readers over time

‘16‘17‘18‘19‘2002468

Readers' Seniority

Tooltip

Professor / Associate Prof. 2

50%

PhD / Post grad / Masters / Doc 2

50%

Readers' Discipline

Tooltip

Computer Science 9

90%

Business, Management and Accounting 1

10%

Save time finding and organizing research with Mendeley

Sign up for free
0