-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Lets you embed C++ code into Haskell. -- -- Utilities to inline C++ code into Haskell using inline-c. See tests -- for example on how to build. @package inline-c-cpp @version 0.5.0.1 -- | Module exposing a Context to inline C++ code. We only have used -- this for experiments, so use with caution. See the C++ tests to see -- how to build inline C++ code. module Language.C.Inline.Cpp -- | The equivalent of baseCtx for C++. It specifies the -- .cpp file extension for the C file, so that g++ will decide -- to build C++ instead of C. See the .cabal test target for an -- example on how to build. cppCtx :: Context cppTypePairs :: [(CIdentifier, TypeQ)] -> Context -- | Emits an using directive, e.g. -- --
--   C.using "namespace std" ==> using namespace std
--   
using :: String -> DecsQ -- | Marks an std::exception_ptr. Only used via Ptr. data AbstractCppExceptionPtr -- | A module that contains exception-safe equivalents of inline-c -- QuasiQuoters. module Language.C.Inline.Cpp.Exception -- | An exception thrown in C++ code. data CppException CppStdException :: CppExceptionPtr -> ByteString -> Maybe ByteString -> CppException CppHaskellException :: SomeException -> CppException CppNonStdException :: CppExceptionPtr -> Maybe ByteString -> CppException type CppExceptionPtr = ForeignPtr AbstractCppExceptionPtr -- | Like toException but unwrap CppHaskellException toSomeException :: CppException -> SomeException -- | Like tryBlock, but will throw unwrapped -- CppHaskellExceptions or other CppExceptions rather than -- returning them in an Either throwBlock :: QuasiQuoter -- | Similar to block, but C++ exceptions will be caught and the -- result is (Either CppException value). The return type must be void or -- constructible with {}. Using this will automatically include -- exception, cstring and cstdlib. tryBlock :: QuasiQuoter -- | Variant of throwBlock for blocks which return void. catchBlock :: QuasiQuoter tryBlockQuoteExp :: QuasiQuoter -> String -> Q Exp instance GHC.Show.Show Language.C.Inline.Cpp.Exception.CppException instance GHC.Exception.Type.Exception Language.C.Inline.Cpp.Exception.CppException -- | Deprecated: Language.C.Inline.Cpp.Exceptions is deprecated in favor -- of Language.C.Inline.Cpp.Exception which changes the CppException data -- type to preserve the exception for custom error handling. module Language.C.Inline.Cpp.Exceptions -- | An exception thrown in C++ code. data CppException CppHaskellException :: SomeException -> CppException pattern CppStdException :: String -> CppException pattern CppOtherException :: Maybe String -> CppException -- | Like toException but unwrap CppHaskellException toSomeException :: CppException -> SomeException -- | Like tryBlock, but will throw unwrapped -- CppHaskellExceptions or other CppExceptions rather than -- returning them in an Either throwBlock :: QuasiQuoter -- | Similar to block, but C++ exceptions will be caught and the -- result is (Either CppException value). The return type must be void or -- constructible with {}. Using this will automatically include -- exception, cstring and cstdlib. tryBlock :: QuasiQuoter -- | Variant of throwBlock for blocks which return void. catchBlock :: QuasiQuoter -- | A module that contains exception-safe equivalents of inline-c -- QuasiQuoters. module Language.C.Inline.Cpp.Unsafe -- | Like tryBlock, but will throw unwrapped -- CppHaskellExceptions or other CppExceptions rather -- than returning them in an Either throwBlock :: QuasiQuoter -- | Similar to block, but C++ exceptions will be caught and the -- result is (Either CppException value). The return type must be void or -- constructible with {}. Using this will automatically include -- exception, cstring and cstdlib. tryBlock :: QuasiQuoter -- | Variant of throwBlock for blocks which return void. catchBlock :: QuasiQuoter -- | Like toException but unwrap CppHaskellException toSomeException :: CppException -> SomeException