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 PAA19880; Sun, 21 Oct 2001 15:14:07 +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 PAA18629 for ; Sun, 21 Oct 2001 15:14:06 +0200 (MET DST) Received: from relay.rinet.ru (relay.rinet.ru [195.54.192.35]) by concorde.inria.fr (8.11.1/8.10.0) with ESMTP id f9LDE5514570 for ; Sun, 21 Oct 2001 15:14:05 +0200 (MET DST) Received: (from uucp@localhost) by relay.rinet.ru (8.11.6/8.11.4) with UUCP id f9LDDxD08516 for caml-list@inria.fr; Sun, 21 Oct 2001 17:13:59 +0400 (MSD) X-Envelope-To: caml-list@inria.fr Received: from bely.stormoff (BELY) [192.168.0.10] by stormoff with esmtp (Exim 2.05 #1 (Debian)) id 15vINw-0002Xw-00; Sun, 21 Oct 2001 17:11:24 +0400 X-Comment-To: malc To: caml-list@inria.fr Subject: Re: [Caml-list] Troubles with C->Caml References: From: Dmitry Bely Date: 21 Oct 2001 17:10:27 +0400 In-Reply-To: Message-ID: User-Agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Academic Rigor) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk malc writes: > > > result = alloc_small (1, 2); > > > Field (result, 0) = ; > > > Field (result, 1) = Extract_exception (res); > > > > FAQ. When calling allocating functions, the GC may move the values of > > the heap. The variable "res", of type "value", is actually a pointer > > to the heap. After the call to "alloc_small", its pointed value may > > have been moved by the GC, but "res" still points to the old area. > > Well, the real code contains all the necessary CAMLxxx decorations, and > yet it still coredumps. And belive me, i read everything i could find > on the subject before posting the question. Furthermore i found that > C code in OCaml distribution is very inconsistent w.r.t CAMLxxx macros, > and its hard to draw any conclusions from there. Why simply not to use CamlIDL and forget about all this problems forever? Hope to hear from you soon, Dmitry ------------------- 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