diff options
| author | Alan Mackenzie | 2009-09-26 09:18:41 +0000 |
|---|---|---|
| committer | Alan Mackenzie | 2009-09-26 09:18:41 +0000 |
| commit | 0000ee90eb09ea3f4c2f36ac8e453be3f0ec3f0e (patch) | |
| tree | 046f1b3b0a9d183344bc1f93b9e788d6bd92d1f4 | |
| parent | d9a13f68b599e73e0d7fc63510baafae00adeca6 (diff) | |
| download | emacs-0000ee90eb09ea3f4c2f36ac8e453be3f0ec3f0e.tar.gz emacs-0000ee90eb09ea3f4c2f36ac8e453be3f0ec3f0e.zip | |
cc-langs.el (c-nonlabel-token-key): Allow quoted character constants (as
case labels).
cc-engine.el (c-beginning-of-statement-1): Correct buggy bracketing.
| -rw-r--r-- | lisp/progmodes/cc-engine.el | 5 | ||||
| -rw-r--r-- | lisp/progmodes/cc-langs.el | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 24b5a9b33f1..0b631d47d77 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el | |||
| @@ -1067,8 +1067,9 @@ comment at the start of cc-engine.el for more info." | |||
| 1067 | (not (eq ret 'beginning)) | 1067 | (not (eq ret 'beginning)) |
| 1068 | (looking-at c-case-kwds-regexp)) | 1068 | (looking-at c-case-kwds-regexp)) |
| 1069 | (if (< after-case:-pos start) | 1069 | (if (< after-case:-pos start) |
| 1070 | (setq pos after-case:-pos) | 1070 | (setq pos after-case:-pos)) |
| 1071 | (setq ret 'label))) | 1071 | (if (eq ret 'same) |
| 1072 | (setq ret 'label))) | ||
| 1072 | 1073 | ||
| 1073 | ;; Skip over the unary operators that can start the statement. | 1074 | ;; Skip over the unary operators that can start the statement. |
| 1074 | (while (progn | 1075 | (while (progn |
diff --git a/lisp/progmodes/cc-langs.el b/lisp/progmodes/cc-langs.el index 9c19e791c3e..0e0eca228bc 100644 --- a/lisp/progmodes/cc-langs.el +++ b/lisp/progmodes/cc-langs.el | |||
| @@ -2885,7 +2885,7 @@ tested at the beginning of every sexp in a suspected label, | |||
| 2885 | i.e. before \":\". Only used if `c-recognize-colon-labels' is set." | 2885 | i.e. before \":\". Only used if `c-recognize-colon-labels' is set." |
| 2886 | t (concat | 2886 | t (concat |
| 2887 | ;; Don't allow string literals. | 2887 | ;; Don't allow string literals. |
| 2888 | "[\"']\\|" | 2888 | "\"\\|" |
| 2889 | ;; All keywords except `c-label-kwds' and `c-protection-kwds'. | 2889 | ;; All keywords except `c-label-kwds' and `c-protection-kwds'. |
| 2890 | (c-make-keywords-re t | 2890 | (c-make-keywords-re t |
| 2891 | (set-difference (c-lang-const c-keywords) | 2891 | (set-difference (c-lang-const c-keywords) |