changeset 99350:c6c533f20c51

(c-forward-label): Fix for QT macros.
author Alan Mackenzie <acm@muc.de>
date Mon, 03 Nov 2008 19:03:36 +0000
parents c764fa1cc84a
children 80f18c62d371
files lisp/progmodes/cc-engine.el
diffstat 1 files changed, 6 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/progmodes/cc-engine.el	Mon Nov 03 19:02:48 2008 +0000
+++ b/lisp/progmodes/cc-engine.el	Mon Nov 03 19:03:36 2008 +0000
@@ -5954,7 +5954,8 @@
 	label-end
 	qt-symbol-idx
 	macro-start			; if we're in one.
-	label-type)
+	label-type
+	kwd)
     (cond
      ;; "case" or "default" (Doesn't apply to AWK).
      ((looking-at c-label-kwds-regexp)
@@ -6107,12 +6108,13 @@
 		((looking-at ":\\([^:]\\|\\'\\)") ; A single colon.
 		 (forward-char)
 		 (setq label-type
-		       (if (string= "signals" ; Special QT macro
-				    (buffer-substring-no-properties start label-end))
+		       (if (or (string= "signals" ; Special QT macro
+					(setq kwd (buffer-substring-no-properties start label-end)))
+			       (string= "Q_SIGNALS" kwd))
 			   'qt-1kwd-colon
 			 'goto-target)))
 		((and qt-symbol-idx
-		      (search-forward-regexp "\\=slots\\>" limit t)
+		      (search-forward-regexp "\\=\\(slots\\|Q_SLOTS\\)\\>" limit t)
 		      (progn (c-forward-syntactic-ws limit)
 			     (looking-at ":\\([^:]\\|\\'\\)"))) ; A single colon
 		 (forward-char)