Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: James Kuyper Newsgroups: comp.lang.c,comp.std.c Subject: Re: Microsoft abandons the C language Date: Wed, 29 Aug 2012 14:51:27 -0400 Organization: A noiseless patient Spider Lines: 25 Message-ID: <503E64AF.6000205@verizon.net> References: <50396253.4040309@loria.fr> <87fw76kgp8.fsf@huddi.jernurt.dk> <503D17CA.5020105@loria.fr> <503D4315.7030702@loria.fr> <503DD8C1.2070703@loria.fr> <503E252A.6050309@loria.fr> <503E5F4E.5010604@loria.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Injection-Info: mx04.eternal-september.org; posting-host="d8fef572ea43a1acd556896aa70d63af"; logging-data="9257"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18P3Dfl4OTwTcq2dJEF/d5q0Cz3/fJdweE=" User-Agent: Mozilla/5.0 (X11; Linux i686; rv:14.0) Gecko/20120713 Thunderbird/14.0 In-Reply-To: <503E5F4E.5010604@loria.fr> Cancel-Lock: sha1:aXkKyOhzm1XaMQOCYkFy2fdDJHY= Xref: csiph.com comp.lang.c:25418 comp.std.c:1615 On 08/29/2012 02:28 PM, Jens Gustedt wrote: ... [citing 6.7.4p10, which is a non-normative example] > ... A file scope declaration with extern creates an external definition. ... > extern double fahr(double); // creates an external definition That comment is inconsistent with my understanding of the normative text of the standard. In particular, 6.9p5 requires that an external definition define be the definition of either a function or an object. It's clearly not an external definition of an object, and the grammar for a function definition in 6.9.1p1 requires a compound-statement which is missing from that statement. My understanding is that, in conflict with 6.7.4p10, a file scope declaration with extern, but no corresponding compound statement defining the body of the function, is not a definition, and in particular, is not an external definition, nor does it somehow cause such a definition to be created. Is the non-normative text of 6.7.4p10 incorrect, or my understanding of C? Possibly, both?