foundation: Alternative prelude with batteries and no dependencies

[ bsd3, foundation, library ] [ Propose Tags ]

A custom prelude with no dependencies apart from base.

This package has the following goals:

[Skip to Readme]
Versions [faq] 0.0.1, 0.0.2, 0.0.3, 0.0.4, 0.0.5, 0.0.6, 0.0.7, 0.0.8, 0.0.9, 0.0.10, 0.0.11, 0.0.12, 0.0.13, 0.0.14, 0.0.15, 0.0.16, 0.0.17, 0.0.18, 0.0.19, 0.0.20, 0.0.21, 0.0.22, 0.0.23, 0.0.24, 0.0.25
Dependencies base (>=4.5 && <4.10), ghc-prim (>=0.2), Win32 [details]
License BSD-3-Clause
Copyright Vincent Hanquez <>
Author Vincent Hanquez <>
Revised Revision 2 made by HerbertValerioRiedel at 2017-05-20T11:53:00Z
Category foundation
Home page
Bug tracker
Source repo head: git clone
Uploaded by VincentHanquez at 2016-08-13T09:38:59Z
Distributions Arch:0.0.25, Debian:0.0.21, Fedora:0.0.25, LTSHaskell:0.0.23, NixOS:0.0.25, Stackage:0.0.23, openSUSE:0.0.25
Downloads 84108 total (718 in the last 30 days)
Rating 2.25 (votes: 4) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Hackage Matrix CI
Docs available [build log]
Last success reported on 2016-08-13 [all 1 reports]




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

For package maintainers and hackage trustees

Readme for foundation-0.0.1

[back to package description]


Build Status BSD Haskell

Documentation: foundation on hackage


  • provide a base like set of modules that provide a consistent set of features and bugfixes across multiple versions of GHC (unlike base).
  • provide a better and more efficient prelude than base's prelude.
  • be self-sufficient: no external dependencies apart from base (or ghc packages).
  • provide better data-types: packed unicode string by default, arrays.
  • Better numerical classes that better represent mathematical things (No more all-in-one Num).

How to use

Disable the built-in prelude at the top of your file:

{-# LANGUAGE NoImplicitPrelude #-}

Or directly in your project cabal file:

Default-Extensions: NoImplicitPrelude

Then in your modules:

import Foundation

How to contribute

Any contributions is welcome, but a short list includes:

  • Improve the code base
  • Report an issue
  • Fix an issue
  • Improve the documentation
  • Make tutorial on how to use foundation
  • Make your project use foundation instead of base, report the missing coverage (IO, types, etc.), or what functionality is missing to make a succesful transition


Foundation started on the simple idea of trying to put everything I need in one simple and consistent package. The amazing haskell ecosystem is extremely fragmented and maintained by different people with different goals, free time, and style. The overall scare of not trying to change anything relatively central (base, bytestring, text, vector ..) for a promise of stability has pushed many people to work on their own thing, leading to unnecessary work duplication and further fragmentation.

Foundation uses and abuses type families.