Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: Integral types and own type definitions (was Re: Suggested method for returning a string from a C program?) Date: Mon, 31 Mar 2025 14:56:35 -0700 Organization: None to speak of Lines: 24 Message-ID: <87bjtgsw30.fsf@nosuchdomain.example.com> References: <20250325011327.41@kylheku.com> <20250325131110.000056bd@yahoo.com> <86bjtpjp22.fsf@linuxsc.com> <87iknw7sz8.fsf@nosuchdomain.example.com> <87sen05cza.fsf@nosuchdomain.example.com> <87o6xn60qc.fsf@nosuchdomain.example.com> <87zfh74exe.fsf@nosuchdomain.example.com> MIME-Version: 1.0 Content-Type: text/plain Injection-Date: Mon, 31 Mar 2025 23:56:37 +0200 (CEST) Injection-Info: dont-email.me; posting-host="c78d518dd8bd555ded4f4434dc3e2aaf"; logging-data="1442803"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/sa0DRF/axfH3CJt91r5Ae" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:YgCxIUaJgwZj1pqDsxY6HyY4HSk= sha1:DW3IparYjrvFZ+ACyCySPOlvTtU= Bytes: 2334 Alan Mackenzie writes: > Keith Thompson wrote: > > [ .... ] > >> I don't know of any language that uses "-" for both negation (prefix, >> one operand) and subtraction (infix, two operands) and treats -5 >> as a single token rather than a unary minus operator applied to the >> constant/literal "5". > > How about Lisp? The unary operator is (- 5), the binary (- 10 5). > > It doesn't match your second parenthetical remark ("infix") but > otherwise it does. I know about Lisp. It doesn't match my description, for the reasons you pointed out. It use of -5 as a single token doesn't present the problems it would in a more C-like language. [...] -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com void Void(void) { Void(); } /* The recursive call of the void */