-
Notifications
You must be signed in to change notification settings - Fork 52
Closed
Labels
Milestone
Description
I've found no mention in documentation about this, so I assume that this is a bug. For example:
#include <string.h>
{#fun strcmp as ^ { `CString', `CString' } -> `CInt' #}
Produces the following error:
c2hs: Errors during expansion of binding hooks:
test.chs:3: (column 47) [ERROR] >>> Missing "out" marshaller!
There is no default marshaller for this combination of Haskell and C type:
Haskell type: CInt
C type : CInt
And if I switch CInt to Int, then:
c2hs: Errors during expansion of binding hooks:
test.chs:3: (column 21) [ERROR] >>> Missing "in" marshaller!
There is no default marshaller for this combination of Haskell and C type:
Haskell type: CString
C type : (Ptr CChar)
I can use 'id' as a marshaller, but in my opinion, this is a workaround and C-types should work out of the box.