HACKING: Use space char for indentation.

* HACKING.tex: Whitespace/indent section is probably out of date. Rephrase.
  Remove the editor recommendations, as I don't know what would be correct.

Acked-by: Vincent Jardin <vincent.jardin@6wind.com>
(cherry picked from commit 4da670b7a9aacf552aa11c4d4f6d994b312ada89)
This commit is contained in:
Paul Jakma 2014-10-27 15:14:06 +00:00 committed by Daniel Walton
parent 21bbd111ab
commit db5a0ac110

View File

@ -21,23 +21,12 @@ are welcome.
GNU coding standards apply. Indentation follows the result of GNU coding standards apply. Indentation follows the result of
invoking GNU indent (as of 2.2.8a) with no arguments. Note that this invoking GNU indent (as of 2.2.8a) with the --nut argument.
uses tabs instead of spaces where possible for leading whitespace, and
assumes that tabs are every 8 columns. Do not attempt to redefine the
location of tab stops. Note also that some indentation does not
follow GNU style. This is a historical accident, and we generally
only clean up whitespace when code is unmaintainable due to whitespace
issues, to minimise merging conflicts.
For GNU emacs, use indentation style ``gnu''. Originally, tabs were used instead of spaces, with tabs are every 8 columns.
However, tab's interoperability issues mean space characters are now preferred for
For Vim, use the following lines (note that tabs are at 8, and that new changes. We generally only clean up whitespace when code is unmaintainable
softtabstop sets the indentation level): due to whitespace issues, to minimise merging conflicts.
set tabstop=8
set softtabstop=2
set shiftwidth=2
set noexpandtab
Be particularly careful not to break platforms/protocols that you Be particularly careful not to break platforms/protocols that you
cannot test. cannot test.