From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Tino Calancha Newsgroups: gmane.emacs.devel Subject: Re: Wrong fontification in C source Date: Tue, 13 Sep 2016 04:48:24 +0900 (JST) Message-ID: References: <20160912192338.GB29886@acm.fritz.box> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed X-Trace: blaine.gmane.org 1473709956 18877 195.159.176.226 (12 Sep 2016 19:52:36 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 12 Sep 2016 19:52:36 +0000 (UTC) User-Agent: Alpine 2.20 (DEB 67 2015-01-07) Cc: Emacs developers , Tino Calancha To: Alan Mackenzie Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Sep 12 21:52:32 2016 Return-path: Envelope-to: ged-emacs-devel@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 1bjXHJ-0003vY-4A for ged-emacs-devel@m.gmane.org; Mon, 12 Sep 2016 21:52:29 +0200 Original-Received: from localhost ([::1]:44863 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjXHK-0007OK-6Z for ged-emacs-devel@m.gmane.org; Mon, 12 Sep 2016 15:52:30 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34480) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjXET-00050R-3n for emacs-devel@gnu.org; Mon, 12 Sep 2016 15:49:34 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bjXEO-0006dY-Ty for emacs-devel@gnu.org; Mon, 12 Sep 2016 15:49:32 -0400 Original-Received: from mail-pa0-f48.google.com ([209.85.220.48]:33097) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bjXEO-0006dS-Nz for emacs-devel@gnu.org; Mon, 12 Sep 2016 15:49:28 -0400 Original-Received: by mail-pa0-f48.google.com with SMTP id cm16so53786309pac.0 for ; Mon, 12 Sep 2016 12:49:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:date:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=BRZpcoVi3ZZCxs0GFqQ2ubRU14j2tmEEDu5XRWbWa/k=; b=WZ0vE/wNOimWeOGSGnu6Q7Po5jHwXcMhtxativ+1HBPhh37feMIYBEcAjNzJNvKOJo oWn6r+di/8k9HURrAyHG0r3AqFagH9hEwFnTWjDwH+g9uoDpLzH45tKx7WxiajZ+xU5y eIDu2E/aU4AP5aEgtXfP5H3mRyUsAgKMOj5GDxxYUYdr4xsfs3ZjeDrbPMiXlb0A2fGV pK+3WILdqatgA4vk/Z4hGa/E15MDHs/LQVchZi7icUV03OuceP2VGbN8Una4NUsJ3V2q G055K6usK9TXh56EqaZIGH0ys8uJOZAvUSVYUhnK5Sns8e/QTjNI7o5DuVemWg3C3tzv J3xQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:date:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=BRZpcoVi3ZZCxs0GFqQ2ubRU14j2tmEEDu5XRWbWa/k=; b=U3zv6vpPbzO2R3+t8fT/A/7pF5O5Hrj6Tn01kwY6eGm+VUrWPmQqw4wB8lDKBKbo4h U0cHLkA6rRZCHN95e5ftCwsbWX1jEPIG0d0622T1KsBto30rq5X6LD37K74Bxx5qyOqx LA2fafcC0L5wa8qG90lY2NAMhgz8WEWVCTPtziK2OQhM4FF2eu4TNAMqlBleKY4MPhwj lm+WLA8vI5F+y4ASYR+CA1iYi9h60iJDySp7bY7yXwDlN4RlAxcD3xAUfYE1KjmXzvPb CBnugYRyJ4Wqf1V21kQv2nQGdJOvmuB698i5QXkgHUEe+M1SETYftS61NuDtF6Rsi0gn V0qw== X-Gm-Message-State: AE9vXwOpJU/GGTS2sMH+JA5pbgwiY7pRXwtpSfukbMAcqC4NRVtJR5nQH5gUVot81/qHYA== X-Received: by 10.66.148.167 with SMTP id tt7mr36563857pab.21.1473709707765; Mon, 12 Sep 2016 12:48:27 -0700 (PDT) Original-Received: from calancha-pc (57.92.100.220.dy.bbexcite.jp. [220.100.92.57]) by smtp.gmail.com with ESMTPSA id x126sm26355983pfx.61.2016.09.12.12.48.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 12 Sep 2016 12:48:27 -0700 (PDT) X-Google-Original-From: Tino Calancha X-X-Sender: calancha@calancha-pc In-Reply-To: <20160912192338.GB29886@acm.fritz.box> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.220.48 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:207398 Archived-At: On Mon, 12 Sep 2016, Alan Mackenzie wrote: > Hello, Tino. > > On Wed, Aug 31, 2016 at 12:31:00AM +0900, Tino Calancha wrote: > >> Hi Alan, > >> I've just noticed that after commit: >> 578d9aaf82b386c1a0316dde491d297e18e10636 >> in Emacs C source code, >> 'DEFUN' gets face 'default' instead of 'font-lock-function-name-face'. > > OK. This is not necessarily a bug; "DEFUN" is not the name of the > function being defined, therefore it is not obvious why it should get > font-lock-function-name-face. If anything should get that face, it is > the identifier beginning with "F...". That's right. > If, with SW older than 578d9a..., you type instead "DFUN", or any other > string, this also gets fontified with font-lock-function-name-face > (possibly at first needing M-o M-o). So it is not "DEFUN" as such which > is being fontified, it is rather the identifier in that position. > > So, the sensible thing to do is either (i) enhance the fontification > part of CC Mode to handle DEFUN (and DEFVAR, ....) properly; or (ii) > decide that the situation is "not a bug". Given how much work it would > take to parse DEFUN and friends, and the fact that they're not used > outside of Emacs development, I'm inclined to go for alternative (ii). I agree. I just got used to see DEFUN with a nice blue color, but your argument convinced me. Regards, Tino