Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!zephyr.ens.tek.com!tekcrl!tekgvs!toma From: toma@tekgvs.LABS.TEK.COM (Tom Almy) Newsgroups: comp.lang.forth Subject: Re: interactive control structures Message-ID: <6601@tekgvs.LABS.TEK.COM> Date: 3 Jan 90 19:32:01 GMT References: <2620@tukki.jyu.fi> Reply-To: toma@tekgvs.LABS.TEK.COM (Tom Almy) Organization: Tektronix, Inc., Beaverton, OR. Lines: 42 In article <2620@tukki.jyu.fi> tsaari@tukki.jyu.fi (Antero Taivalsaari) writes: >In 1987 I built a Forth (for VAX/VMS) which now seems to be based >on similar ideas that are used in that STOIC system you mention, >although I'm completely unfamiliar with STOIC. >My system, which I (at that time unaware of the other dozen systems >with equivalent name) named Fifth (Fully Interactive ForTH), >has many similarities to the code presented by Mitch Bradley [Description of operation deleted] Your system sounds quite like STOIC, but STOIC only compiled into one location (The "compiler buffer"). When carriage return was hit and the nesting level was zero, then the code in the compiler buffer would be executed and then tossed. The current nesting level was part of the prompt. The Colon word in STOIC copies the following contents of the compiler buffer, up to the "semicolon" marker into the dictionary. Clever! One additional user-friendly feature was that the tokenizer (equivalent to Forth WORD) tokenized string literals. Thus strings would be pushed on the stack and used just like numeric literals. STOIC was completely postfix -- words taking string arguments got them off of the stack instead of reading from the input stream (another confusing factor to the novice). >...Yes, I know it isn't standard Forth anymore, but it has encouraged >me to believe that there is no reason why I shouldn't be able to use >DO-LOOPs and IFs interactively in normal Forth systems, too. But it doesn't break any existing Forth code. It is a perfect extension to the language. One last novice-confusing factor. The use of the decimal point to indicate a double precision integer *AND* the fact it doesn't matter where the decimal point is! My PRIDE CAD system redefines the numeric input routines so that the suffix "D" is used to indicate double integers, and a decimal point indicates a floating point literal, like people are used to. Tom Almy toma@tekgvs.labs.tek.com Standard Disclaimers Apply