[gambit-list] C-FFI type issues
darren at wildfire.com.au
Thu Sep 17 00:41:03 EDT 2009
Is it the binding for clip_rect? It looks like you're trying to assign
a struct value type to pointer ___result_voidstar
You either want to allocate storage for a copy of the struct and use a
release function (per the c-lambda docs in the Gambit manual), or just
use pointers, eg:
(pointer (struct "SDL_Rect"))
"___result_voidstar = &___arg1->clip_rect;"))
Of course if you do this you have to be careful managing the lifetime of
the containing object so you don't get dangling pointers etc.
Hope that helps.
Isaac Freeman wrote:
> I've been banging my head on this one for days now... I've even tried
> looking at the resulting C code and passing it through the CPP and
> indent... I can't figure out where this is complaining about and
> Any hints would be great...
More information about the Gambit-list