named: Named parameters (keyword arguments) for Haskell

[ bsd3, control, library ] [ Propose Tags ]

named is a lightweight library for named function parameters (keyword arguments) based on overloaded labels. Keyword arguments have several advantages over positional arguments:

  • they can be supplied in arbitrary order

  • their names serve as documentation at call site

  • it is impossible to accidentally mix them up

Unlike newtype wrappers, keyword arguments don't pollute the global namespace, don't require top-level definitions, and don't need to be exported.

This implementation of named parameters is typesafe, provides good type inference, descriptive type errors, and has no runtime overhead.

Example usage:

import Named

createSymLink :: "from" :! FilePath -> "to" :! FilePath -> IO ()
createSymLink (Arg from) (Arg to) = ...

main = createSymLink ! #from "/path/to/source"
                     ! #to "/target/path"


Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees


Versions [RSS],,,
Change log
Dependencies base (>=4.9 && <4.20) [details]
License BSD-3-Clause
Author Vladislav Zavialov
Maintainer Monadfix <>
Revised Revision 5 made by Bodigrim at 2023-09-30T20:35:23Z
Category Control
Home page
Bug tracker
Source repo head: git clone
Uploaded by Artyom at 2019-10-19T06:36:11Z
Distributions LTSHaskell:, NixOS:, Stackage:
Reverse Dependencies 14 direct, 4 indirect [details]
Downloads 3645 total (32 in the last 30 days)
Rating 2.5 (votes: 6) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2019-10-19 [all 1 reports]