unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
* Re: (sqrt long-digit-string)
@ 2003-02-11 18:25 Nelson H. F. Beebe
  2003-02-12  5:35 ` Dale P. Smith
  0 siblings, 1 reply; 2+ messages in thread
From: Nelson H. F. Beebe @ 2003-02-11 18:25 UTC (permalink / raw)
  Cc: beebe

I just tried the posted example of (sqrt long-digit-string) with
guile 1.6.3 on Sun Solaris and got similar scanner errors.

I then chopped off trailing digits and made repeated experiments.
With an input line of 256 characters, guile reports a reasonable
numeric answer.   With 257 characters, it goes into a wait state.
With 258 character, it reports the scanner error.

Evidently, there is some sloppy, and unreasonably limited, buffer
handling going on here.  Lisp programs should be able to read tokens
of arbitrary length (limited only by available memory); otherwise,
bignum arithmetic is infeasible.

-------------------------------------------------------------------------------
- Nelson H. F. Beebe                    Tel: +1 801 581 5254                  -
- Center for Scientific Computing       FAX: +1 801 581 4148                  -
- University of Utah                    Internet e-mail: beebe@math.utah.edu  -
- Department of Mathematics, 110 LCB        beebe@acm.org  beebe@computer.org -
- 155 S 1400 E RM 233                       beebe@ieee.org                    -
- Salt Lake City, UT 84112-0090, USA    URL: http://www.math.utah.edu/~beebe  -
-------------------------------------------------------------------------------


_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-devel


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: (sqrt long-digit-string)
  2003-02-11 18:25 (sqrt long-digit-string) Nelson H. F. Beebe
@ 2003-02-12  5:35 ` Dale P. Smith
  0 siblings, 0 replies; 2+ messages in thread
From: Dale P. Smith @ 2003-02-12  5:35 UTC (permalink / raw)


On Tue, 11 Feb 2003 11:25:44 -0700 (MST)
"Nelson H. F. Beebe" <beebe@math.utah.edu> wrote:

> I just tried the posted example of (sqrt long-digit-string) with
> guile 1.6.3 on Sun Solaris and got similar scanner errors.
> 
> I then chopped off trailing digits and made repeated experiments.
> With an input line of 256 characters, guile reports a reasonable
> numeric answer.   With 257 characters, it goes into a wait state.
> With 258 character, it reports the scanner error.

It works for me in 1.6.3 on intel, using rlb's .debs.

The reader starts out with a token buffer of 30, and then doubles it
each time it overflows.  30 60 120 240 480.  It doesn't line up at 256.

Just a hunch.  Try it without readline, if you are using it.

-Dale

-- 
Dale P. Smith
Senior Systems Consultant,      | Treasurer,
Altus Technologies Corporation  | Cleveland Linux Users Group
dsmith@altustech.com            | http://cleveland.lug.net
440-746-9000 x239               |


_______________________________________________
Guile-devel mailing list
Guile-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-devel


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-02-12  5:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-02-11 18:25 (sqrt long-digit-string) Nelson H. F. Beebe
2003-02-12  5:35 ` Dale P. Smith

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).