From: Peter G. <pg...@gm...> - 2007-05-13 13:40:37
|
Hello, C2HS doesn't seem to handle Ptr (Ptr Foo) the way it should. For instance, in GnomeVFS, I have {# call gnome_vfs_open #}. The C prototype for that function is: GnomeVFSResult gnome_vfs_open (GnomeVFSHandle **handle, const gchar *text_uri, GnomeVFSOpenMode open_mode); But the import C2HS creates is: foreign import ccall safe " gnome_vfs_open_uri" gnome_vfs_open_uri :: ((Ptr Handle) -> ((Ptr URI) -> (CInt -> (IO CInt)))) Should I just ignore that and use castPtr? Pete |