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 BAA12123; Sun, 12 Jan 2003 01:15:49 +0100 (MET) 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 BAA12175 for ; Sun, 12 Jan 2003 01:15:48 +0100 (MET) Received: from rocket.naverex.net (rocket.naverex.net [213.169.64.107]) by concorde.inria.fr (8.11.1/8.11.1) with ESMTP id h0C0Fkr27582 for ; Sun, 12 Jan 2003 01:15:46 +0100 (MET) Received: from uni.net.ua (uni.naverex.kiev.ua [213.169.64.137]) by rocket.naverex.net (8.Who.Cares/8.Who.Cares) with ESMTP id h0C0Fg39099419 for ; Sun, 12 Jan 2003 02:15:43 +0200 (EET) (envelope-from tema@sit.kiev.ua) Received: from lena [195.5.26.217] by uni.net.ua [213.169.83.1] with SMTP (MDaemon.PRO.v5.0.5.R) for ; Sun, 12 Jan 2003 02:15:11 +0200 From: Artem Prisyznuk To: Daniel.Andor@physics.org Cc: Caml List Date: Sun, 12 Jan 2003 02:20:42 +0300 X-Priority: 3 (Normal) In-Reply-To: <200301111907.51989.da209@cam.ac.uk> Message-Id: Subject: Re: [Caml-list] C -> CAML linking: loosing values in arrays?? MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Mailer: Opera 6.0 build 1010 X-MDRemoteIP: 195.5.26.217 X-Return-Path: tema@sit.kiev.ua X-MDaemon-Deliver-To: caml-list@inria.fr Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk 11.01.03 22:07:51, Daniel Andor wrote: >If I pass a non-array double using copy_double(), it works and I get the >correct number on the other side. > >Any ideas as to where I've gone wrong? >>From Caml manual: .... 18.3.3 Arrays Arrays of integers and pointers are represented like tuples, that is, as pointers to blocks tagged 0. They are accessed with the Field macro for reading and the modify function for writing. Arrays of floating-point numbers (type float array) have a _special, unboxed_, more efficient representation. These arrays are represented by pointers to blocks with tag Double_array_tag. They should be accessed with the Double_field and Store_double_field macros. .... > >Thanks, >Daniel. >------------------- >To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr >Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ >Beginner's list: http://groups.yahoo.com/group/ocaml_beginners > ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners