Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: anton@mips.complang.tuwien.ac.at (Anton Ertl) Newsgroups: comp.lang.forth Subject: Re: Operator overloading? Date: Wed, 31 Jul 2024 16:14:53 GMT Organization: Institut fuer Computersprachen, Technische Universitaet Wien Lines: 42 Message-ID: <2024Jul31.181453@mips.complang.tuwien.ac.at> References: Injection-Date: Wed, 31 Jul 2024 18:21:41 +0200 (CEST) Injection-Info: dont-email.me; posting-host="0bf0c08abe30c3d9331a628672875080"; logging-data="1759390"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18puQ4YPuFAONTcbOFnWPNP" Cancel-Lock: sha1:EbHUC2g0zwJQZHr3YSab0UCtQuY= X-newsreader: xrn 10.11 Bytes: 2510 Gerry Jackson writes: >On 31/07/2024 08:47, albert@spenarnc.xs4all.nl wrote: >> In article , >> Stephen Pelc wrote: >Here's a program that demonstrates a non-parsing TO: > > VFX Forth 64 for Windows x64 > © MicroProcessor Engineering Ltd, 1998-2023 > > Version: 5.43 [build 4238] > Build date: 9 November 2023 > > Free dictionary = 6731782 bytes [6574kb] > >111 value x x . 111 ok >222 to cr .( Does TO parse? ) x x 222 = [if] .( No it doesn't!) [then] >Does TO parse? No it doesn't! ok > >Using a flag means that x could be on another line or even in another file. > >You could argue that it's not a standard program because it contains a >deliberate ambiguous condition Exactly, it's not a standard program, and no particular behaviour is specified in the standard for this program. >so a parsing TO would fail in some way >but it does demonstrate non-compliant behaviour. Given that it's not a standard program and no particular behaviour is prescribed, the behaviour of VFX is compliant for this program. There may be some way to construct a compliant program using FIND, SEARCH-WORDLIST, TRAVERSE-WORDLIST, or FIND-NAME, where VFX does not behave compliantly, though. - anton -- M. Anton Ertl http://www.complang.tuwien.ac.at/anton/home.html comp.lang.forth FAQs: http://www.complang.tuwien.ac.at/forth/faq/toc.html New standard: https://forth-standard.org/ EuroForth 2024: https://euro.theforth.net