Path: ...!weretis.net!feeder9.news.weretis.net!i2pn.org!i2pn2.org!.POSTED!not-for-mail From: dxf Newsgroups: comp.lang.forth Subject: Re: Back & Forth - Co-routines Date: Sat, 22 Mar 2025 10:26:45 +1100 Organization: i2pn2 (i2pn.org) Message-ID: References: <49736c0ec0e34ca5d67f4e0d6e8cbe2a080e38ab@i2pn2.org> <2ec5cfbd438db9be750543c9ebddfa6ffa17583c@i2pn2.org> <00c65eb0d61675581c8e5bd83d47295e47b23eb4@i2pn2.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Injection-Date: Fri, 21 Mar 2025 23:26:45 -0000 (UTC) Injection-Info: i2pn2.org; logging-data="1195358"; mail-complaints-to="usenet@i2pn2.org"; posting-account="XPw7UV90Iy7EOhY4YuUXhpdoEf5Vz7K+BsxA/Cx8bVc"; User-Agent: Mozilla Thunderbird Content-Language: en-GB X-Spam-Checker-Version: SpamAssassin 4.0.0 In-Reply-To: Bytes: 1855 Lines: 22 On 21/03/2025 11:27 pm, Hans Bezemer wrote: > ... > Nice test - I bet it wouldn't be too hard to implement at least part of the Forth-200x implementation ;-) > > Sometin' like define {: > 1. Parse a word; > 2. If not :} then create a (local); > 3. Repeat. > > Ok, this is horrible code, it needs the VALUES in reverse, but it works: > > : :} ; > : {: begin ' dup ['] :} <> while >body postpone literal postpone (local) repeat drop ; immediate > > : test {: b a :} a b / ; I'd just call that LOCAL| and be done. Can't say I ever found the syntax an annoyance. I appreciate it might not be ideal for doing Windows API calls...