Re: Import, how to
Henning Thielemann <[email protected]> Mon, 19 Jul 2010 00:04:57 +0200 (CEST)
| Newsgroups | gmane.comp.lang.haskell.ffi |
|---|---|
| Message-ID | <alpine.DEB.2.00.1007190004110.7507@anubis.informatik.uni-halle.de> |
On Sun, 18 Jul 2010, grzyb wrote: > I'm a beginner at haskell and ffi. I was trying to import and use is haskell > one C function, but I can't manage to do that. > > Can someone show me an example how to create an import and a use example for > such a C function: > char functionName(char *, unsigned int, char *) Something like foreign import functionName :: Ptr CChar -> CUInt -> Ptr CChar -> IO CChar