From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15585 invoked by alias); 12 Jan 2004 18:55:24 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 15564 invoked from network); 12 Jan 2004 18:55:22 -0000 Received: from unknown (HELO localhost.redhat.com) (216.129.200.20) by sources.redhat.com with SMTP; 12 Jan 2004 18:55:22 -0000 Received: from gnu.org (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 4BF542B8F; Mon, 12 Jan 2004 13:55:21 -0500 (EST) Message-ID: <4002ED99.5000108@gnu.org> Date: Mon, 12 Jan 2004 18:55:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0.2) Gecko/20030820 MIME-Version: 1.0 To: Eli Zaretskii Cc: gdb-patches@sources.redhat.com Subject: Re: [rfc, rfa:doco] Add -Wunused-label to -Werror list References: <400180C8.70803@gnu.org> <3405-Sun11Jan2004203155+0200-eliz@elta.co.il> Content-Type: multipart/mixed; boundary="------------090803060900010001060904" X-SW-Source: 2004-01/txt/msg00320.txt.bz2 This is a multi-part message in MIME format. --------------090803060900010001060904 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-length: 282 > Date: Sun, 11 Jan 2004 11:58:48 -0500 >> From: Andrew Cagney >> >> Eli, doco look ok? > > > Yes, except that I'd suggest to say more explicitly what is the > programming error being shown in that fragment. Someone might not get > it... Something like ...? --------------090803060900010001060904 Content-Type: text/plain; name="diffs" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="diffs" Content-length: 1697 2004-01-12 Andrew Cagney * gdbint.texinfo: Update copyright year. (Coding): Add -Wunused-label to list of -Werror warnings. Index: gdbint.texinfo =================================================================== RCS file: /cvs/src/src/gdb/doc/gdbint.texinfo,v retrieving revision 1.178 diff -u -r1.178 gdbint.texinfo --- gdbint.texinfo 10 Nov 2003 22:47:31 -0000 1.178 +++ gdbint.texinfo 12 Jan 2004 18:53:52 -0000 @@ -8,7 +8,7 @@ @ifinfo This file documents the internals of the GNU debugger @value{GDBN}. -Copyright 1990,1991,1992,1993,1994,1996,1998,1999,2000,2001,2002,2003 +Copyright 1990,1991,1992,1993,1994,1996,1998,1999,2000,2001,2002,2003,2004 Free Software Foundation, Inc. Contributed by Cygnus Solutions. Written by John Gilmore. Second Edition by Stan Shebs. @@ -48,7 +48,7 @@ @vskip 0pt plus 1filll Copyright @copyright{} 1990,1991,1992,1993,1994,1996,1998,1999,2000,2001, - 2002, 2003 Free Software Foundation, Inc. + 2002, 2003, 2004 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or @@ -5132,6 +5132,23 @@ @item -Wpointer-arith @item -Wuninitialized + +@item -Wunused-label +This warning has the additional benefit of detecting the absence of the +@code{case} reserved word in a switch statement: +@smallexample +enum @{ FD_SCHEDULED, NOTHING_SCHEDULED @} sched; +@dots{} +switch (sched) + @{ + case FD_SCHEDULED: + @dots{}; + break; + NOTHING_SCHEDULED: + @dots{}; + break; + @} +@end smallexample @end table @emph{Pragmatics: Due to the way that @value{GDBN} is implemented most --------------090803060900010001060904--