• Alan Mackenzie's avatar
    Prevent C++ Mode wrongly fontifying some identifiers near templates as types · 9151f16e
    Alan Mackenzie authored
    This fixes debbugs #7917.
    
    * lisp/progmodes/cc-engine.el (c-forward-keyword-prefixed-id): Accept 'maybe
    (from c-forward-type) as sufficient to record an id.  Record type id as well
    as ref ids.
    (c-forward-name): Bind c-last-identifier-range around the call to
    c-forward-<>-arglist to prevent it getting corrupted.  Don't automatically
    assume an identifier is a type when a template ">" is followed by a "(".
    (c-forward-type): Don't automatically assume an identifier is a type when a
    template ">" is followed by a "(".
    
    * lisp/progmodes/cc-fonts.el (c-font-lock-<>-arglists): Don't fontify an
    identifier as a type when its associated ">" is followed by a "(".
    9151f16e
cc-engine.el 418 KB