1 new commit in cc-mode:
https://bitbucket.org/xemacs/cc-mode/commits/8cd5f9d0c1bd/
Changeset: 8cd5f9d0c1bd
User: acm
Date: 2017-12-19 17:57:25+00:00
Summary: Fix loss of documentation face in certain CC Mode doc comment situations
* cc-fonts.el (c-font-lock-doc-comments): Take into account the possibility of
font-lock-comment-delimiter-face. Test rigorously for "/**" (etc.) being
itself inside a literal, rather than just depending on the face of the
previous character.
Affected #: 1 file
diff -r 125218d347ca602b4f09318fb79c8ca6fb895fc9 -r
8cd5f9d0c1bd6c994ffca85187003ff53c554280 cc-fonts.el
--- a/cc-fonts.el
+++ b/cc-fonts.el
@@ -2666,8 +2666,8 @@
;; This function might do hidden buffer changes.
(let (comment-beg region-beg)
- (if (eq (get-text-property (point) 'face)
- 'font-lock-comment-face)
+ (if (memq (get-text-property (point) 'face)
+ '(font-lock-comment-face font-lock-comment-delimiter-face))
;; Handle the case when the fontified region starts inside a
;; comment.
(let ((start (c-literal-start)))
@@ -2687,8 +2687,15 @@
(or (not (c-got-face-at comment-beg
c-literal-faces))
(and (/= comment-beg (point-min))
+ ;; Cheap check which is unreliable (the previous
+ ;; character could be the end of a previous
+ ;; comment).
(c-got-face-at (1- comment-beg)
- c-literal-faces))))
+ c-literal-faces)
+ ;; Expensive reliable check.
+ (save-excursion
+ (goto-char comment-beg)
+ (c-in-literal)))))
(setq comment-beg nil))
(setq region-beg comment-beg))
Repository URL:
https://bitbucket.org/xemacs/cc-mode/
--
This is a commit notification from
bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.