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 JAA32178; Sun, 16 May 2004 09:30:21 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id JAA32444 for ; Sun, 16 May 2004 09:30:20 +0200 (MET DST) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by nez-perce.inria.fr (8.12.10/8.12.10) with ESMTP id i4G7U2EV024480; Sun, 16 May 2004 09:30:02 +0200 Received: (from xleroy@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id JAA00232; Sun, 16 May 2004 09:30:02 +0200 (MET DST) Date: Sun, 16 May 2004 09:30:02 +0200 From: Xavier Leroy To: yminsky@cs.cornell.edu Cc: caml-list@inria.fr Subject: Re: [Caml-list] Counting bits in a big_int Message-ID: <20040516093002.A43@pauillac.inria.fr> References: <891bd3390405112022194630a8@mail.gmail.com> <16547.8441.559944.112854@gargle.gargle.HOWL> <891bd3390405130427180c36d6@mail.gmail.com> <16547.27869.60461.270873@gargle.gargle.HOWL> <891bd3390405141953628db08a@mail.gmail.com> <20040515111433.GA32168@fichte.ai.univie.ac.at> <891bd339040515131939afd837@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0i In-Reply-To: <891bd339040515131939afd837@mail.gmail.com>; from yminsky@gmail.com on Sat, May 15, 2004 at 04:19:04PM -0400 X-Miltered: at nez-perce with ID 40A7187A.001 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 nat:01 undocumented:01 nat:01 low-level:01 undocumented:01 low-level:01 api:01 valerie:01 rt-:99 api:01 abstraction:01 ocaml:01 ocaml:01 caml:01 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk > Nice. The weird thing about the Nat module is that it's completely > undocumented. Is there any reason to think it wil be stable between > revisions? For instance, does Xavier's reimplementation have the same > Num module with the same interface as the previous one? The Nat interface hasn't changed since the beginning of OCaml, and my recent reimplementation of the low-level primitives preserved its interface. > I guess my real question is: why is Nat undocumented? Nat is a very low-level API, based on in-place modification of sub-numbers of big integers. Consequently, it's hard to use directly, and it's also hard to document. The lack of documentation is both an encouragement not to use it, and an evidence that we are lazy :-) If you really want to know what Nat does, the following tech rep is useful: "The CAML Numbers Reference Manual" by Valerie Menissier-Morain, technical report 141, INRIA, july 1992, available at ftp://ftp.inria.fr/INRIA/publication/RT/RT-0141.ps.gz. It documents the Caml V3.1 API for exact-precision arithmetic, but the part of it that deals with the "nat" abstraction still applies to the Nat module of OCaml. - Xavier Leroy ------------------- 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