The template-default package

[Tags: bsd3, library]

Declaring instances of the Default type class has always been pretty mechanical. This package makes the compiler do the mechanical bit. This has the benefit that even less thought is required, and the instance will automatically be corrected when the definition of the data type changes (say, to add more arguments to the constructor). Usage looks like this:

 (-# LANGUAGE TemplateHaskell #-)
 import Data.Default.TH
 deriveDefault ''MyFancyTypeName

Properties

Versions0.1, 0.1.1
Dependenciesbase (>=3 && <6), data-default, template-haskell (>=2.4 && <2.8)
LicenseBSD3
CopyrightDaniel Wagner 2012
AuthorDaniel Wagner
MaintainerDaniel Wagner <daniel@wagner-home.com>
CategoryData
Home pagehttps://github.com/haskell-pkg-janitors/template-default
Upload dateSat Apr 28 04:14:48 UTC 2012
Uploaded byDanielWagner
DistributionsNixOS:0.1.1
Downloads183 total (19 in last 30 days)

Modules

[Index]

Downloads

Maintainers' corner

For package maintainers and hackage trustees