unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Andreas Rottmann <a.rottmann@gmx.at>
To: Guile Development <guile-devel@gnu.org>
Subject: Random numbers (again) broken on 64-bit platforms
Date: Mon, 26 Jul 2010 23:01:56 +0200	[thread overview]
Message-ID: <87vd82554r.fsf@delenn.lan> (raw)

Hi!

After pulling from Git today, I noticed that `random' is still/again
broken on 64-bit platforms:

scheme@(guile-user)> (random (ash 1 32))
ERROR: In procedure random:
ERROR: Argument 1 out of range: 4294967296

This looks like being caused by
b606ff6af9c9ec7fc3c4473c09ce1e95c18f024a, which doesn't take into
account (in scm_random) that an INUM may well exceed 32 bits on 64-bit
platforms. I'll try to come up with a patch for that, unless someone
beats me to it.

Regards, Rotty
-- 
Andreas Rottmann -- <http://rotty.yi.org/>



             reply	other threads:[~2010-07-26 21:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-26 21:01 Andreas Rottmann [this message]
2010-07-27  8:52 ` Random numbers (again) broken on 64-bit platforms Andy Wingo
2010-08-01 18:44   ` Andreas Rottmann
2010-08-01 19:57     ` Andy Wingo
2010-08-01 22:06       ` No Itisnt
2010-08-02  7:11         ` Andy Wingo

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

  List information: https://www.gnu.org/software/guile/

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

  git send-email \
    --in-reply-to=87vd82554r.fsf@delenn.lan \
    --to=a.rottmann@gmx.at \
    --cc=guile-devel@gnu.org \
    /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 read-only IMAP folder(s) and NNTP newsgroup(s).