Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
* allocating memory for c-structures
@ 2006-12-26 18:15 micha
  2006-12-26 18:33 ` [Caml-list] " skaller
  2006-12-26 18:35 ` Richard Jones
  0 siblings, 2 replies; 4+ messages in thread
From: micha @ 2006-12-26 18:15 UTC (permalink / raw)
  To: OCaml Mailing List

Normaly I allocate memory for c-structures with malloc or with "new" for 
c++ objects. Some time ago a read about a library which places external 
structures in strings of the interfacing languages (it was a scheme lib 
I think). So instead of using malloc or new I would allocate an 
ocaml-string and put the c-structure there. So it will be free by the gc.
That seems o.k. for me, any comments? I'm missing something?

cheers
 Michael


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2006-12-26 18:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-12-26 18:15 allocating memory for c-structures micha
2006-12-26 18:33 ` [Caml-list] " skaller
2006-12-26 18:35 ` Richard Jones
2006-12-26 18:55   ` micha

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox