From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7742 invoked by alias); 14 Jan 2002 10:37:31 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 7704 invoked from network); 14 Jan 2002 10:37:29 -0000 Received: from unknown (HELO fw-cam.cambridge.arm.com) (193.131.176.3) by sources.redhat.com with SMTP; 14 Jan 2002 10:37:29 -0000 Received: by fw-cam.cambridge.arm.com; id KAA25178; Mon, 14 Jan 2002 10:37:28 GMT Received: from unknown(172.16.1.2) by fw-cam.cambridge.arm.com via smap (V5.5) id xma025063; Mon, 14 Jan 02 10:37:20 GMT Received: from cam-mail2.cambridge.arm.com (localhost [127.0.0.1]) by cam-admin0.cambridge.arm.com (8.9.3/8.9.3) with ESMTP id KAA06786; Mon, 14 Jan 2002 10:37:18 GMT Received: from sun18.cambridge.arm.com (sun18.cambridge.arm.com [172.16.2.18]) by cam-mail2.cambridge.arm.com (8.9.3/8.9.3) with ESMTP id KAA23594; Mon, 14 Jan 2002 10:37:17 GMT Message-Id: <200201141037.KAA23594@cam-mail2.cambridge.arm.com> X-Mailer: exmh version 2.0.2 2/24/98 To: Eli Zaretskii cc: Andrew Cagney , gdb@sources.redhat.com, Richard.Earnshaw@arm.com Reply-To: Richard.Earnshaw@arm.com Organization: ARM Ltd. X-Telephone: +44 1223 400569 (direct+voicemail), +44 1223 400400 (switchbd) X-Fax: +44 1223 400410 X-Address: ARM Ltd., 110 Fulbourn Road, Cherry Hinton, Cambridge CB1 9NJ. X-Url: http://www.arm.com/ Subject: Re: how to format an error? In-reply-to: Your message of "Mon, 14 Jan 2002 10:21:25 +0200." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Mon, 14 Jan 2002 02:37:00 -0000 From: Richard Earnshaw X-SW-Source: 2002-01/txt/msg00145.txt.bz2 > > On Sun, 13 Jan 2002, Andrew Cagney wrote: > > > Given the attached, which is the correct way of formatting an error message: > > > > This is an error message. > > this is an error message. > > This is an error message > > this is an error message > > I suggest the last variant. It goes with the GNU coding standards > except for the capitalization. But capitalization is > language-specific (e.g., in German, all nouns are capitalized), and it > was recently discovered in Emacs development that a 100% adherence to > the capitalization rule you cited produces wrong results in some > cases. Most of the messages don't need caps, so I think losing that > is the best alternative which is simple enough to adher to. Hmm, I'd go for the third. If the message were to appear in a GUI box, it could well be a line of text on its own, such as ************* ERROR ************** * * * This is an error message * * * ********************************** In such a context I think it would be very wrong to start this with a lower-case letter. However, exceptions: strings extracted from user code shouldn't have the case changed, so print foo error: Foo doesn't exist would be wrong. Though I think this should be "'foo' doesn't exist" Given that, (and that a litteral will never appear in the first letter) can we safely assume that we can capitalize the first letter during printing? If so, we could mandate that all messages in the source code should start with a lower case letter (except where other capitalization rules apply) and then have the UI output routine capitalize the first letter as appropriate for the output stream? R.