(save-rec-ref-ids c-record-ref-identifiers)
;; Set when we parse a declaration which might also be an expression,
;; such as "a *b". See CASE 16 and CASE 17.
- maybe-expression)
+ maybe-expression
+ ;; Set for the type when `c-forward-type' returned `maybe', and we
+ ;; want to fontify it as a type, but aren't confident enough to enter
+ ;; it into `c-found-types'.
+ unsafe-maybe)
(save-excursion
(goto-char preceding-token-end)
;; a statement beginning with an identifier.
(when (and (eq at-type 'maybe)
(not (eq context 'top)))
- (setq c-record-type-identifiers nil))
+ (setq unsafe-maybe t))
(throw 'at-decl-or-cast t))
;; CASE 11
;; fontification just because it's "a known type that can't
;; be a name or other expression". 2013-09-18.
)
- (let ((c-promote-possible-types t))
+ (let ((c-promote-possible-types
+ (if unsafe-maybe 'just-one t)))
(save-excursion
(goto-char type-start)
(c-forward-type))))