]> git.eshelyaron.com Git - emacs.git/commitdiff
(indent-c-exp): Don't move an { from column 0.
authorRichard M. Stallman <rms@gnu.org>
Sun, 1 Aug 1993 05:17:42 +0000 (05:17 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sun, 1 Aug 1993 05:17:42 +0000 (05:17 +0000)
lisp/progmodes/c-mode.el

index cdbf22463132b5882410897e6ee5342339619732..bd4186aa90a4bc9c8cad5b298e6436f34e8c76c1 100644 (file)
@@ -1137,7 +1137,9 @@ ENDPOS is encountered."
            (if (= (following-char) ?})
                (setq this-indent (- this-indent c-indent-level)))
            (if (= (following-char) ?{)
-               (setq this-indent (+ this-indent c-brace-offset)))
+               (if (zerop (current-column))
+                   (setq this-indent 0)
+                 (setq this-indent (+ this-indent c-brace-offset))))
            ;; Don't leave indentation in empty lines.
            (if (eolp) (setq this-indent 0))
            ;; Put chosen indentation into effect.