]> git.lizzy.rs Git - rust.git/commit
Suggest removing inline attributes
authorRyan Cumming <etaoins@gmail.com>
Wed, 17 Jan 2018 19:08:03 +0000 (06:08 +1100)
committerRyan Cumming <etaoins@gmail.com>
Thu, 18 Jan 2018 09:02:42 +0000 (20:02 +1100)
commit7467b83377e47a5f99b68737e5855ec4db1501e2
tree882fd68477b4bcc6f3d1409186a10f04c7f3efd9
parent5f3c340bfbc61dd676bab8b383a6ad080ef554b8
Suggest removing inline attributes

This adds a `suggest_remove_item` helper that will remove an item and
all trailing whitespace. This should handle both attributes on the same
line as the function and on a separate line; the function takes the
position of the original attribute.
clippy_lints/src/inline_fn_without_body.rs
clippy_lints/src/utils/sugg.rs
tests/ui/inline_fn_without_body.rs
tests/ui/inline_fn_without_body.stderr