diff options
| author | Richard M. Stallman | 1995-06-28 21:25:06 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-06-28 21:25:06 +0000 |
| commit | e2b1cb74271b973feaee005696441fdf136e5702 (patch) | |
| tree | e6b4f0f7a3bdf97d86f2455a584e1f7ef2e2157b /lisp/progmodes | |
| parent | ccd318fb5b55bd8c2512259ccf631d5a945e6895 (diff) | |
| download | emacs-e2b1cb74271b973feaee005696441fdf136e5702.tar.gz emacs-e2b1cb74271b973feaee005696441fdf136e5702.zip | |
(electric-c++-terminator): Fix logic for handling colon.
Diffstat (limited to 'lisp/progmodes')
| -rw-r--r-- | lisp/progmodes/cplus-md.el | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lisp/progmodes/cplus-md.el b/lisp/progmodes/cplus-md.el index 647f08ba493..8c93118d91b 100644 --- a/lisp/progmodes/cplus-md.el +++ b/lisp/progmodes/cplus-md.el | |||
| @@ -301,15 +301,15 @@ no args if that value is non-nil." | |||
| 301 | ;; So quickly rule out most other uses of colon | 301 | ;; So quickly rule out most other uses of colon |
| 302 | ;; and do no indentation for them. | 302 | ;; and do no indentation for them. |
| 303 | (and (eq last-command-char ?:) | 303 | (and (eq last-command-char ?:) |
| 304 | (not (looking-at "case[ \t]")) | 304 | (or (not (or (looking-at "case[ \t]") |
| 305 | (save-excursion | 305 | (save-excursion |
| 306 | (forward-word 1) | 306 | (forward-word 1) |
| 307 | (skip-chars-forward " \t") | 307 | (skip-chars-forward " \t") |
| 308 | (< (point) end)) | 308 | (>= (point) end)))) |
| 309 | ;; Do re-indent double colons | 309 | ;; Do re-indent double colons |
| 310 | (save-excursion | 310 | (save-excursion |
| 311 | (end-of-line 1) | 311 | (end-of-line 1) |
| 312 | (looking-at ":"))) | 312 | (looking-at ":")))) |
| 313 | (progn | 313 | (progn |
| 314 | (beginning-of-defun) | 314 | (beginning-of-defun) |
| 315 | (let ((pps (parse-partial-sexp (point) end))) | 315 | (let ((pps (parse-partial-sexp (point) end))) |