From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#24258: 25.1.50: In C++ `for' statement, second declaration is misfontified. Date: Thu, 18 Aug 2016 10:21:33 +0000 Message-ID: <20160818102133.GA3790@acm.fritz.box> References: <20160818090415.GA3030@acm.fritz.box> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: blaine.gmane.org 1471515951 860 195.159.176.226 (18 Aug 2016 10:25:51 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 18 Aug 2016 10:25:51 +0000 (UTC) User-Agent: Mutt/1.5.24 (2015-08-30) Cc: 24258@debbugs.gnu.org To: Arash Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Aug 18 12:25:47 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1baKW9-0008Lr-Kp for geb-bug-gnu-emacs@m.gmane.org; Thu, 18 Aug 2016 12:25:45 +0200 Original-Received: from localhost ([::1]:51757 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1baKW6-0004WF-Q3 for geb-bug-gnu-emacs@m.gmane.org; Thu, 18 Aug 2016 06:25:42 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:51028) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1baKTZ-0002H5-Fu for bug-gnu-emacs@gnu.org; Thu, 18 Aug 2016 06:23:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1baKTW-0006Rl-8R for bug-gnu-emacs@gnu.org; Thu, 18 Aug 2016 06:23:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:34891) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1baKTW-0006Rh-5j for bug-gnu-emacs@gnu.org; Thu, 18 Aug 2016 06:23:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1baKTW-0007hL-1U for bug-gnu-emacs@gnu.org; Thu, 18 Aug 2016 06:23:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 18 Aug 2016 10:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 24258 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 24258-submit@debbugs.gnu.org id=B24258.147151572729514 (code B ref 24258); Thu, 18 Aug 2016 10:23:02 +0000 Original-Received: (at 24258) by debbugs.gnu.org; 18 Aug 2016 10:22:07 +0000 Original-Received: from localhost ([127.0.0.1]:60836 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1baKSd-0007fy-2k for submit@debbugs.gnu.org; Thu, 18 Aug 2016 06:22:07 -0400 Original-Received: from mail.muc.de ([193.149.48.3]:33216) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1baKSZ-0007fn-Ue for 24258@debbugs.gnu.org; Thu, 18 Aug 2016 06:22:05 -0400 Original-Received: (qmail 41409 invoked by uid 3782); 18 Aug 2016 10:22:01 -0000 Original-Received: from acm.muc.de (p548C63BB.dip0.t-ipconnect.de [84.140.99.187]) by colin.muc.de (tmda-ofmipd) with ESMTP; Thu, 18 Aug 2016 12:22:01 +0200 Original-Received: (qmail 3813 invoked by uid 1000); 18 Aug 2016 10:21:33 -0000 Content-Disposition: inline In-Reply-To: <20160818090415.GA3030@acm.fritz.box> X-Delivery-Agent: TMDA/1.1.12 (Macallan) X-Primary-Address: acm@muc.de X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:122353 Archived-At: Hello, Arash. On Thu, Aug 18, 2016 at 09:04:15AM +0000, Alan Mackenzie wrote: > In C++ Mode, in the following: > for (int32 a = 0, int32 b = 0; ; ) { > } > , the second "int32" is getting font-lock-variable-name-face and "b" is > left unfontified. This is a bug. I'm not convinced that the above is correct syntax; the following, I think, would be correct: for (int32 a = 0, b = 0 ; ... ; ...) { ... } , but I don't think a second type (before the "b") is allowed. I've even tried it out with a compiler. If this is the case, then CC Mode is behaving reasonably in fontifying the second "int32" as a variable - it draws the programmer's attention to something being wrong. -- Alan Mackenzie (Nuremberg, Germany).