Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Dec 1998 19:40:58 +0900
From:      "Daniel C. Sobral" <dcs@newsguy.com>
To:        current@FreeBSD.ORG
Subject:   Re: BootFORTH - demo floppy 
Message-ID:  <367E25BA.5C386267@newsguy.com>

next in thread | raw e-mail | index | archive | help
At Mon, 21 Dec 1998 00:55:50 -0800, you wrote
>
>I'm all in favor of pushing FICL more in the direction of standards
>conformance, to be sure. The I/O model in particular is rather
>primitive since FICL was designed specifically to chew on strings
>rather than be a more traditional console-based forth and I'd love to
>see some of that brought back.

Not sure what that means, but ANS Forth kind of makes Forth very
string-chewing as far as the command interpreter/compiler goes. The
old
INTERPRET is obsolete, and the "heart" of the interpreter machine is
now
EVALUATE. Still, I expect to be a interpreting/compiling flag
_somewhere_,
that could be read by whatever is printing the prompt. But that's just
a side
not. What I really meant to say is...

>My own forth skills have seriously atrophied, unfortunately, and I'm
>generally not up on the newer ANS standards or even the older stuff
>which wasn't explicitly covered in the Brodie book. :-)
>
>If you see such conformance violations, a precise description of what
>the primitive should be returning or taking instead would be
>appreciated. Diffs to the code are, of course, appreciated even more! :)

The last draft of ANS Forth is available on the Internet (easily
reachable
from www.forth.org/literature.html --
html://www.forth.org/dpans/dpans.html
for on-line reference) on a number of different printable formats. The
final
version of ANS Forth is very much like that draft, so it is quite
useful.

This might not be exactly the tool for learning Forth, but it does go
to some
extent to explain the Forth model, Forth assumptions, and differences
between
ANS Forth standard and the previous ones, so anyone 

As for the behavior of EVALUATE... Well it receives a buffer and a
char count,
and it should restrict itself to that. Currently, it just ignores the
char
count. This is not a problem with the old boot code commands, btw. I
checked
that (in fact, if I had not been experimenting with the old boot code
commands, it would have taken me a lot more time to find the bug :).

To quote from the above link:

Relevant text from the Standard:

6.1.1360 EVALUATE 
... Make the string described by c-addr and u both the 'input source'
and
'input buffer' ... 
6.1.2216 SOURCE 
... c-addr is the address of, and u is the number of characters in,
the
'input buffer'. 
2.1 Definitions of Terms 
input source: 
The device, file, block, or other entity that supplies characters to
refill the 'input buffer'. 
input buffer: 
A region of memory containing the sequence of characters from the
input source that is currently accessible to a program. 

-- 
Daniel C. Sobral			(8-DCS)
dcs@newsguy.com

	You can't modify a constant, float upstream, win an argument
with the IRS, or satisfy this compiler

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?367E25BA.5C386267>