Anonymous records via named tuples

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow to host generated Haddocks.

BSD-3-Clause licensed by Chris Done
Maintained by


Declare and access tuple fields with labels

This package is experimental, exploring the design space opened up by the implemented and to-be-implemented work on extensible records in GHC.

Note: You need GHC 8.0.1.

Basic examples

The haddock docs are here.

Enable these extensions:

  • In GHCi: :set -XOverloadedLabels -XTypeOperators -XDataKinds -XFlexibleContexts

  • In a module: {-# LANGUAGE OverloadedLabels, TypeOperators, DataKinds, FlexibleContexts #-}

Let’s use GHCi:

> import Labels
> :set -XOverloadedLabels -XTypeOperators -XDataKinds -XFlexibleContexts