From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA09784; Mon, 15 Oct 2001 17:51:51 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id RAA10075 for ; Mon, 15 Oct 2001 17:51:50 +0200 (MET DST) Received: from d12lmsgate-2.de.ibm.com (d12lmsgate-2.de.ibm.com [195.212.91.200]) by concorde.inria.fr (8.11.1/8.10.0) with ESMTP id f9FFpnv17645 for ; Mon, 15 Oct 2001 17:51:49 +0200 (MET DST) Received: from d12relay02.de.ibm.com (d12relay02.de.ibm.com [9.165.215.23]) by d12lmsgate-2.de.ibm.com (1.0.0) with ESMTP id RAA93652 for ; Mon, 15 Oct 2001 17:51:44 +0200 Received: from d10hubm1.telaviv.ibm.com (d10ml001.telaviv.ibm.com [9.148.216.55]) by d12relay02.de.ibm.com (8.11.1m3/NCO v4.97.1) with ESMTP id f9FFphu132566 for ; Mon, 15 Oct 2001 17:51:43 +0200 Importance: Normal Subject: [Caml-list] Small request To: caml-list@inria.fr X-Mailer: Lotus Notes Release 5.0.7 March 21, 2001 Message-ID: From: "Ohad Rodeh" Date: Mon, 15 Oct 2001 18:50:13 +0300 X-MIMETrack: Serialize by Router on D10ML001/10/M/IBM(Release 5.0.8 |June 18, 2001) at 15/10/2001 18:51:44 MIME-Version: 1.0 Content-type: text/plain; charset=us-ascii Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk While I'm at it, there is one more function that could help me: val Marshal.length : 'a -> extern_flags list -> int This hypothetical function returns the length that an object will be marshaled to. This allows pre-allocating a C buffer of the correct size, and then marshaling an ML object directy into it. This prevents memory fragmentation on the C-size. Ohad. ------------------- Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr