caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Xavier Leroy <xavier.leroy@inria.fr>
To: yminsky@cs.cornell.edu
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] Counting bits in a big_int
Date: Sun, 16 May 2004 09:30:02 +0200	[thread overview]
Message-ID: <20040516093002.A43@pauillac.inria.fr> (raw)
In-Reply-To: <891bd339040515131939afd837@mail.gmail.com>; from yminsky@gmail.com on Sat, May 15, 2004 at 04:19:04PM -0400

> 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


      parent reply	other threads:[~2004-05-16  7:30 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-12  3:22 Yaron Minsky
2004-05-12  4:19 ` Michael Hoisie
     [not found] ` <16547.8441.559944.112854@gargle.gargle.HOWL>
     [not found]   ` <891bd3390405130427180c36d6@mail.gmail.com>
     [not found]     ` <16547.27869.60461.270873@gargle.gargle.HOWL>
2004-05-15  2:53       ` Yaron Minsky
2004-05-15 11:14         ` Markus Mottl
2004-05-15 20:19           ` Yaron Minsky
2004-05-16  0:51             ` skaller
2004-05-16  7:30             ` Xavier Leroy [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040516093002.A43@pauillac.inria.fr \
    --to=xavier.leroy@inria.fr \
    --cc=caml-list@inria.fr \
    --cc=yminsky@cs.cornell.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).