From: Alan Mackenzie <acm@muc.de>
To: Tino Calancha <tino.calancha@gmail.com>
Cc: Emacs developers <emacs-devel@gnu.org>
Subject: Re: Wrong fontification in C source
Date: Mon, 12 Sep 2016 19:23:38 +0000 [thread overview]
Message-ID: <20160912192338.GB29886@acm.fritz.box> (raw)
In-Reply-To: <alpine.DEB.2.20.1608310029350.23778@calancha-pc>
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...".
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).
> Regards,
> Tino
--
Alan Mackenzie (Nuremberg, Germany).
next prev parent reply other threads:[~2016-09-12 19:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-30 15:31 Wrong fontification in C source Tino Calancha
2016-09-12 19:23 ` Alan Mackenzie [this message]
2016-09-12 19:48 ` Tino Calancha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160912192338.GB29886@acm.fritz.box \
--to=acm@muc.de \
--cc=emacs-devel@gnu.org \
--cc=tino.calancha@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).