The reflection package

[Tags: bsd3, library]

This package addresses the configuration problem which is propogating configurations that are available at run-time, allowing multible configurations to coexist without resorting to mutable global variables or System.IO.Unsafe.unsafePerformIO.

That package is an implementation of the ideas presented in the paper "Functional Pearl: Implicit Configurations" by Oleg Kiselyov and Chung-chieh Shan (original paper). However, the API has been streamlined to improve performance.

Austin Seipp's tutorial Reflecting values to types and back provides a summary of the approach taken by this library, along with more motivating examples.

[Skip to ReadMe]


Versions0.0.0, 0.1.0, 0.1.1, 0.2.0, 0.3.0, 0.3.1, 0.3.2, 0.3.3, 0.3.5, 0.4.0,,, 0.4.1,, 0.5,, 0.6, 0.7, 0.8, 0.9, 1.0, 1.1, 1.1.1, 1.1.2, 1.1.3, 1.1.4, 1.1.5,, 1.1.6, 1.1.7,, 1.3, 1.3.1, 1.3.2, 1.4, 1.5.1,,, 1.5.2,, 2, 2.1
Change logCHANGELOG.markdown
Dependenciesbase (>=2 && <5), tagged (>=0.4.4 && <1), template-haskell [details]
Copyright2009-2013 Edward A. Kmett, 2012 Elliott Hird, 2004 Oleg Kiselyov and Chung-chieh Shan
AuthorEdward A. Kmett, Elliott Hird, Oleg Kiselyov and Chung-chieh Shan
MaintainerEdward A. Kmett <>
CategoryData, Reflection, Dependent Types
Home page
Bug tracker
Source repositoryhead: git clone git://
UploadedSun Sep 13 23:22:49 UTC 2015 by EdwardKmett
DistributionsDebian:2, Fedora:1.5.1, FreeBSD:2, LTSHaskell:2, NixOS:2.1, Stackage:2.1
Downloads94178 total (230 in last 30 days)
1 []
StatusDocs available [build log]
Last success reported on 2015-09-13 [all 1 reports]




slowIf you enable this flag, we use a more portable much much slower implementation. Moreover, the 'Given' API is broken, so this is currently an unsupported configuration. If you feel the need to turn on this flag for any reason, please email the maintainer!DisabledAutomatic
template-haskellYou can disable the use of the `template-haskell` package using `-f-template-haskell`. Disabling this is an unsupported configuration, but it may be useful for accelerating builds in sandboxes for expert users.EnabledManual

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info


Maintainers' corner

For package maintainers and hackage trustees

Readme for reflection-2.1


Hackage Build Status

This package provides an implementation of the ideas presented in Functional Pearl: Implicit Configurations by Oleg Kiselyov and Chung-Chieh Shan. However, the API has been implemented in a much more efficient manner.

Contact Information

Contributions and bug reports are welcome!

Please feel free to contact me through github or on the #haskell IRC channel on

-Edward Kmett