Fix GMP v4 compatibility.
[packages/integer-gmp.git] / GHC / Integer / GMP / Internals.hs
1 {-# LANGUAGE NoImplicitPrelude #-}
2
3 -- | This modules provides access to the 'Integer' constructors and
4 -- exposes some highly optimized GMP-operations.
5 --
6 -- Note that since @integer-gmp@ does not depend on `base`, error
7 -- reporting via exceptions, 'error', or 'undefined' is not
8 -- available. Instead, the low-level functions will crash the runtime
9 -- if called with invalid arguments.
10 --
11 -- See also
12 -- <https://ghc.haskell.org/trac/ghc/wiki/Commentary/Libraries/Integer GHC Commentary: Libraries/Integer>.
13
14 module GHC.Integer.GMP.Internals
15 ( -- * The 'Integer' type
16 Integer(..)
17
18 -- * Number theoretic functions
19 , gcdInt
20 , gcdInteger
21 , gcdExtInteger
22 , lcmInteger
23 , nextPrimeInteger
24 , testPrimeInteger
25
26 -- * Exponentiation functions
27 , powInteger
28 , powModInteger
29 , powModSecInteger
30 , recipModInteger
31
32 -- * Import/export functions
33 , sizeInBaseInteger
34 , importIntegerFromByteArray
35 , importIntegerFromAddr
36 , exportIntegerToMutableByteArray
37 , exportIntegerToAddr
38 ) where
39
40 import GHC.Integer.Type