bors cf81a3b6d0 Auto merge of #3832 - HarrisonMc555:use_last, r=flip1995
Implement "Use last" lint

Closes #3673

This lint checks the use of `x.get(x.len() - 1)` and suggests `x.last()` (where `x` is a `Vec`).

There's at least one more thing that needs to happen here. I believe I am correctly checking most of the scenarios and avoiding false positives. However, if different `Vec`s are used for the `x.get` and `y.len`, then it will emit a false positive. In other words, I need to check to make sure the `Vec`s are the same.

Also, a lot of these commits were temporary and not helpful to the project history...am I supposed to squash on merge? If so, how do I do that?

changelog: New lint: `get_last_with_len`
2019-05-27 11:04:38 +00:00
..
2019-05-12 13:07:58 +02:00
2019-01-21 13:59:49 +01:00
2019-03-07 23:26:47 +09:00
2019-03-10 22:07:10 +01:00
2019-01-27 13:46:22 +01:00
2019-03-10 18:06:28 +00:00
2019-03-10 22:07:10 +01:00
2019-02-18 19:36:58 -07:00
2019-02-18 19:36:58 -07:00
2019-05-12 13:07:58 +02:00
2019-02-21 06:59:10 +02:00
2019-05-16 20:18:07 +02:00
2019-05-16 20:18:07 +02:00
2019-05-16 20:18:07 +02:00
2019-04-30 16:45:28 -03:00
2019-04-30 16:45:28 -03:00
2019-04-30 16:45:28 -03:00
2019-04-30 16:45:28 -03:00
2019-03-09 13:48:06 -08:00
2019-05-08 09:24:24 +02:00
2019-05-08 09:24:24 +02:00
2019-02-17 01:50:31 +01:00
2019-02-17 01:50:31 +01:00
2019-04-02 11:39:43 -03:00
2019-03-07 23:26:47 +09:00
2019-04-16 21:46:07 +02:00
2019-04-25 19:41:23 -07:00
2019-05-14 13:46:10 +02:00
2019-03-19 06:57:41 +01:00
2019-03-19 06:57:41 +01:00
2019-03-19 06:57:41 +01:00
2019-04-01 20:37:05 +02:00
2019-05-12 10:18:38 +02:00
2019-05-12 10:18:38 +02:00
2019-02-24 18:23:54 +01:00
2019-02-24 18:23:54 +01:00
2019-04-02 11:39:43 -03:00
2019-03-10 18:06:28 +00:00
2019-01-29 07:22:08 +02:00
2019-01-29 07:22:08 +02:00
2019-02-19 06:39:22 +02:00
2019-02-20 06:06:00 +02:00
2019-03-10 18:13:15 +00:00
2019-05-08 09:24:24 +02:00
2019-02-18 22:56:43 +00:00
2019-02-18 22:56:43 +00:00