Path: csiph.com!news.mixmin.net!eternal-september.org!reader01.eternal-september.org!.POSTED!not-for-mail From: Tim Rentsch Newsgroups: comp.lang.c Subject: Re: Limitation of MS-DOS C compiler? (was Re: Should I convert FORTRAN code to C?) Date: Mon, 26 Dec 2022 05:20:31 -0800 Organization: A noiseless patient Spider Lines: 26 Message-ID: <86y1quwbc0.fsf@linuxsc.com> References: <10655@agate.BERKELEY.EDU> <1857@hubcap.UUCP> <8807121629.AA07169@explorer.dgp.toronto.edu> <2807@ttrdc.UUCP> <853b5253-ab29-4e38-9e81-a1d9312e5e2dn@googlegroups.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: reader01.eternal-september.org; posting-host="b017513bf0c3c2565b748ac271e0e545"; logging-data="3451334"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/+Y/z/uD/kbkE9h0SzX74mGJjNWFQcE9Y=" User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.4 (gnu/linux) Cancel-Lock: sha1:GPmwYTvrLSb0PMIEl/1hgkhlkGM= sha1:WIu9tzTkn4e0QSf4TpFrx2afy5s= Xref: csiph.com comp.lang.c:168635 antispam@math.uni.wroc.pl writes: > Lynn McGuire wrote: > >> I doubt that any modern C/C++ compilers refuse to take any legal >> C/C++ code. I would not be surprised that modern C/C++ compilers >> detect certain benchmarks > > Some time ago I posted here a simple C program. It looks legal > (nobody here objected to legality of this program). In principle > compiler should generate pretty small executable, but it looks > that no existing compiler can handle that program. One can say > that compiler does not "reject" the program, simply compiler runs > out of memory. But for the user effect is the same: compiler > will not handle legal program. And the answer is the same as before. The C language is infinitely large (and indeed must be if it is to be Turing complete). Compilers are programs; no program can deal with unboundedly large inputs (not counting the vanishingly small fraction of programs whose output set is finite rather than infinite). No competent person expects a compiler (or indeed any non-trivial program) to be able to handle unboundedly large inputs. A program that is unable to handle a large input simply because of its size is not "refusing" to handle the input, and anyone who says otherwise is just being obtuse.