summaryrefslogtreecommitdiff
path: root/lisp/progmodes/cc-engine.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/progmodes/cc-engine.el')
-rw-r--r--lisp/progmodes/cc-engine.el7
1 files changed, 6 insertions, 1 deletions
diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el
index c42c95764a2..db1f46621da 100644
--- a/lisp/progmodes/cc-engine.el
+++ b/lisp/progmodes/cc-engine.el
@@ -9978,7 +9978,12 @@ This function might do hidden buffer changes."
(save-excursion
(goto-char type-start)
(let ((c-promote-possible-types t))
- (c-forward-type)))))
+ (c-forward-type))))
+
+ ;; Signal a type declaration for "struct foo {".
+ (when (and backup-at-type-decl
+ (eq (char-after) ?{))
+ (setq at-type-decl t)))
(setq backup-at-type at-type
backup-type-start type-start