Version française
Home     About     Download     Resources     Contact us    
Browse thread
allocating memory for c-structures
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: micha <micha-1@f...>
Subject: allocating memory for c-structures
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