From owner-cvs-src Wed Mar 19 22:51: 1 2003 Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 96AE837B404; Wed, 19 Mar 2003 22:50:58 -0800 (PST) Received: from HAL9000.homeunix.com (12-233-57-224.client.attbi.com [12.233.57.224]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5593F43F75; Wed, 19 Mar 2003 22:50:57 -0800 (PST) (envelope-from das@FreeBSD.ORG) Received: from HAL9000.homeunix.com (localhost [127.0.0.1]) by HAL9000.homeunix.com (8.12.6/8.12.5) with ESMTP id h2K6oumR004825; Wed, 19 Mar 2003 22:50:56 -0800 (PST) (envelope-from das@FreeBSD.ORG) Received: (from das@localhost) by HAL9000.homeunix.com (8.12.6/8.12.5/Submit) id h2K6ouRQ004824; Wed, 19 Mar 2003 22:50:56 -0800 (PST) (envelope-from das@FreeBSD.ORG) Date: Wed, 19 Mar 2003 22:50:56 -0800 From: David Schultz To: "Andrey A. Chernov" Cc: src-committers@FreeBSD.ORG, cvs-src@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/contrib/gdtoa gdtoaimp.h Message-ID: <20030320065056.GA4680@HAL9000.homeunix.com> Mail-Followup-To: "Andrey A. Chernov" , src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org References: <200303192025.h2JKPjNr000550@repoman.freebsd.org> <20030320050712.GA48184@nagual.pp.ru> <20030320054502.GA4308@HAL9000.homeunix.com> <20030320061316.GA48935@nagual.pp.ru> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030320061316.GA48935@nagual.pp.ru> Sender: owner-cvs-src@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Thus spake Andrey A. Chernov : > On Wed, Mar 19, 2003 at 21:45:02 -0800, David Schultz wrote: > > Do you see anything else I should bug the vendor about while I'm at > > it? > > So far I notice one thing only: > > char decimalpoint = *localeconv()->decimal_point; > > ... and then decimalpoint used everywhere in the code. > > But localeconv() can return "" for any value which is legally not in the > current locale. decimalpoint becomes '\0' in that case which cause > unwanted effects. [...] From C99 7.11.2.1.3: The members of the structure with type char * are pointers to strings, any of which (except decimal_point) can point to "", to indicate that the value is not available in the current locale or is of zero length. Thus, the present code should be fine. > > > The next thing is style: why > > > #include "locale.h" > > > instead of > > > #include ? > > > > With one exception, the author uses that convention consistently. > > I don't think so - I saw , in the author's code. It > may affect cross-platform building when standard includes moved to other > place and gcc instructed to find them there. The latter is the one exception I was talking about. The former is part of an auxiliary program, not the library. Anyway, the use of quotes instead of angle brackets shouldn't make a difference unless somoone decides to put (for example) a broken float.h in libc's $MAKEOBJDIR. I will mention this to David Gay in any case. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-src" in the body of the message