summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/src/docs/duplicate_underscore_argument.txt
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/clippy/src/docs/duplicate_underscore_argument.txt')
-rw-r--r--src/tools/clippy/src/docs/duplicate_underscore_argument.txt16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/tools/clippy/src/docs/duplicate_underscore_argument.txt b/src/tools/clippy/src/docs/duplicate_underscore_argument.txt
new file mode 100644
index 000000000..a8fcd6a9f
--- /dev/null
+++ b/src/tools/clippy/src/docs/duplicate_underscore_argument.txt
@@ -0,0 +1,16 @@
+### What it does
+Checks for function arguments having the similar names
+differing by an underscore.
+
+### Why is this bad?
+It affects code readability.
+
+### Example
+```
+fn foo(a: i32, _a: i32) {}
+```
+
+Use instead:
+```
+fn bar(a: i32, _b: i32) {}
+``` \ No newline at end of file