Repository: rust-lang/rust-mode (language: rust)

Issue:
indenting creates tabs instead of spaces
Since PR #324, indenting Rust code in emacs is creating tabs instead of spaces, which is not according to the usual Rust style. If this is intended, at least the documentation should suggest adding `(setq-local indent-tabs-mode nil)` as a hook.


Discussion / hints:
Well, rust-mode should not prevent you from inserting tabs. You can do that if you want with `indent-tabs-mode`, but it is out of scope of a major mode.

> at least the documentation should suggest adding (setq-local indent-tabs-mode nil) as a hook.

would you contribute that?

Fix patch:
diff --git a/README.md b/README.md
index 34a3fc2d..3672a286 100644
--- a/README.md
+++ b/README.md
@@ -7,6 +7,7 @@
 
 - [Installation via MELPA](#installation-via-melpa)
 - [Manual Installation](#manual-installation)
+- [Indentation](#indentation)
 - [rustfmt](#rustfmt)
 - [Tests](#tests)
 - [Other useful packages](#other-useful-packages)
@@ -35,7 +36,7 @@ And put this in your config to load rust-mode automatically:
 
 `(require 'rust-mode)`
 
-# Manual Installation 
+# Manual Installation
 
 Add this to your init.el:
 
@@ -44,10 +45,20 @@ Add this to your init.el:
 (autoload 'rust-mode "rust-mode" nil t)
 ```
 
+# Indentation
+
+The Rust style guide recommends spaces for indentation; to follow the
+recommendation add this to your init.el:
+
+```elisp
+(add-hook 'rust-mode-hook
+          (lambda () (setq indent-tabs-mode nil)))
+```
+
 # rustfmt
 
 The `rust-format-buffer` function will format your code with
-[rustfmt](https://github.com/rust-lang/rustfmt) if installed. By default, 
+[rustfmt](https://github.com/rust-lang/rustfmt) if installed. By default,
 this is bound to `C-c C-f`.
 
 Placing `(setq rust-format-on-save t)` in your init.el will enable automatic
@@ -62,6 +73,6 @@ you set the environment variable EMACS to a program that runs emacs.
 
 # Other useful packages
 
-[cargo.el](https://github.com/kwrooijen/cargo.el) Emacs Minor Mode for Cargo, Rust's Package Manager
-[emacs-racer](https://github.com/racer-rust/emacs-racer) Racer support for Emacs
-[rustic](https://github.com/brotzeit/rustic) Rust development environment for Emacs 
+* [cargo.el](https://github.com/kwrooijen/cargo.el) Emacs Minor Mode for Cargo, Rust's Package Manager
+* [emacs-racer](https://github.com/racer-rust/emacs-racer) Racer support for Emacs
+* [rustic](https://github.com/brotzeit/rustic) Rust development environment for Emacs


Test patch: