Deutsch English Français Italiano |
<vvr8eb$l85c$2@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!eternal-september.org!.POSTED!not-for-mail From: James Kuyper <jameskuyper@alumni.caltech.edu> Newsgroups: comp.lang.c Subject: Re: Loops (was Re: do { quit; } else { }) Date: Sun, 11 May 2025 18:30:35 -0400 Organization: A noiseless patient Spider Lines: 18 Message-ID: <vvr8eb$l85c$2@dont-email.me> References: <vspbjh$8dvd$1@dont-email.me> <vtdh4q$b3kt$1@dont-email.me> <vtf7fe$1qtpg$1@dont-email.me> <vtgfuf$31ug1$1@dont-email.me> <20250413072027.219@kylheku.com> <vtgpce$39229$1@dont-email.me> <vti2ki$g23v$1@dont-email.me> <vtin99$vu24$1@dont-email.me> <vtiuf0$18au8$1@dont-email.me> <vtj97r$1i3v3$1@dont-email.me> <vtl166$36p6b$1@dont-email.me> <vtlcg0$3f46a$2@dont-email.me> <20250415153419.00004cf7@yahoo.com> <86h62078i8.fsf@linuxsc.com> <20250504180833.00000906@yahoo.com> <86plggzilx.fsf@linuxsc.com> <vvnsvt$3k1mu$1@dont-email.me> <86ldr4yx0x.fsf@linuxsc.com> <vvpmm2$3dhl$1@dont-email.me> <vvpsji$4jht$1@dont-email.me> <vvr5mg$l85c$1@dont-email.me> <87wmam4xa5.fsf@nosuchdomain.example.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Injection-Date: Mon, 12 May 2025 00:30:36 +0200 (CEST) Injection-Info: dont-email.me; posting-host="73b6b0098675985745ffc6a28843a6c7"; logging-data="696492"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19Lm/PAB3k/Xz1FDa78r9obaPz1k1WcLGA=" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:4rY4UM8gc69cNbRqZfUmpIfEB0s= In-Reply-To: <87wmam4xa5.fsf@nosuchdomain.example.com> Content-Language: en-US Bytes: 2529 On 5/11/25 18:06, Keith Thompson wrote: > James Kuyper <jameskuyper@alumni.caltech.edu> writes: > [...] >> It's main potential usefulness is not in the definition of the function, >> but in calls to the function. If the calls occur in a different >> translation unit from the definition, the compiler does not have the >> needed information. > > It does if the visible declaration has the same information. True - I was responding to his claim that the information in the declaration was unneeded, because it's implicit in the function definition. That would be true if the primary purpose of this feature was to enable optimizations, but I don't thing it was. I think it was primarily intended to motivate (but not, unfortunately, mandate) warnings when the undefined behavior is predictable at compile time.