{-# LINE 1 "./QuantLib/Instrument/Forward.chs" #-}
module QuantLib.Instrument.Forward
(
GenForward
, Forward
, ForwardRateAgreement
, BondForward
, FxForward
, asForward
, forwardRateAgreement
, bondForward
, fxForward
, fxForwardFromRate
, cleanForwardPrice
, forwardPrice
, forwardValue
, impliedYield
, settlementDate
, spotIncome
, spotValue
, amount
, forwardRate
, fxForwardRate
, fairForwardRate
, npvSourceCurrency
, npvTargetCurrency
) where
import qualified Foreign.C.Types as C2HSImp
import qualified Foreign.ForeignPtr as C2HSImp
import qualified Foreign.Marshal.Utils as C2HSImp
import qualified Foreign.Ptr as C2HSImp
import QuantLib.Internal
import QuantLib.Internal.Common
import QuantLib.Internal.Type
import QuantLib.InterestRate
{-# LINE 35 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 43 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 44 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 45 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 46 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 47 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 48 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 49 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 50 "./QuantLib/Instrument/Forward.chs" #-}
{-# LINE 51 "./QuantLib/Instrument/Forward.chs" #-}
forwardRateAgreement :: (GenIborIndex ibor) -> (Day)
-> (Day)
-> (PositionType) -> (Double)
-> (Double)
-> (Maybe (GenYieldTermStructure y))
-> IO ((ForwardRateAgreement))
forwardRateAgreement :: forall ibor y.
GenIborIndex ibor
-> Day
-> Day
-> PositionType
-> Double
-> Double
-> Maybe (GenYieldTermStructure y)
-> IO ForwardRateAgreement
forwardRateAgreement GenIborIndex ibor
a1 Day
a2 Day
a3 PositionType
a4 Double
a5 Double
a6 Maybe (GenYieldTermStructure y)
a7 =
GenIborIndex ibor
-> (Ptr CIborIndex' -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall ibor b.
GenIborIndex ibor -> (Ptr CIborIndex' -> IO b) -> IO b
withIborIndex GenIborIndex ibor
a1 ((Ptr CIborIndex' -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement)
-> (Ptr CIborIndex' -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall a b. (a -> b) -> a -> b
$ \Ptr CIborIndex'
a1' ->
Day -> (CInt -> IO ForwardRateAgreement) -> IO ForwardRateAgreement
forall a. Day -> (CInt -> IO a) -> IO a
withDay Day
a2 ((CInt -> IO ForwardRateAgreement) -> IO ForwardRateAgreement)
-> (CInt -> IO ForwardRateAgreement) -> IO ForwardRateAgreement
forall a b. (a -> b) -> a -> b
$ \CInt
a2' ->
Day -> (CInt -> IO ForwardRateAgreement) -> IO ForwardRateAgreement
forall a. Day -> (CInt -> IO a) -> IO a
withDay Day
a3 ((CInt -> IO ForwardRateAgreement) -> IO ForwardRateAgreement)
-> (CInt -> IO ForwardRateAgreement) -> IO ForwardRateAgreement
forall a b. (a -> b) -> a -> b
$ \CInt
a3' ->
let {a4' :: CInt
a4' = PositionType -> CInt
forall a b. (Enum a, Integral b) => a -> b
fromEnumC PositionType
a4} in
let {a5' :: CDouble
a5' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
a5} in
let {a6' :: CDouble
a6' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
a6} in
Maybe (GenYieldTermStructure y)
-> (Ptr CYieldTermStructure' -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall y b.
Maybe (GenYieldTermStructure y)
-> (Ptr CYieldTermStructure' -> IO b) -> IO b
withMaybeYieldTermStructure Maybe (GenYieldTermStructure y)
a7 ((Ptr CYieldTermStructure' -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement)
-> (Ptr CYieldTermStructure' -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall a b. (a -> b) -> a -> b
$ \Ptr CYieldTermStructure'
a7' ->
(Ptr (Ptr ()) -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall a b. (Ptr (Ptr a) -> IO b) -> IO b
preErrorCheck ((Ptr (Ptr ()) -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement)
-> (Ptr (Ptr ()) -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall a b. (a -> b) -> a -> b
$ \Ptr (Ptr ())
a8' ->
Ptr CIborIndex'
-> CInt
-> CInt
-> CInt
-> CDouble
-> CDouble
-> Ptr CYieldTermStructure'
-> Ptr (Ptr ())
-> IO (Ptr CForwardRateAgreement')
forwardRateAgreement'_ Ptr CIborIndex'
a1' CInt
a2' CInt
a3' CInt
a4' CDouble
a5' CDouble
a6' Ptr CYieldTermStructure'
a7' Ptr (Ptr ())
a8' IO (Ptr CForwardRateAgreement')
-> (Ptr CForwardRateAgreement' -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall a b. IO a -> (a -> IO b) -> IO b
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= \Ptr CForwardRateAgreement'
res ->
Ptr CForwardRateAgreement' -> IO ForwardRateAgreement
peekForwardRateAgreement Ptr CForwardRateAgreement'
res IO ForwardRateAgreement
-> (ForwardRateAgreement -> IO ForwardRateAgreement)
-> IO ForwardRateAgreement
forall a b. IO a -> (a -> IO b) -> IO b
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= \ForwardRateAgreement
res' ->
Ptr (Ptr ()) -> IO ()
forall a. Ptr (Ptr a) -> IO ()
errorCheck Ptr (Ptr ())
a8'IO () -> IO ForwardRateAgreement -> IO ForwardRateAgreement
forall a b. IO a -> IO b -> IO b
forall (m :: * -> *) a b. Monad m => m a -> m b -> m b
>>
ForwardRateAgreement -> IO ForwardRateAgreement
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return (ForwardRateAgreement
res')
{-# LINE 60 "./QuantLib/Instrument/Forward.chs" #-}
bondForward :: (Day)
-> (Day)
-> (PositionType) -> (Double)
-> (Word)
-> (DayCounter) -> (Calendar) -> (BusinessDayConvention) -> (GenBond b) -> (Maybe (GenYieldTermStructure y1))
-> (Maybe (GenYieldTermStructure y2))
-> IO ((BondForward))
bondForward a1 a2 a3 a4 a5 a6 a7 a8 a9 a10 a11 =
withDay a1 $ \a1' ->
withDay a2 $ \a2' ->
let {a3' = fromEnumC a3} in
let {a4' = realToFrac a4} in
let {a5' = fromIntegral a5} in
withDayCounter a6 $ \a6' ->
withCalendar a7 $ \a7' ->
let {a8' = fromEnumC a8} in
withBond a9 $ \a9' ->
withMaybeYieldTermStructure a10 $ \a10' ->
withMaybeYieldTermStructure a11 $ \a11' ->
preErrorCheck $ \a12' ->
bondForward'_ a1' a2' a3' a4' a5' a6' a7' a8' a9' a10' a11' a12' >>= \res ->
peekBondForward res >>= \res' ->
errorCheck a12'>>
return (res')
{-# LINE 69 "./QuantLib/Instrument/Forward.chs" #-}
cleanForwardPrice :: (BondForward) -> IO ((Double))
cleanForwardPrice a1 =
withBondForward a1 $ \a1' ->
preErrorCheck $ \a2' ->
cleanForwardPrice'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 72 "./QuantLib/Instrument/Forward.chs" #-}
forwardPrice :: (BondForward) -> IO ((Double))
forwardPrice a1 =
withBondForward a1 $ \a1' ->
preErrorCheck $ \a2' ->
forwardPrice'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 75 "./QuantLib/Instrument/Forward.chs" #-}
forwardValue :: (GenForward f) -> IO ((Double))
forwardValue a1 =
withForward a1 $ \a1' ->
preErrorCheck $ \a2' ->
forwardValue'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 79 "./QuantLib/Instrument/Forward.chs" #-}
impliedYield :: (GenForward f) -> (Double)
-> (Double)
-> (Day)
-> (Compounding) -> (DayCounter) -> IO ((InterestRate))
impliedYield a1 a2 a3 a4 a5 a6 =
withForward a1 $ \a1' ->
let {a2' = realToFrac a2} in
let {a3' = realToFrac a3} in
withDay a4 $ \a4' ->
let {a5' = (fromIntegral . fromEnum) a5} in
withDayCounter a6 $ \a6' ->
preErrorCheck $ \a7' ->
impliedYield'_ a1' a2' a3' a4' a5' a6' a7' >>= \res ->
peekInterestRate res >>= \res' ->
errorCheck a7'>>
return (res')
{-# LINE 85 "./QuantLib/Instrument/Forward.chs" #-}
settlementDate :: (GenForward f) -> IO ((Day))
settlementDate a1 =
withForward a1 $ \a1' ->
preErrorCheck $ \a2' ->
settlementDate'_ a1' a2' >>= \res ->
let {res' = toDay res} in
errorCheck a2'>>
return (res')
{-# LINE 88 "./QuantLib/Instrument/Forward.chs" #-}
spotIncome :: (GenForward f) -> (GenYieldTermStructure y) -> IO ((Double))
spotIncome a1 a2 =
withForward a1 $ \a1' ->
withYieldTermStructure a2 $ \a2' ->
preErrorCheck $ \a3' ->
spotIncome'_ a1' a2' a3' >>= \res ->
let {res' = realToFrac res} in
errorCheck a3'>>
return (res')
{-# LINE 91 "./QuantLib/Instrument/Forward.chs" #-}
spotValue :: (GenForward f) -> IO ((Double))
spotValue a1 =
withForward a1 $ \a1' ->
preErrorCheck $ \a2' ->
spotValue'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 94 "./QuantLib/Instrument/Forward.chs" #-}
forwardRate :: (ForwardRateAgreement) -> IO ((InterestRate))
forwardRate a1 =
withGenInstrument a1 $ \a1' ->
preErrorCheck $ \a2' ->
forwardRate'_ a1' a2' >>= \res ->
peekInterestRate res >>= \res' ->
errorCheck a2'>>
return (res')
{-# LINE 97 "./QuantLib/Instrument/Forward.chs" #-}
amount :: (ForwardRateAgreement) -> IO ((Double))
amount a1 =
withGenInstrument a1 $ \a1' ->
preErrorCheck $ \a2' ->
amount'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 101 "./QuantLib/Instrument/Forward.chs" #-}
fxForward :: (Double)
-> (Currency)
-> (Double)
-> (Currency)
-> (Day)
-> (Bool)
-> (Word)
-> (Calendar)
-> IO ((FxForward))
fxForward :: Double
-> Currency
-> Double
-> Currency
-> Day
-> Bool
-> Word
-> Calendar
-> IO FxForward
fxForward Double
a1 Currency
a2 Double
a3 Currency
a4 Day
a5 Bool
a6 Word
a7 Calendar
a8 =
let {a1' :: CDouble
a1' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
a1} in
Currency -> (Ptr CCurrency -> IO FxForward) -> IO FxForward
forall b. Currency -> (Ptr CCurrency -> IO b) -> IO b
withCurrency Currency
a2 ((Ptr CCurrency -> IO FxForward) -> IO FxForward)
-> (Ptr CCurrency -> IO FxForward) -> IO FxForward
forall a b. (a -> b) -> a -> b
$ \Ptr CCurrency
a2' ->
let {a3' :: CDouble
a3' = Double -> CDouble
forall a b. (Real a, Fractional b) => a -> b
realToFrac Double
a3} in
Currency -> (Ptr CCurrency -> IO FxForward) -> IO FxForward
forall b. Currency -> (Ptr CCurrency -> IO b) -> IO b
withCurrency Currency
a4 ((Ptr CCurrency -> IO FxForward) -> IO FxForward)
-> (Ptr CCurrency -> IO FxForward) -> IO FxForward
forall a b. (a -> b) -> a -> b
$ \Ptr CCurrency
a4' ->
Day -> (CInt -> IO FxForward) -> IO FxForward
forall a. Day -> (CInt -> IO a) -> IO a
withDay Day
a5 ((CInt -> IO FxForward) -> IO FxForward)
-> (CInt -> IO FxForward) -> IO FxForward
forall a b. (a -> b) -> a -> b
$ \CInt
a5' ->
let {a6' :: CInt
a6' = Bool -> CInt
forall a. Num a => Bool -> a
C2HSImp.fromBool Bool
a6} in
let {a7' :: CUInt
a7' = Word -> CUInt
forall a b. (Integral a, Num b) => a -> b
fromIntegral Word
a7} in
Calendar -> (Ptr CCalendar -> IO FxForward) -> IO FxForward
forall b. Calendar -> (Ptr CCalendar -> IO b) -> IO b
withCalendar Calendar
a8 ((Ptr CCalendar -> IO FxForward) -> IO FxForward)
-> (Ptr CCalendar -> IO FxForward) -> IO FxForward
forall a b. (a -> b) -> a -> b
$ \Ptr CCalendar
a8' ->
(Ptr (Ptr ()) -> IO FxForward) -> IO FxForward
forall a b. (Ptr (Ptr a) -> IO b) -> IO b
preErrorCheck ((Ptr (Ptr ()) -> IO FxForward) -> IO FxForward)
-> (Ptr (Ptr ()) -> IO FxForward) -> IO FxForward
forall a b. (a -> b) -> a -> b
$ \Ptr (Ptr ())
a9' ->
CDouble
-> Ptr CCurrency
-> CDouble
-> Ptr CCurrency
-> CInt
-> CInt
-> CUInt
-> Ptr CCalendar
-> Ptr (Ptr ())
-> IO (Ptr CFxForward')
fxForward'_ CDouble
a1' Ptr CCurrency
a2' CDouble
a3' Ptr CCurrency
a4' CInt
a5' CInt
a6' CUInt
a7' Ptr CCalendar
a8' Ptr (Ptr ())
a9' IO (Ptr CFxForward')
-> (Ptr CFxForward' -> IO FxForward) -> IO FxForward
forall a b. IO a -> (a -> IO b) -> IO b
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= \Ptr CFxForward'
res ->
Ptr CFxForward' -> IO FxForward
peekFxForward Ptr CFxForward'
res IO FxForward -> (FxForward -> IO FxForward) -> IO FxForward
forall a b. IO a -> (a -> IO b) -> IO b
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
>>= \FxForward
res' ->
Ptr (Ptr ()) -> IO ()
forall a. Ptr (Ptr a) -> IO ()
errorCheck Ptr (Ptr ())
a9'IO () -> IO FxForward -> IO FxForward
forall a b. IO a -> IO b -> IO b
forall (m :: * -> *) a b. Monad m => m a -> m b -> m b
>>
FxForward -> IO FxForward
forall a. a -> IO a
forall (m :: * -> *) a. Monad m => a -> m a
return (FxForward
res')
{-# LINE 112 "./QuantLib/Instrument/Forward.chs" #-}
fxForwardFromRate :: (Double)
-> (Currency)
-> (Currency)
-> (Double)
-> (Day)
-> (Bool)
-> (Word)
-> (Calendar)
-> IO ((FxForward))
fxForwardFromRate a1 a2 a3 a4 a5 a6 a7 a8 =
let {a1' = realToFrac a1} in
withCurrency a2 $ \a2' ->
withCurrency a3 $ \a3' ->
let {a4' = realToFrac a4} in
withDay a5 $ \a5' ->
let {a6' = C2HSImp.fromBool a6} in
let {a7' = fromIntegral a7} in
withCalendar a8 $ \a8' ->
preErrorCheck $ \a9' ->
fxForwardFromRate'_ a1' a2' a3' a4' a5' a6' a7' a8' a9' >>= \res ->
peekFxForward res >>= \res' ->
errorCheck a9'>>
return (res')
{-# LINE 123 "./QuantLib/Instrument/Forward.chs" #-}
fxForwardRate :: (FxForward) -> IO ((Double))
fxForwardRate a1 =
withGenInstrument a1 $ \a1' ->
fxForwardRate'_ a1' >>= \res ->
let {res' = realToFrac res} in
return (res')
{-# LINE 127 "./QuantLib/Instrument/Forward.chs" #-}
fairForwardRate :: (FxForward) -> IO ((Double))
fairForwardRate a1 =
withGenInstrument a1 $ \a1' ->
preErrorCheck $ \a2' ->
fairForwardRate'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 130 "./QuantLib/Instrument/Forward.chs" #-}
npvSourceCurrency :: (FxForward) -> IO ((Double))
npvSourceCurrency a1 =
withGenInstrument a1 $ \a1' ->
preErrorCheck $ \a2' ->
npvSourceCurrency'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 133 "./QuantLib/Instrument/Forward.chs" #-}
npvTargetCurrency :: (FxForward) -> IO ((Double))
npvTargetCurrency a1 =
withGenInstrument a1 $ \a1' ->
preErrorCheck $ \a2' ->
npvTargetCurrency'_ a1' a2' >>= \res ->
let {res' = realToFrac res} in
errorCheck a2'>>
return (res')
{-# LINE 136 "./QuantLib/Instrument/Forward.chs" #-}
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardRateAgreement"
forwardRateAgreement'_ :: ((C2HSImp.Ptr (CIborIndex')) -> (C2HSImp.CInt -> (C2HSImp.CInt -> (C2HSImp.CInt -> (C2HSImp.CDouble -> (C2HSImp.CDouble -> ((C2HSImp.Ptr (CYieldTermStructure')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO (C2HSImp.Ptr (CForwardRateAgreement')))))))))))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlBondForward"
bondForward'_ :: (C2HSImp.CInt -> (C2HSImp.CInt -> (C2HSImp.CInt -> (C2HSImp.CDouble -> (C2HSImp.CUInt -> ((C2HSImp.Ptr (CDayCounter)) -> ((C2HSImp.Ptr (CCalendar)) -> (C2HSImp.CInt -> ((C2HSImp.Ptr (CBond')) -> ((C2HSImp.Ptr (CYieldTermStructure')) -> ((C2HSImp.Ptr (CYieldTermStructure')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO (C2HSImp.Ptr (CBondForward')))))))))))))))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlBondForwardCleanForwardPrice"
cleanForwardPrice'_ :: ((C2HSImp.Ptr (CBondForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlBondForwardForwardPrice"
forwardPrice'_ :: ((C2HSImp.Ptr (CBondForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardForwardValue"
forwardValue'_ :: ((C2HSImp.Ptr (CForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardImpliedYield"
impliedYield'_ :: ((C2HSImp.Ptr (CForward')) -> (C2HSImp.CDouble -> (C2HSImp.CDouble -> (C2HSImp.CInt -> (C2HSImp.CInt -> ((C2HSImp.Ptr (CDayCounter)) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO (C2HSImp.Ptr (CInterestRate))))))))))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardSettlementDate"
settlementDate'_ :: ((C2HSImp.Ptr (CForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CInt)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardSpotIncome"
spotIncome'_ :: ((C2HSImp.Ptr (CForward')) -> ((C2HSImp.Ptr (CYieldTermStructure')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble))))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardSpotValue"
spotValue'_ :: ((C2HSImp.Ptr (CForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardRateAgreementForwardRate"
forwardRate'_ :: ((C2HSImp.Ptr (CForwardRateAgreement')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO (C2HSImp.Ptr (CInterestRate)))))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlForwardRateAgreementAmount"
amount'_ :: ((C2HSImp.Ptr (CForwardRateAgreement')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlFxForward"
fxForward'_ :: (C2HSImp.CDouble -> ((C2HSImp.Ptr (CCurrency)) -> (C2HSImp.CDouble -> ((C2HSImp.Ptr (CCurrency)) -> (C2HSImp.CInt -> (C2HSImp.CInt -> (C2HSImp.CUInt -> ((C2HSImp.Ptr (CCalendar)) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO (C2HSImp.Ptr (CFxForward'))))))))))))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlFxForward1"
fxForwardFromRate'_ :: (C2HSImp.CDouble -> ((C2HSImp.Ptr (CCurrency)) -> ((C2HSImp.Ptr (CCurrency)) -> (C2HSImp.CDouble -> (C2HSImp.CInt -> (C2HSImp.CInt -> (C2HSImp.CUInt -> ((C2HSImp.Ptr (CCalendar)) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO (C2HSImp.Ptr (CFxForward'))))))))))))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlFxForwardForwardRate"
fxForwardRate'_ :: ((C2HSImp.Ptr (CFxForward')) -> (IO C2HSImp.CDouble))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlFxForwardFairForwardRate"
fairForwardRate'_ :: ((C2HSImp.Ptr (CFxForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlFxForwardNpvSourceCurrency"
npvSourceCurrency'_ :: ((C2HSImp.Ptr (CFxForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))
foreign import ccall safe "QuantLib/Instrument/Forward.chs.h qlFxForwardNpvTargetCurrency"
npvTargetCurrency'_ :: ((C2HSImp.Ptr (CFxForward')) -> ((C2HSImp.Ptr (C2HSImp.Ptr ())) -> (IO C2HSImp.CDouble)))