projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
90d258c
)
Analyze and fontify correctly a C++ `enum' with colon, but lacking a tag.
author
Alan Mackenzie
<acm@muc.de>
Wed, 24 Aug 2016 01:18:20 +0000
(
01:18
+0000)
committer
Alan Mackenzie
<acm@muc.de>
Wed, 24 Aug 2016 01:18:20 +0000
(
01:18
+0000)
* lisp/progmodes/cc-engine.el (c-backward-typed-enum-colon): Check for "enum"
directly preceding the colon, and handle it.
lisp/progmodes/cc-engine.el
patch
|
blob
|
history
diff --git
a/lisp/progmodes/cc-engine.el
b/lisp/progmodes/cc-engine.el
index ccdc1b15a6823a0ab4cfa287b3d1638b81d2248c..940d7a4cc3e915eed60fe4fcfdc722fc69356893 100644
(file)
--- a/
lisp/progmodes/cc-engine.el
+++ b/
lisp/progmodes/cc-engine.el
@@
-9756,7
+9756,10
@@
comment at the start of cc-engine.el for more info."
((and (eql (char-after) ?:)
(save-excursion
(c-backward-syntactic-ws)
- (c-on-identifier)))
+ (or (c-on-identifier)
+ (progn
+ (c-backward-token-2)
+ (looking-at c-brace-list-key)))))
(setq colon-pos (point))
(forward-char)
(c-forward-syntactic-ws)