diff options
| author | Alan Mackenzie | 2016-07-23 10:43:34 +0000 |
|---|---|---|
| committer | Alan Mackenzie | 2016-07-23 10:43:34 +0000 |
| commit | edcdf64960a2ab4e8d9ce4419874e43b6d3ccee4 (patch) | |
| tree | c4442fafb9a5fd9575594eb19e165a2a22843237 | |
| parent | 03f32876210f3dd68c71baa210e523c3b7581758 (diff) | |
| download | emacs-edcdf64960a2ab4e8d9ce4419874e43b6d3ccee4.tar.gz emacs-edcdf64960a2ab4e8d9ce4419874e43b6d3ccee4.zip | |
Java Mode: Handle strings as case labels correctly.
This fixes debbugs #23901.
* lisp/progmodes/cc-langs.el (c-nonlabel-token-key): Remove "\"" from the
Java value.
| -rw-r--r-- | lisp/progmodes/cc-langs.el | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/progmodes/cc-langs.el b/lisp/progmodes/cc-langs.el index 4d366848998..30949f8aee1 100644 --- a/lisp/progmodes/cc-langs.el +++ b/lisp/progmodes/cc-langs.el | |||
| @@ -3253,8 +3253,8 @@ i.e. before \":\". Only used if `c-recognize-colon-labels' is set." | |||
| 3253 | (append (c-lang-const c-label-kwds) | 3253 | (append (c-lang-const c-label-kwds) |
| 3254 | (c-lang-const c-protection-kwds)) | 3254 | (c-lang-const c-protection-kwds)) |
| 3255 | :test 'string-equal))) | 3255 | :test 'string-equal))) |
| 3256 | ;; Don't allow string literals, except in AWK. Character constants are OK. | 3256 | ;; Don't allow string literals, except in AWK and Java. Character constants are OK. |
| 3257 | (c objc java pike idl) (concat "\"\\|" | 3257 | (c objc pike idl) (concat "\"\\|" |
| 3258 | (c-lang-const c-nonlabel-token-key)) | 3258 | (c-lang-const c-nonlabel-token-key)) |
| 3259 | ;; Also check for open parens in C++, to catch member init lists in | 3259 | ;; Also check for open parens in C++, to catch member init lists in |
| 3260 | ;; constructors. We normally allow it so that macros with arguments | 3260 | ;; constructors. We normally allow it so that macros with arguments |