Deutsch English Français Italiano |
<87wmozpqfl.fsf@bsb.me.uk> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!news.mixmin.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Ben Bacarisse <ben.usenet@bsb.me.uk> Newsgroups: comp.lang.c Subject: Re: Recursion, Yo Date: Sun, 14 Apr 2024 22:47:26 +0100 Organization: A noiseless patient Spider Lines: 44 Message-ID: <87wmozpqfl.fsf@bsb.me.uk> References: <uut24f$2icpb$1@dont-email.me> <uv4r9e$mdd3$1@dont-email.me> <uv5e3l$q885$1@dont-email.me> <uv5gfd$qum1$1@dont-email.me> <uv5lgl$s6uj$1@dont-email.me> <uv61f6$v1jm$1@dont-email.me> <uv68ok$11080$1@dont-email.me> <uv7a8n$18qf8$3@dont-email.me> <uv867l$1j8l6$1@dont-email.me> <_zSRN.161297$m4d.144795@fx43.iad> <20240411075825.30@kylheku.com> <r8TRN.114606$Wbff.54968@fx37.iad> <uva6ep$24ji7$1@dont-email.me> <uvah1j$26gtr$1@dont-email.me> <uvao71$27qit$1@dont-email.me> <uvb9r4$2c31v$1@dont-email.me> <uvcing$2kbfj$6@dont-email.me> <uveft2$346sv$1@dont-email.me> <uvf7vs$3911c$3@dont-email.me> <8734roqmdb.fsf@bsb.me.uk> <uvgjfr$3l055$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain Injection-Date: Sun, 14 Apr 2024 23:47:26 +0200 (CEST) Injection-Info: dont-email.me; posting-host="630246efbb215cbe93f34fc90f0492a3"; logging-data="4047830"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18NyKQ5VUbbFOgwEo4dGH2VHQUdOv9fKCU=" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:35/nvydDJdmff7Qv4YrLqCdRUwA= sha1:jiH+BgaCl4OBuQJ57VsnsRAdoo8= X-BSB-Auth: 1.f7e547da0bc0669ef2e8.20240414224726BST.87wmozpqfl.fsf@bsb.me.uk Bytes: 3275 bart <bc@freeuk.com> writes: > On 14/04/2024 11:17, Ben Bacarisse wrote: >> Lawrence D'Oliveiro <ldo@nz.invalid> writes: >> >>> On Sat, 13 Apr 2024 19:37:37 +0200, Janis Papanagnou wrote: >> ... >>>> But maybe you can explain where or how there's something "thrown away". >>> >>> This is a valid Algol 68 program (just tested with a68g): >>> >>> BEGIN PROC f = REAL : 3.1415; f END >>> >>> It calls f, which returns a real, which is then cast to VOID -- i.e. >>> thrown away. >> You are just arguing about how you want to use an informal term: namely >> to "throw away". In Algol 68, the mode (AKA type) "void" is, >> conceptually, a collection of values like any other. The coercion >> called voiding converts a value of some other type to the single value >> of type void. You could describe this a "throwing away the value", or >> you could agree with Janis and say that the serial-clause you wrote >> yields the sole value of type void. > > It looks to me as though it yields a type REAL, as would this: > > BEGIN 1.23 END > > If the context has no need for such a type, then it is discarded (although > my own language would report an error for constructs like this that make no > sense by themselves; most likely it is an actual mistake). > > But in one like this: > > REAL x := BEGIN 1.23 END > > Then that REAL value would be utilised. But what post posted was a whole program. The context -- it being the top-level serial clause matters. I think. I say I think because I'd like to find the wording that makes this so. a68g says it, but a68g is an implementation and not the final word. -- Ben.