summaryrefslogtreecommitdiff
path: root/libraries/base/Prelude.hs
diff options
context:
space:
mode:
authorHerbert Valerio Riedel <hvr@gnu.org>2014-08-31 11:40:50 +0200
committerHerbert Valerio Riedel <hvr@gnu.org>2014-08-31 12:25:16 +0200
commit393b820233caa00e428affc28e090b496d181664 (patch)
tree3cd003a4d12d3c0d6145a180b25078807970472f /libraries/base/Prelude.hs
parentb760cc59b26a407dcd5715920c64f53513e65f14 (diff)
downloadhaskell-393b820233caa00e428affc28e090b496d181664.tar.gz
Re-export Word from Prelude (re #9531)
The original proposal text can be found at http://www.haskell.org/pipermail/libraries/2014-August/023491.html The proposal passed with a clear majority, and was additionally confirmed by the core libraries committee. *Compatibility Note* Only code that imports `Data.Word` for the sole purpose of using `Word` *and* requires to be `-Werror`-clean (due to `-fwarn-unused-imports`) is affected by this change. In order to write warning-free forward/backward compatible against `base`, a variant of the following CPP-based snippet can be used: -- Starting with base>4.7.0 or GHC>7.8 Prelude re-exports 'Word' -- The following is needed, if 'Word' is the *only* entity needed from Data.Word #ifdef MIN_VERSION_base # if !MIN_VERSION_base(4,7,1) import Data.Word (Word) # endif -- no cabal_macros.h -- fallback to __GLASGOW_HASKELL__ #elif __GLASGOW_HASKELL__ < 709 import Data.Word (Word) #endif This also updates the haddock submodule in order to avoid a compile warning
Diffstat (limited to 'libraries/base/Prelude.hs')
-rw-r--r--libraries/base/Prelude.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/libraries/base/Prelude.hs b/libraries/base/Prelude.hs
index 9b1119e155..3a3cc4dcc2 100644
--- a/libraries/base/Prelude.hs
+++ b/libraries/base/Prelude.hs
@@ -48,7 +48,7 @@ module Prelude (
-- *** Numeric types
Int, Integer, Float, Double,
- Rational,
+ Rational, Word,
-- *** Numeric type classes
Num((+), (-), (*), negate, abs, signum, fromInteger),