j
: Next unread message k
: Previous unread message j a
: Jump to all threads
j l
: Jump to MailingList overview
Hello,
I'm plodding my way through OF1275.
In section 3.2.2.3.1 reference is made to the Forth words
DEFER INSTANCE BUFFER:
I couldn't find these in the DPANS94 spec... anyone know what these are? I never did much with ANS Forth, so I am not sure why I can't find these words in the docs. Perhaps INSTANCE and BUFFER: are specific to OF?
I assume DEFER is for deferred definition/vectored execution words. Why isn't it in ANS spec?
Thanks,
-- John.
__________________________________________________ Do You Yahoo!? LAUNCH - Your Yahoo! Music Experience http://launch.yahoo.com - To unsubscribe: send mail to majordomo@freiburg.linux.de with 'unsubscribe openbios' in the body of the message http://www.freiburg.linux.de/OpenBIOS/ - free your system..
On Tue, May 21, 2002 at 09:52:27PM -0700, John R. Hogerhuis wrote:
DEFER
think of it as a forward declaration.
defer foobar
creates a word foobar that displays a message, sth like "tried execution of an uninitialized defer word" which can be overwritten by
['] foobar ( the old name) to some-forth-word
if you run foobar after that, it does the same as some-forth-word
cannot be used inside a colon definition
INSTANCE
creates the next occurence of buffer, defer, value or variable instance specific. that way it'll get reallocated each time an instance of that package is created
ex. from IEEE1275: ok 30 instance value new-name
BUFFER:
creates a named buffer of a given size which returns the address of the first byte on execution ex. from IEEE1275:
100 buffer: new-name ( creates a buffer called new-name which has 100 bytes) 55 new-name 20 + c! ( writes 55 in new-name[20])
I couldn't find these in the DPANS94 spec... anyone know what these are? I never did much with ANS Forth, so I am not sure why I can't find these words in the docs. Perhaps INSTANCE and BUFFER: are specific to OF?
OF uses a subset of ANS but extends it with own words - I think the same thing is achieved with different words in ANS and OF at some places
hope I could help, patrick mauritz
OF uses a subset of ANS but extends it with own words - I think the same thing is achieved with different words in ANS and OF at some places
OF actually has a (slightly) different definition of some words than ANS, has some extra "standard" Forth words that ANS has not, and doesn't have some of the ANS required words. Confused yet?
Cheers,
Segher
- To unsubscribe: send mail to majordomo@freiburg.linux.de with 'unsubscribe openbios' in the body of the message http://www.freiburg.linux.de/OpenBIOS/ - free your system..