From 863fd69b44d6e65544973871043d89d1d6c50a9e Mon Sep 17 00:00:00 2001 From: Alberto Ruiz Date: Thu, 22 Dec 2011 18:16:58 +0100 Subject: ok hmatrix-special --- packages/special/hmatrix-special.cabal | 8 ++++---- packages/special/lib/Numeric/GSL/Special/Airy.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Bessel.hs | 9 +++++++-- packages/special/lib/Numeric/GSL/Special/Clausen.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Coulomb.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Coupling.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Dawson.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Debye.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Dilog.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Elementary.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Ellint.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Elljac.hs | 7 +++++-- packages/special/lib/Numeric/GSL/Special/Erf.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Exp.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Expint.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Fermi_dirac.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Gamma.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Gegenbauer.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Hyperg.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Internal.hsc | 5 ++++- packages/special/lib/Numeric/GSL/Special/Laguerre.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Lambert.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Legendre.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Log.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Pow_int.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Psi.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Synchrotron.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Transport.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Trig.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/Zeta.hs | 4 ++-- packages/special/lib/Numeric/GSL/Special/auto.hs | 8 +++++--- packages/special/lib/Numeric/GSL/Special/autoall.sh | 1 + packages/special/lib/Numeric/GSL/Special/replace.hs | 2 +- 33 files changed, 79 insertions(+), 65 deletions(-) (limited to 'packages/special') diff --git a/packages/special/hmatrix-special.cabal b/packages/special/hmatrix-special.cabal index c6c8379..4dd884b 100644 --- a/packages/special/hmatrix-special.cabal +++ b/packages/special/hmatrix-special.cabal @@ -1,5 +1,5 @@ Name: hmatrix-special -Version: 0.1.1 +Version: 0.2.0 License: GPL License-file: LICENSE Author: Alberto Ruiz @@ -11,7 +11,7 @@ Description: Interface to GSL special functions. Category: Math -tested-with: GHC ==6.12.3 +tested-with: GHC ==7.4 cabal-version: >=1.6 build-type: Simple @@ -74,6 +74,6 @@ library cpp-options: -DSAFE_CHEAP=unsafe source-repository head - type: darcs - location: http://code.haskell.org/hmatrix + type: git + location: https://github.com/AlbertoRuiz/hmatrix diff --git a/packages/special/lib/Numeric/GSL/Special/Airy.hs b/packages/special/lib/Numeric/GSL/Special/Airy.hs index 8a04eed..2438b71 100644 --- a/packages/special/lib/Numeric/GSL/Special/Airy.hs +++ b/packages/special/lib/Numeric/GSL/Special/Airy.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Airy --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -41,7 +41,7 @@ module Numeric.GSL.Special.Airy( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal airy_Ai_e :: Double -> Precision -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Bessel.hs b/packages/special/lib/Numeric/GSL/Special/Bessel.hs index 66d6c5b..e88c3b0 100644 --- a/packages/special/lib/Numeric/GSL/Special/Bessel.hs +++ b/packages/special/lib/Numeric/GSL/Special/Bessel.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Bessel --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -91,6 +91,7 @@ module Numeric.GSL.Special.Bessel( , bessel_Inu , bessel_Knu_scaled_e , bessel_Knu_scaled +, bessel_Knu_scaled_e10_e , bessel_Knu_e , bessel_Knu , bessel_lnKnu_e @@ -104,7 +105,7 @@ module Numeric.GSL.Special.Bessel( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..),CSize(..)) import Numeric.GSL.Special.Internal bessel_J0_e :: Double -> (Double,Double) @@ -467,6 +468,10 @@ bessel_Knu_scaled :: Double -> Double -> Double bessel_Knu_scaled = gsl_sf_bessel_Knu_scaled foreign import ccall SAFE_CHEAP "gsl_sf_bessel_Knu_scaled" gsl_sf_bessel_Knu_scaled :: Double -> Double -> Double +bessel_Knu_scaled_e10_e :: Double -> Double -> (Double,Int,Double) +bessel_Knu_scaled_e10_e nu x = createSFR_E10 "bessel_Knu_scaled_e10_e" $ gsl_sf_bessel_Knu_scaled_e10_e nu x +foreign import ccall SAFE_CHEAP "gsl_sf_bessel_Knu_scaled_e10_e" gsl_sf_bessel_Knu_scaled_e10_e :: Double -> Double -> Ptr () -> IO CInt + bessel_Knu_e :: Double -> Double -> (Double,Double) bessel_Knu_e nu x = createSFR "bessel_Knu_e" $ gsl_sf_bessel_Knu_e nu x foreign import ccall SAFE_CHEAP "gsl_sf_bessel_Knu_e" gsl_sf_bessel_Knu_e :: Double -> Double -> Ptr () -> IO CInt diff --git a/packages/special/lib/Numeric/GSL/Special/Clausen.hs b/packages/special/lib/Numeric/GSL/Special/Clausen.hs index 70f05a7..59547ec 100644 --- a/packages/special/lib/Numeric/GSL/Special/Clausen.hs +++ b/packages/special/lib/Numeric/GSL/Special/Clausen.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Clausen --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -18,7 +18,7 @@ module Numeric.GSL.Special.Clausen( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal clausen_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Coulomb.hs b/packages/special/lib/Numeric/GSL/Special/Coulomb.hs index 7253972..c282d7b 100644 --- a/packages/special/lib/Numeric/GSL/Special/Coulomb.hs +++ b/packages/special/lib/Numeric/GSL/Special/Coulomb.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Coulomb --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -21,7 +21,7 @@ module Numeric.GSL.Special.Coulomb( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal hydrogenicR_1_e :: Double -> Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Coupling.hs b/packages/special/lib/Numeric/GSL/Special/Coupling.hs index 16ff9b9..390c6bb 100644 --- a/packages/special/lib/Numeric/GSL/Special/Coupling.hs +++ b/packages/special/lib/Numeric/GSL/Special/Coupling.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Coupling --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -24,7 +24,7 @@ module Numeric.GSL.Special.Coupling( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal coupling_3j_e :: CInt -> CInt -> CInt -> CInt -> CInt -> CInt -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Dawson.hs b/packages/special/lib/Numeric/GSL/Special/Dawson.hs index 7e8d9ce..2486a57 100644 --- a/packages/special/lib/Numeric/GSL/Special/Dawson.hs +++ b/packages/special/lib/Numeric/GSL/Special/Dawson.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Dawson --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -18,7 +18,7 @@ module Numeric.GSL.Special.Dawson( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal dawson_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Debye.hs b/packages/special/lib/Numeric/GSL/Special/Debye.hs index 01976ee..5a54e37 100644 --- a/packages/special/lib/Numeric/GSL/Special/Debye.hs +++ b/packages/special/lib/Numeric/GSL/Special/Debye.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Debye --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -28,7 +28,7 @@ module Numeric.GSL.Special.Debye( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal debye_1_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Dilog.hs b/packages/special/lib/Numeric/GSL/Special/Dilog.hs index 6aa58c4..a7e8e86 100644 --- a/packages/special/lib/Numeric/GSL/Special/Dilog.hs +++ b/packages/special/lib/Numeric/GSL/Special/Dilog.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Dilog --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -21,7 +21,7 @@ module Numeric.GSL.Special.Dilog( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal dilog_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Elementary.hs b/packages/special/lib/Numeric/GSL/Special/Elementary.hs index 7e7f8b6..710e0ce 100644 --- a/packages/special/lib/Numeric/GSL/Special/Elementary.hs +++ b/packages/special/lib/Numeric/GSL/Special/Elementary.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Elementary --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -19,7 +19,7 @@ module Numeric.GSL.Special.Elementary( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal multiply_e :: Double -> Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Ellint.hs b/packages/special/lib/Numeric/GSL/Special/Ellint.hs index 6735057..0d171bf 100644 --- a/packages/special/lib/Numeric/GSL/Special/Ellint.hs +++ b/packages/special/lib/Numeric/GSL/Special/Ellint.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Ellint --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -40,7 +40,7 @@ module Numeric.GSL.Special.Ellint( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal ellint_Kcomp_e :: Double -> Precision -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Elljac.hs b/packages/special/lib/Numeric/GSL/Special/Elljac.hs index 5b32cfe..18c7f06 100644 --- a/packages/special/lib/Numeric/GSL/Special/Elljac.hs +++ b/packages/special/lib/Numeric/GSL/Special/Elljac.hs @@ -16,8 +16,11 @@ module Numeric.GSL.Special.Elljac( elljac_e ) where -import Foreign -import Foreign.C.Types(CInt) +import System.IO.Unsafe +import Foreign.Ptr +import Foreign.Storable +import Foreign.Marshal +import Foreign.C.Types(CInt(..)) elljac_e :: Double -> Double -> (Double,Double,Double) elljac_e u m = unsafePerformIO $ do diff --git a/packages/special/lib/Numeric/GSL/Special/Erf.hs b/packages/special/lib/Numeric/GSL/Special/Erf.hs index 258afd3..69a5c9e 100644 --- a/packages/special/lib/Numeric/GSL/Special/Erf.hs +++ b/packages/special/lib/Numeric/GSL/Special/Erf.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Erf --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -28,7 +28,7 @@ module Numeric.GSL.Special.Erf( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal erfc_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Exp.hs b/packages/special/lib/Numeric/GSL/Special/Exp.hs index 4f15964..0cc2b1c 100644 --- a/packages/special/lib/Numeric/GSL/Special/Exp.hs +++ b/packages/special/lib/Numeric/GSL/Special/Exp.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Exp --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -35,7 +35,7 @@ module Numeric.GSL.Special.Exp( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal exp_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Expint.hs b/packages/special/lib/Numeric/GSL/Special/Expint.hs index f1102c4..be01007 100644 --- a/packages/special/lib/Numeric/GSL/Special/Expint.hs +++ b/packages/special/lib/Numeric/GSL/Special/Expint.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Expint --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -44,7 +44,7 @@ module Numeric.GSL.Special.Expint( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal expint_E1_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Fermi_dirac.hs b/packages/special/lib/Numeric/GSL/Special/Fermi_dirac.hs index 362c7ba..a28b6e3 100644 --- a/packages/special/lib/Numeric/GSL/Special/Fermi_dirac.hs +++ b/packages/special/lib/Numeric/GSL/Special/Fermi_dirac.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Fermi_dirac --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -34,7 +34,7 @@ module Numeric.GSL.Special.Fermi_dirac( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal fermi_dirac_m1_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Gamma.hs b/packages/special/lib/Numeric/GSL/Special/Gamma.hs index 1a4ed4e..f5a573b 100644 --- a/packages/special/lib/Numeric/GSL/Special/Gamma.hs +++ b/packages/special/lib/Numeric/GSL/Special/Gamma.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Gamma --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -57,7 +57,7 @@ module Numeric.GSL.Special.Gamma( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal lngamma_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Gegenbauer.hs b/packages/special/lib/Numeric/GSL/Special/Gegenbauer.hs index 31568f3..78fbaf4 100644 --- a/packages/special/lib/Numeric/GSL/Special/Gegenbauer.hs +++ b/packages/special/lib/Numeric/GSL/Special/Gegenbauer.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Gegenbauer --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -24,7 +24,7 @@ module Numeric.GSL.Special.Gegenbauer( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal gegenpoly_1_e :: Double -> Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Hyperg.hs b/packages/special/lib/Numeric/GSL/Special/Hyperg.hs index b5425f1..958503f 100644 --- a/packages/special/lib/Numeric/GSL/Special/Hyperg.hs +++ b/packages/special/lib/Numeric/GSL/Special/Hyperg.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Hyperg --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -38,7 +38,7 @@ module Numeric.GSL.Special.Hyperg( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal hyperg_0F1_e :: Double -> Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Internal.hsc b/packages/special/lib/Numeric/GSL/Special/Internal.hsc index ae735df..338ed40 100644 --- a/packages/special/lib/Numeric/GSL/Special/Internal.hsc +++ b/packages/special/lib/Numeric/GSL/Special/Internal.hsc @@ -29,7 +29,10 @@ module Numeric.GSL.Special.Internal ( ) where -import Foreign +import Foreign.Storable +import Foreign.Ptr +import Foreign.Marshal +import System.IO.Unsafe(unsafePerformIO) import Data.Packed.Development(check,(//)) import Foreign.C.Types(CSize,CInt) diff --git a/packages/special/lib/Numeric/GSL/Special/Laguerre.hs b/packages/special/lib/Numeric/GSL/Special/Laguerre.hs index 8db6a6c..33d7769 100644 --- a/packages/special/lib/Numeric/GSL/Special/Laguerre.hs +++ b/packages/special/lib/Numeric/GSL/Special/Laguerre.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Laguerre --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -24,7 +24,7 @@ module Numeric.GSL.Special.Laguerre( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal laguerre_1_e :: Double -> Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Lambert.hs b/packages/special/lib/Numeric/GSL/Special/Lambert.hs index b229bf6..4c410d7 100644 --- a/packages/special/lib/Numeric/GSL/Special/Lambert.hs +++ b/packages/special/lib/Numeric/GSL/Special/Lambert.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Lambert --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -20,7 +20,7 @@ module Numeric.GSL.Special.Lambert( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal lambert_W0_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Legendre.hs b/packages/special/lib/Numeric/GSL/Special/Legendre.hs index e329457..0042656 100644 --- a/packages/special/lib/Numeric/GSL/Special/Legendre.hs +++ b/packages/special/lib/Numeric/GSL/Special/Legendre.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Legendre --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -53,7 +53,7 @@ module Numeric.GSL.Special.Legendre( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal legendre_Pl_e :: CInt -> Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Log.hs b/packages/special/lib/Numeric/GSL/Special/Log.hs index 7f3f9d6..46b6a0a 100644 --- a/packages/special/lib/Numeric/GSL/Special/Log.hs +++ b/packages/special/lib/Numeric/GSL/Special/Log.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Log --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -25,7 +25,7 @@ module Numeric.GSL.Special.Log( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal log_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Pow_int.hs b/packages/special/lib/Numeric/GSL/Special/Pow_int.hs index fd232ab..bccdde7 100644 --- a/packages/special/lib/Numeric/GSL/Special/Pow_int.hs +++ b/packages/special/lib/Numeric/GSL/Special/Pow_int.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Pow_int --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -18,7 +18,7 @@ module Numeric.GSL.Special.Pow_int( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal pow_int_e :: Double -> CInt -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Psi.hs b/packages/special/lib/Numeric/GSL/Special/Psi.hs index cb4c756..b99817f 100644 --- a/packages/special/lib/Numeric/GSL/Special/Psi.hs +++ b/packages/special/lib/Numeric/GSL/Special/Psi.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Psi --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -29,7 +29,7 @@ module Numeric.GSL.Special.Psi( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal psi_int_e :: CInt -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Synchrotron.hs b/packages/special/lib/Numeric/GSL/Special/Synchrotron.hs index 59d6c76..6b5cbf6 100644 --- a/packages/special/lib/Numeric/GSL/Special/Synchrotron.hs +++ b/packages/special/lib/Numeric/GSL/Special/Synchrotron.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Synchrotron --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -20,7 +20,7 @@ module Numeric.GSL.Special.Synchrotron( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal synchrotron_1_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Transport.hs b/packages/special/lib/Numeric/GSL/Special/Transport.hs index e95a67a..4f3b469 100644 --- a/packages/special/lib/Numeric/GSL/Special/Transport.hs +++ b/packages/special/lib/Numeric/GSL/Special/Transport.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Transport --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -24,7 +24,7 @@ module Numeric.GSL.Special.Transport( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal transport_2_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Trig.hs b/packages/special/lib/Numeric/GSL/Special/Trig.hs index 91c264a..2f1bda9 100644 --- a/packages/special/lib/Numeric/GSL/Special/Trig.hs +++ b/packages/special/lib/Numeric/GSL/Special/Trig.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Trig --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -39,7 +39,7 @@ module Numeric.GSL.Special.Trig( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal sin_e :: Double -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/Zeta.hs b/packages/special/lib/Numeric/GSL/Special/Zeta.hs index 930efc0..b29b026 100644 --- a/packages/special/lib/Numeric/GSL/Special/Zeta.hs +++ b/packages/special/lib/Numeric/GSL/Special/Zeta.hs @@ -1,7 +1,7 @@ ------------------------------------------------------------ -- | -- Module : Numeric.GSL.Special.Zeta --- Copyright : (c) Alberto Ruiz 2006 +-- Copyright : (c) Alberto Ruiz 2006-11 -- License : GPL -- Maintainer : Alberto Ruiz (aruiz at um dot es) -- Stability : provisional @@ -30,7 +30,7 @@ module Numeric.GSL.Special.Zeta( ) where import Foreign(Ptr) -import Foreign.C.Types(CInt) +import Foreign.C.Types(CInt(..)) import Numeric.GSL.Special.Internal zeta_int_e :: CInt -> (Double,Double) diff --git a/packages/special/lib/Numeric/GSL/Special/auto.hs b/packages/special/lib/Numeric/GSL/Special/auto.hs index b6276b2..d3461b2 100755 --- a/packages/special/lib/Numeric/GSL/Special/auto.hs +++ b/packages/special/lib/Numeric/GSL/Special/auto.hs @@ -2,8 +2,10 @@ -- automatic generation of wrappers for simple GSL special functions +{-# LANGUAGE NoMonomorphismRestriction #-} + import Text.ParserCombinators.Parsec -import System +import System.Environment(getArgs) import Data.List(intersperse, isPrefixOf) import Data.Char(toUpper,isUpper,toLower) @@ -64,7 +66,7 @@ main = do let exports = rep (")",") where") $ rep ("(\n","(\n ") $ rep (",\n",", ") $ unlines $ ["("]++intersperse "," (map (\(Header _ n _) -> hName n) (filter safe parsed))++[")"] let defs = unlines $ map (showFull (name ++".h")) parsed let imports = "\nimport Foreign(Ptr)\n" - ++"import Foreign.C.Types(CInt)\n" + ++"import Foreign.C.Types(CInt(..))\n" ++"import Numeric.GSL.Special.Internal\n" let mod = modhead name ++ "module Numeric.GSL.Special."++ upperFirst name++exports++imports++defs writeFile (upperFirst name ++ ".hs") mod @@ -80,7 +82,7 @@ google name = "