diff options
Diffstat (limited to 'lib/Numeric/GSL/Internal.hs')
-rw-r--r-- | lib/Numeric/GSL/Internal.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Numeric/GSL/Internal.hs b/lib/Numeric/GSL/Internal.hs index 2ccc3ef..db2c633 100644 --- a/lib/Numeric/GSL/Internal.hs +++ b/lib/Numeric/GSL/Internal.hs | |||
@@ -13,8 +13,11 @@ | |||
13 | module Numeric.GSL.Internal where | 13 | module Numeric.GSL.Internal where |
14 | 14 | ||
15 | import Data.Packed.Internal | 15 | import Data.Packed.Internal |
16 | import Foreign | 16 | |
17 | import Foreign.Marshal.Array(copyArray) | ||
18 | import Foreign.Ptr(Ptr, FunPtr) | ||
17 | import Foreign.C.Types(CInt) | 19 | import Foreign.C.Types(CInt) |
20 | import System.IO.Unsafe(unsafePerformIO) | ||
18 | 21 | ||
19 | iv :: (Vector Double -> Double) -> (CInt -> Ptr Double -> Double) | 22 | iv :: (Vector Double -> Double) -> (CInt -> Ptr Double -> Double) |
20 | iv f n p = f (createV (fromIntegral n) copy "iv") where | 23 | iv f n p = f (createV (fromIntegral n) copy "iv") where |