From 2cb9ae76a13edbeed2240647633bc9bd13136e69 Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Tue, 8 Oct 2013 21:22:57 +0100 Subject: Emacs: remove old-style indentation function --- emacs/init.el | 41 +---------------------------------------- 1 file changed, 1 insertion(+), 40 deletions(-) (limited to 'emacs') diff --git a/emacs/init.el b/emacs/init.el index 0c934fd..b62c308 100644 --- a/emacs/init.el +++ b/emacs/init.el @@ -1067,46 +1067,7 @@ Also returns nil if pid is nil." (awk-mode . "awk") (other . "k&r")) c-basic-offset 4) - (c-set-offset 'case-label '+) - (c-set-offset 'arglist-cont-nonempty #'ap/c-lineup-arglist) - (defun ap/c-lineup-arglist (langelem) - "Line up the current argument line under the first argument. - -As a special case, if the indented line is inside a brace block -construct, the indentation is 0 only. This is intended -as a \"DWIM\" measure in cases like macros that contains statement -blocks, e.g: - -A_VERY_LONG_MACRO_NAME ({ - some (code, with + long, lines * in[it]); -}); -<--> c-basic-offset - -Works with: arglist-cont-nonempty, arglist-close." - (save-excursion - (let ((indent-pos (point))) - - (if (c-block-in-arglist-dwim (c-langelem-2nd-pos c-syntactic-element)) - 0 - - ;; Normal case. Indent to the token after the arglist open paren. - (goto-char (c-langelem-2nd-pos c-syntactic-element)) - (if (and c-special-brace-lists - (c-looking-at-special-brace-list)) - ;; Skip a special brace list opener like "({". - (progn (c-forward-token-2) - (forward-char)) - (forward-char)) - - (let ((arglist-content-start (point))) - (c-forward-syntactic-ws) - (when (< (point) indent-pos) - (goto-char arglist-content-start) - (skip-chars-forward " \t")) - (vector (if (or (looking-at ",") - (looking-at ")")) - (- (current-column) 2) - (current-column)))))))))) + (c-set-offset 'case-label '+))) (use-package quickrun :defer t -- cgit 1.4.1