Deutsch English Français Italiano |
<v5phah$168u$1@dont-email.me> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Richard Harnden <richard.nospam@gmail.invalid> Newsgroups: comp.lang.c Subject: Re: Baby X is bor nagain Date: Sat, 29 Jun 2024 18:46:56 +0100 Organization: A noiseless patient Spider Lines: 42 Message-ID: <v5phah$168u$1@dont-email.me> References: <v494f9$von8$1@dont-email.me> <v53i4s$33k73$2@dont-email.me> <v53lf7$34huc$1@dont-email.me> <v53vh6$368vf$1@dont-email.me> <v54se1$3bqsk$1@dont-email.me> <20240624160941.0000646a@yahoo.com> <v5bu5r$va3a$1@dont-email.me> <20240624181006.00003b94@yahoo.com> <v5c86d$11ac7$1@dont-email.me> <JEheO.108086$ED9b.74955@fx11.iad> <v5cblg$11q0j$1@dont-email.me> <gEieO.108089$ED9b.25598@fx11.iad> <20240625113616.000075e0@yahoo.com> <mUzeO.141609$Cqra.55051@fx10.iad> <v5elql$1jmii$1@dont-email.me> <m3BeO.24907$Gurd.16179@fx34.iad> <v5empd$1jndv$2@dont-email.me> <v5eph4$1k6a9$1@dont-email.me> <87ed8jnbmf.fsf@bsb.me.uk> <v5jhls$2m7np$1@dont-email.me> <v5jm32$2nqvp$1@dont-email.me> <v5k3v2$2qllm$1@dont-email.me> <v5kfst$2svt3$1@dont-email.me> <v5kmlm$2u918$1@dont-email.me> <20240627201830.854@kylheku.com> <v5m2nl$39qob$3@dont-email.me> <20240628032211.403@kylheku.com> <v5p4rv$3u92q$1@dont-email.me> Reply-To: nospam.harnden@invalid.com MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Date: Sat, 29 Jun 2024 19:46:57 +0200 (CEST) Injection-Info: dont-email.me; posting-host="59c5ac1a170b791d952ea5e96b57aa8c"; logging-data="39198"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19oRy8Rdv+zKD5bEAg8c43etHAVw8r3y1U=" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:op2cZ9zaKTElTr8TQy0erdHrUn4= In-Reply-To: <v5p4rv$3u92q$1@dont-email.me> Content-Language: en-GB Bytes: 2908 On 29/06/2024 15:14, bart wrote: [...] > My older bcc compiler reported 4 as a hard error unless an override was > used. But you didn't say anything about main's args. Make that 'int main(void)', then it does what you'd expect: bart.c:17:5: error: too many arguments to function ‘main’ 17 | main(123); // 4 Unchecked arg types | ^~~~ bart.c:13:5: note: declared here 13 | int main(void) { | ^~~~ > [...] > > ------------------------- > #include <stdio.h> > #include <stdlib.h> > > int F(void) { > return; // 1 No value > } > > int G(void) { > if (rand()) > return 0; > } // 2 Possibly running into end > > int main() { > char s[10]; > char *p = &s; // 3 Wrong types > > main(123); // 4 Unchecked arg types > } > ------------------------- >