aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Stjernholm2003-09-24 13:55:07 +0000
committerMartin Stjernholm2003-09-24 13:55:07 +0000
commitd858963e6b6f92dc3099eff3752fdcb4efcf1ea1 (patch)
treed67f63077a12fde47daa8a6c1686772be2503b6b
parent1e3187e322fc803d886984eb51e9195f33e152d5 (diff)
downloademacs-d858963e6b6f92dc3099eff3752fdcb4efcf1ea1.tar.gz
emacs-d858963e6b6f92dc3099eff3752fdcb4efcf1ea1.zip
(c-electric-brace): Fixed a bug in the expand-abbrev' workaround
which caused braces to disbehave inside macros.
-rw-r--r--lisp/progmodes/cc-cmds.el6
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/progmodes/cc-cmds.el b/lisp/progmodes/cc-cmds.el
index f786153b383..d0056183d51 100644
--- a/lisp/progmodes/cc-cmds.el
+++ b/lisp/progmodes/cc-cmds.el
@@ -509,7 +509,9 @@ This function does various newline cleanups based on the value of
509 ;; this case. So the marker that we put after "else" would 509 ;; this case. So the marker that we put after "else" would
510 ;; end up before it. 510 ;; end up before it.
511 (setq delete-temp-newline 511 (setq delete-temp-newline
512 (cons (copy-marker (c-point 'eopl) t) 512 (cons (save-excursion
513 (c-backward-syntactic-ws)
514 (copy-marker (point) t))
513 (point-marker)))) 515 (point-marker))))
514 (unwind-protect 516 (unwind-protect
515 (progn 517 (progn
@@ -2671,7 +2673,7 @@ command to conveniently insert and align the necessary backslashes."
2671 2673
2672 ;; There's no nonempty prefix on the line after the 2674 ;; There's no nonempty prefix on the line after the
2673 ;; comment opener. If the line is empty, or if the 2675 ;; comment opener. If the line is empty, or if the
2674 ;; text on has less or equal indentation than the 2676 ;; text on it has less or equal indentation than the
2675 ;; comment starter we assume it's an unclosed 2677 ;; comment starter we assume it's an unclosed
2676 ;; comment starter, i.e. that 2678 ;; comment starter, i.e. that
2677 ;; `c-block-comment-prefix' should be used. 2679 ;; `c-block-comment-prefix' should be used.