bors
272bbfb857
Auto merge of #9386 - smoelius:further-enhance-needless-borrow, r=Jarcho
...
Further enhance `needless_borrow`, mildly refactor `redundant_clone`
This PR does the following:
* Moves some code from `redundant_clone` into a new `clippy_utils` module called `mir`, and wraps that code in a function called `dropped_without_further_use`.
* Relaxes the "is copyable" condition condition from #9136 by also suggesting to remove borrows from values dropped without further use. The changes involve the just mentioned function.
* Separates `redundant_clone` into modules.
Strictly speaking, the last bullet is independent of the others. `redundant_clone` is somewhat hairy, IMO. Separating it into modules makes it slightly less so, by helping to delineate what depends upon what.
I've tried to break everything up into digestible commits.
r? `@Jarcho`
(`@Jarcho` I hope you don't mind.)
changelog: continuation of #9136
2022-10-08 21:24:54 +00:00
..
2022-09-23 13:42:59 -04:00
2022-10-02 23:02:13 +08:00
2022-10-02 17:15:19 -04:00
2022-10-02 14:50:37 -04:00
2022-10-08 15:58:51 +00:00
2022-10-02 17:15:19 -04:00
2022-09-23 13:42:59 -04:00
2022-10-03 20:10:00 -03:00
2022-10-01 17:55:22 +02:00
2022-09-29 12:02:58 +02:00
2022-09-28 14:27:32 +02:00
2022-10-05 17:21:32 +00:00
2022-09-21 13:13:27 -04:00
2022-09-23 13:42:59 -04:00
2022-07-28 19:08:22 +02:00
2022-10-01 22:27:38 +00:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-09-09 13:36:26 +02:00
2022-10-05 18:59:01 +11:00
2022-10-05 13:44:06 +00:00
2022-10-02 17:15:19 -04:00
2022-09-23 13:42:59 -04:00
2022-10-01 17:55:22 +02:00
2022-09-23 13:42:59 -04:00
2022-08-31 09:24:45 -04:00
2022-10-06 16:00:45 +02:00
2022-10-01 17:55:22 +02:00
2022-10-02 17:15:19 -04:00
2022-08-16 11:10:13 +10:00
2022-08-11 19:42:16 +02:00
2022-09-20 15:23:48 +02:00
2022-09-23 13:42:59 -04:00
2022-09-28 14:27:32 +02:00
2022-09-28 14:27:32 +02:00
2022-10-07 05:07:44 -04:00
2022-09-21 13:13:27 -04:00
2022-09-28 14:27:32 +02:00
2022-10-05 13:44:06 +00:00
2022-10-05 13:44:06 +00:00
2022-08-11 19:42:16 +02:00
2022-09-23 13:42:59 -04:00
2022-10-05 13:44:06 +00:00
2022-10-01 15:25:37 +02:00
2022-08-10 18:34:54 +02:00
2022-09-27 19:18:29 +00:00
2022-08-31 09:24:45 -04:00
2022-09-23 13:42:59 -04:00
2022-09-28 14:27:32 +02:00
2022-09-29 12:02:58 +02:00
2022-09-28 14:27:32 +02:00
2022-09-30 11:36:55 -04:00
2022-09-28 14:27:32 +02:00
2022-09-24 23:21:19 +09:00
2022-09-23 13:42:59 -04:00
2022-09-24 23:21:19 +09:00
2022-09-23 13:42:59 -04:00
2022-10-02 21:00:51 -07:00
2022-10-06 09:24:57 -04:00
2022-09-23 13:42:59 -04:00
2022-09-05 22:25:57 +09:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-10-01 17:55:22 +02:00
2022-09-19 11:37:27 +02:00
2022-09-05 22:25:57 +09:00
2022-10-02 14:50:37 -04:00
2022-09-28 14:27:32 +02:00
2022-10-02 17:04:22 -04:00
2022-10-03 16:46:38 +05:30
2022-10-01 17:55:22 +02:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-10-02 15:02:55 -04:00
2022-10-02 15:02:55 -04:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-09-28 14:27:32 +02:00
2022-09-28 14:27:32 +02:00
2022-09-09 13:36:26 +02:00
2022-09-21 13:13:27 -04:00
2022-09-28 14:27:32 +02:00
2022-09-23 13:42:59 -04:00
2022-10-08 15:58:51 +00:00
2022-10-01 13:58:41 -06:00
2022-08-31 09:24:45 -04:00
2022-10-02 15:02:55 -04:00
2022-10-08 15:58:51 +00:00
2022-09-28 14:27:32 +02:00
2022-10-01 15:25:37 +02:00
2022-09-27 13:26:23 +02:00
2022-09-09 13:36:26 +02:00
2022-10-05 13:44:06 +00:00
2022-09-21 13:13:27 -04:00
2022-10-07 05:07:44 -04:00
2022-09-29 12:02:58 +02:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-10-02 15:03:48 +02:00
2022-09-28 14:27:32 +02:00
2022-09-05 22:25:57 +09:00
2022-10-01 22:31:10 +00:00
2022-08-11 19:42:16 +02:00
2022-09-28 14:27:32 +02:00
2022-09-20 15:23:48 +02:00
2022-10-02 15:02:55 -04:00
2022-09-05 22:25:57 +09:00
2022-09-23 13:42:59 -04:00
2022-10-01 22:31:10 +00:00
2022-09-23 13:42:59 -04:00
2022-10-02 14:50:37 -04:00
2022-10-02 15:02:55 -04:00
2022-10-01 17:55:22 +02:00
2022-09-23 13:42:59 -04:00
2022-09-28 14:27:32 +02:00
2022-09-28 14:27:32 +02:00
2022-10-05 13:44:06 +00:00
2022-09-28 14:27:32 +02:00
2022-10-06 09:19:29 +02:00
2022-08-31 09:24:45 -04:00
2022-09-24 23:21:19 +09:00
2022-09-28 14:27:32 +02:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-09-02 13:03:11 -05:00
2022-10-01 22:31:10 +00:00
2022-09-23 13:42:59 -04:00
2022-09-09 13:36:26 +02:00
2022-10-02 17:04:22 -04:00
2022-09-28 14:27:32 +02:00
2022-10-02 14:50:37 -04:00
2022-09-23 13:42:59 -04:00
2022-09-28 14:27:32 +02:00
2022-09-28 14:27:32 +02:00
2022-09-28 14:27:32 +02:00
2022-10-02 15:02:55 -04:00
2022-10-07 05:07:44 -04:00
2022-09-23 13:42:59 -04:00
2022-09-24 23:21:19 +09:00
2022-08-10 18:34:54 +02:00
2022-10-02 14:50:37 -04:00
2022-10-02 17:04:22 -04:00
2022-10-02 14:50:37 -04:00
2022-09-28 14:27:32 +02:00
2022-08-10 18:34:54 +02:00
2022-09-23 13:42:59 -04:00
2022-09-29 12:02:58 +02:00
2022-10-02 14:50:37 -04:00
2022-09-23 13:42:59 -04:00
2022-08-31 09:24:45 -04:00
2022-10-02 17:04:22 -04:00
2022-10-07 05:07:44 -04:00
2022-08-11 19:42:16 +02:00
2022-09-28 14:27:32 +02:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-09-05 14:20:25 +10:00
2022-09-23 13:42:59 -04:00
2022-09-21 13:13:27 -04:00
2022-09-24 23:21:19 +09:00
2022-10-02 17:15:19 -04:00
2022-09-23 13:42:59 -04:00
2022-09-24 23:21:19 +09:00
2022-09-23 13:42:59 -04:00
2022-09-05 22:25:57 +09:00
2022-10-02 15:02:55 -04:00
2022-09-27 18:21:14 +00:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-10-02 17:15:19 -04:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-09-23 13:42:59 -04:00
2022-10-06 09:19:29 +02:00
2022-08-01 08:53:04 +10:00
2022-08-31 09:24:45 -04:00
2022-10-01 17:55:22 +02:00
2022-09-23 13:42:59 -04:00
2022-10-02 15:02:55 -04:00
2022-09-23 13:42:59 -04:00
2022-10-02 14:50:37 -04:00
2022-09-02 13:03:11 -05:00
2022-09-23 13:42:59 -04:00
2022-09-12 13:24:27 +10:00
2022-10-02 15:02:55 -04:00
2022-09-21 13:13:27 -04:00
2022-09-23 13:42:59 -04:00
2022-09-24 23:21:19 +09:00
2022-08-11 11:10:01 +10:00
2022-10-02 17:15:19 -04:00
2022-09-28 14:27:32 +02:00
2022-10-03 10:11:57 +08:00
2022-10-06 09:19:29 +02:00
2022-10-02 15:02:55 -04:00
2022-09-09 13:36:26 +02:00
2022-09-28 14:27:32 +02:00
2022-10-05 16:10:52 +00:00
2022-09-23 13:42:59 -04:00
2022-09-28 14:27:32 +02:00