Popularity
1.6
Declining
Activity
0.0
Declining
1
2
0
Monthly Downloads: 12
Programming language: Haskell
License: Mozilla Public License 2.0
Tags:
Foreign
Latest version: v0.2.0.0
marshal-contt alternatives and similar packages
Based on the "Foreign" category.
Alternatively, view marshal-contt alternatives based on common mentions on social networks and blogs.
-
erlang
A Foreign Function Interface that lets Haskell and Erlang programs communicate. -
emacs-module
Wrappers around emacs-module.h to write Emacs modules in Haskell -
greencard
Green Card, a foreign function interface pre-processor for Haskell. -
c-storable-deriving
Derivation of C-like Storable Instances -
tasty-lua
Integrate Lua tests into tasty. This package is now part of the hslua monorepo. -
hslua-module-text
Lua module providing a selected set of operations on Text. NOTE: moved into the hslua monorepo. -
hslua-module-system
HsLua module for system and directory functions. This repository has been moved to the hslua monorepo. -
hslua-module-doclayout
Lua module wrapping Text.DocLayout. -
cusolver
Haskell FFI bindings to CUDA Solver, a LAPACK-like library -
hlibcpuid
Haskell bindings to https://github.com/anrieff/libcpuid -
foreign-storable-asymmetric
Types and instances for implementing a Storable with different peek and poke
Access the most powerful time series database as a service
Ingest, store, & analyze all types of time series data in a fully-managed, purpose-built database. Keep data forever with low-cost storage and superior data compression.
Promo
www.influxdata.com
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of marshal-contt or a related project?
Popular Comparisons
README
marshal-contt
A ContT-based wrapper for the bracket-style Haskell-to-C marshalling functions in base
and bytestring
.
Example:
type Argv = [BS.ByteString]
type Env = M.Map BS.ByteString BS.ByteString
allocStringArrayWith :: [BS.ByteString] -> ContT r IO (Ptr CString)
allocStringArrayWith = allocaArrayWith0' withCString
allocStringMapWith :: M.Map BS.ByteString BS.ByteString -> (Ptr CString -> IO a) -> IO a
allocStringMapWith = iallocaArrayWith0' (\(k, v) -> withCString $ k <> "=" <> v)
spawn :: FilePath -> [FileActions] -> Argv -> Env -> IO ProcessID
spawn path actions argv env = flip runContT return $ do
cPath <- withCString path
cAction <- withFileActions actions
cArgv <- allocStringArrayWith argv
cEnv <- marshalEnv env
pidPtr <- alloca
liftIO . throwErrnoIf_ (/= 0) path $
posix_spawn pidPtr cPath cActions nullSpawnAttrs cArgv cEnv
liftIO $ peek pidPtr
spawnp :: String -> [FileActions] -> Argv -> Env -> IO ProcessID
spawnp command actions argv env = flip runContT return $ do
cPath <- withCString path
cAction <- withFileActions actions
cArgv <- allocStringArrayWith argv
cEnv <- marshalEnv env
pidPtr <- alloca
liftIO . throwErrnoIf_ (/= 0) path $
posix_spawnp pidPtr cPath cActions nullSpawnAttrs cArgv cEnv
liftIO $ peek pidPtr