~/talk

Type Inference in GHC

Talkat LambdaConf 2017 · 2017-05-25..05-27· [haskell, compilers-and-language-design]
slides:none on file

GHC performs type inference in two phases: gathering then solving — it traverses code to emit a set of typed equations and class constraints, then runs a solver. The solver is unification-based for plain types and uses instance lookup to turn class constraints into givens. Pattern matching and GADTs introduce implication/existential constraints that must be solved locally, which makes some valid programs hard for the solver to find even though the approach generally works and is what GHC emits as equations.

AI-written summary · about

  1. 0:00Start
  2. 15:09Instantiation
  3. 21:38Failure Cases
  4. 22:09Infinite Type
  5. 22:52Types in Haskell
  6. 38:25Type Checking a Pattern Matching
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.