;;; cc-align.el --- custom indentation functions for CC Mode
-;; Copyright (C) 1985, 1987, 1992-2013 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1987, 1992-2015 Free Software Foundation, Inc.
;; Authors: 2004- Alan Mackenzie
;; 1998- Martin Stjernholm
(back-to-indentation)
(vector (current-column))))
+(defun c-lineup-respect-col-0 (langelem)
+ "If the current line starts at column 0, return [0]. Otherwise return nil.
+
+This can be used for comments (in conjunction with, say,
+`c-lineup-comment'), to keep comments already at column 0
+anchored there, but reindent other comments."
+ (save-excursion
+ (back-to-indentation)
+ (if (eq (current-column) 0)
+ [0]
+ nil)))
+
\f
(defun c-snug-do-while (syntax pos)
"Dynamically calculate brace hanginess for do-while statements.
\f
(cc-provide 'cc-align)
+;;; Local Variables:
+;;; indent-tabs-mode: t
+;;; tab-width: 8
+;;; End:
;;; cc-align.el ends here