From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Chong Yidong Newsgroups: gmane.emacs.bugs Subject: bug#5388: 23.1; syntactic analysis incorrect Date: Sat, 16 Jan 2010 16:00:14 -0500 Message-ID: <873a25ix41.fsf@stupidchicken.com> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1263676228 19231 80.91.229.12 (16 Jan 2010 21:10:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 16 Jan 2010 21:10:28 +0000 (UTC) Cc: 5388@debbugs.gnu.org To: "Odekirk\, Shawn" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Jan 16 22:10:21 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1NWFuW-0005BK-MX for geb-bug-gnu-emacs@m.gmane.org; Sat, 16 Jan 2010 22:10:21 +0100 Original-Received: from localhost ([127.0.0.1]:45468 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NWFuX-0006Lw-BG for geb-bug-gnu-emacs@m.gmane.org; Sat, 16 Jan 2010 16:10:21 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NWFtc-0005O8-To for bug-gnu-emacs@gnu.org; Sat, 16 Jan 2010 16:09:24 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NWFtY-0005K4-3T for bug-gnu-emacs@gnu.org; Sat, 16 Jan 2010 16:09:24 -0500 Original-Received: from [199.232.76.173] (port=39401 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NWFtX-0005Jy-TZ for bug-gnu-emacs@gnu.org; Sat, 16 Jan 2010 16:09:19 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:54677) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NWFtX-0005vS-NA for bug-gnu-emacs@gnu.org; Sat, 16 Jan 2010 16:09:19 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1NWFlW-0001wK-VN; Sat, 16 Jan 2010 16:01:03 -0500 X-Loop: bug-gnu-emacs@gnu.org In-Reply-To: Resent-From: Chong Yidong Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 16 Jan 2010 21:01:02 +0000 Resent-Message-ID: Resent-Sender: bug-gnu-emacs@gnu.org X-Emacs-PR-Message: followup 5388 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 5388-submit@debbugs.gnu.org id=B5388.12636756226376 (code B ref 5388); Sat, 16 Jan 2010 21:01:02 +0000 Original-Received: (at 5388) by debbugs.gnu.org; 16 Jan 2010 21:00:22 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NWFkq-0001dU-AL for submit@debbugs.gnu.org; Sat, 16 Jan 2010 16:00:22 -0500 Original-Received: from pantheon-po39.its.yale.edu ([130.132.50.100]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NWFkp-0001Yw-23 for 5388@debbugs.gnu.org; Sat, 16 Jan 2010 16:00:19 -0500 Original-Received: from furry (173-14-147-246-NewEngland.hfc.comcastbusiness.net [173.14.147.246]) (authenticated bits=0) by pantheon-po39.its.yale.edu (8.12.11.20060308/8.12.11) with ESMTP id o0GL0ER2002669 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Sat, 16 Jan 2010 16:00:14 -0500 Original-Received: by furry (Postfix, from userid 1000) id C6EC9C05D; Sat, 16 Jan 2010 14:00:14 -0700 (MST) X-YaleITSMailFilter: Version 1.2c (attachment(s) not renamed) X-Spam-Score: -3.4 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list X-Spam-Score: -3.4 (---) Resent-Date: Sat, 16 Jan 2010 16:01:03 -0500 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:34400 Archived-At: > A switch statement with two case labels, at least one of which is a > character constant, causes the syntactic analysis of the first > statement in the case block to be evaluated as statement-cont instead > of statement-case-intro. > > I believe the line 'x = 1;' should be evaluated as > statement-case-into, but it is being evaluated as statement-cont. > > switch (x) > { > case 'a': > case 'b': > x = 1; > y = 2; > break; > } Thanks for the bug report, but it does not contain enough information for us to do anything. I assume you are referring to C mode. However, if I paste your snippet into a fresh foo.c and call M-x c-syntactic-information-on-region, I get the following: switch (x) /* ((topmost-intro 1)) */ { /* ((substatement-open 1)) */ case 'a': /* ((case-label 42)) */ case 'b': /* ((case-label 42)) */ x = 1; /* ((statement-case-intro 117)) */ y = 2; /* ((statement 157)) */ break; /* ((statement 203)) */ } /* ((block-close 42)) */ As you can see, the snippet is correctly parsed. Please provide an exact, step-by-step recipe for reproducing this bug, starting with `emacs -Q'.