futhark
Safe HaskellNone
LanguageGHC2021

Language.Futhark.TypeChecker.Error

Contents

Description

Fundamental facilities for constructing type error messages.

Synopsis

Breadcrumbs

data BreadCrumbs Source #

Unification failures can occur deep down inside complicated types (consider nested records). We leave breadcrumbs behind us so we can report the path we took to find the mismatch. When combining breadcrumbs with the Semigroup instance, put the innermost breadcrumbs to the left.

hasNoBreadCrumbs :: BreadCrumbs -> Bool Source #

Is the path empty?

matchingField :: Name -> BreadCrumbs Source #

Matching a record field.

matchingConstructor :: Name -> BreadCrumbs Source #

Matching a constructor.

matching :: Doc () -> BreadCrumbs Source #

Matching anything.