GNU bug report logs - #57075
CC Mode 5.35.1 (C/*l); Leaky fontification of xterm.c with font-lock-maximum-decoration set to 2

Previous Next

Package: cc-mode;

Reported by: Po Lu <luangruo <at> yahoo.com>

Date: Tue, 9 Aug 2022 12:32:02 UTC

Severity: normal

Full log


View this message in rfc822 format

From: Po Lu <luangruo <at> yahoo.com>
To: Alan Mackenzie <acm <at> muc.de>
Cc: 57075 <at> debbugs.gnu.org
Subject: bug#57075: CC Mode 5.35.1 (C/*l); Leaky fontification of xterm.c with font-lock-maximum-decoration set to 2
Date: Thu, 11 Aug 2022 09:44:05 +0800
Alan Mackenzie <acm <at> muc.de> writes:

> Yes.  It's the way level 2 does fontification of types.  Any declaration
> which starts with a standard type, like int, char, void, ..... gets
> fontified, additionally anything like struct foo *bar, and any type
> matching one of the following: 
>
>     ("\\sw+_t" "bool" "complex" "imaginary" "FILE" "lconv" "tm" "va_list"
>      "jmp_buf" "Lisp_Object")
>
> ..  So the types ending in _t, like xcb_translate_coordinates_cookie_t
> are getting fontified too, but not things like Atom or Window *.
>
> The merly partial fontification is the price for the extra speed one
> gets from level 2.  To fontify all declarations, we'd need the
> algorithms from f-l-maximum-decoration 3, and the speed would pretty
> much be down to that of f-l-m-d 3, too.
>
> Sorry nothing better is possible (at the moment).

Okay, thanks for explaining.




This bug report was last modified 3 years and 40 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.