]> git.eshelyaron.com Git - emacs.git/commitdiff
(c-specifier-key): Exclude "template" from this regexp; to allow the "{"
authorAlan Mackenzie <acm@muc.de>
Tue, 29 Jan 2008 20:30:54 +0000 (20:30 +0000)
committerAlan Mackenzie <acm@muc.de>
Tue, 29 Jan 2008 20:30:54 +0000 (20:30 +0000)
of a template function to be correctly anchored on "template", not the
following "<".

lisp/progmodes/cc-langs.el

index 9e8dd282e11e0a8f249f880aab48c96f9416b0cd..4c82fb522c078564c5c3359619899e31f6928e30 100644 (file)
@@ -1771,11 +1771,13 @@ one of `c-type-list-kwds', `c-ref-list-kwds',
 (c-lang-defvar c-prefix-spec-kwds-re (c-lang-const c-prefix-spec-kwds-re))
 
 (c-lang-defconst c-specifier-key
-  ;; Adorned regexp of the keywords in `c-prefix-spec-kwds' that
-  ;; aren't ambiguous with types or type prefixes.
+  ;; Adorned regexp of the keywords in `c-prefix-spec-kwds' that aren't
+  ;; ambiguous with types or type prefixes.  These are the keywords (like
+  ;; extern, namespace, but NOT template) that can modify a declaration.
   t (c-make-keywords-re t
       (set-difference (c-lang-const c-prefix-spec-kwds)
-                     (c-lang-const c-type-start-kwds)
+                     (append (c-lang-const c-type-start-kwds)
+                             (c-lang-const c-<>-arglist-kwds))
                      :test 'string-equal)))
 (c-lang-defvar c-specifier-key (c-lang-const c-specifier-key))