diff options
Diffstat (limited to 'src/docs/match_single_binding.txt')
| -rw-r--r-- | src/docs/match_single_binding.txt | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/docs/match_single_binding.txt b/src/docs/match_single_binding.txt deleted file mode 100644 index 67ded0bbd55..00000000000 --- a/src/docs/match_single_binding.txt +++ /dev/null @@ -1,23 +0,0 @@ -### What it does -Checks for useless match that binds to only one value. - -### Why is this bad? -Readability and needless complexity. - -### Known problems - Suggested replacements may be incorrect when `match` -is actually binding temporary value, bringing a 'dropped while borrowed' error. - -### Example -``` -match (a, b) { - (c, d) => { - // useless match - } -} -``` - -Use instead: -``` -let (c, d) = (a, b); -``` \ No newline at end of file |
