David Wood
0f4c4c5e18
lint: port array-into-iter diagnostics
...
Signed-off-by: David Wood <david.wood@huawei.com>
2022-06-30 08:59:19 +01:00
Takayuki Maeda
77d6176e69
remove unnecessary to_string
and String::new
2022-06-13 15:48:40 +09:00
David Wood
73fa217bc1
errors: span_suggestion
takes impl ToString
...
Change `span_suggestion` (and variants) to take `impl ToString` rather
than `String` for the suggested code, as this simplifies the
requirements on the diagnostic derive.
Signed-off-by: David Wood <david.wood@huawei.com>
2022-04-29 02:05:20 +01:00
Cameron Steffen
b11733534d
Remove a span from hir::ExprKind::MethodCall
2022-01-21 07:48:10 -06:00
Esteban Kuber
f640438b40
Keep info on pre-desugaring expression for better "incorrect .await
" suggestion
...
Keep the `HirId` of `.await`ed expressions so in the case of a `fn` call
on on a sync `fn`, we can suggest maybe turning it into an `async fn`.
2021-12-13 17:09:16 +00:00
est31
bdc4b46221
Use let_else in some more places in rustc_lint
2021-12-03 03:51:47 +01:00
Cameron Steffen
bd1a1e4f0d
Don't mark for loop head span with desugaring
2021-10-15 08:04:50 -05:00
Hirochika Matsumoto
3818981ca1
Practice diagnostic message convention
2021-10-03 16:16:28 +09:00
Mark Rousskov
3b89679671
Adjust documentation for compatibility with 2021
...
This also adjusts the lint docs generation to accept (and ignore) an allow
attribute, rather than expecting the documentation to be immediately followed by
the lint name.
2021-09-20 22:21:43 -04:00
Mara Bos
90080f4703
Don't give invalid suggestions in array_into_iter.
2021-08-30 23:43:38 +02:00
Mara Bos
422ad3bec2
Upgrade array_into_iter lint to include Deref-to-array types.
2021-08-30 23:43:38 +02:00
Mara Bos
260f9b9e91
Link to edition guide instead of issues for 2021 lints.
2021-08-09 17:45:01 +02:00
Mara Bos
ef152d9b9f
Better suggestion for array_into_iter in for loop.
2021-06-26 12:14:22 +00:00
Mara Bos
5cfe2a5fc6
Add new suggestion to array_into_iter lint.
2021-06-26 12:03:33 +00:00
Mara Bos
37e17803b5
Change wording on array_into_iter lint for 1.53 and edition changes.
2021-06-26 12:03:33 +00:00
Ryan Levick
7b3940f44b
Address PR feedback
2021-06-25 14:51:56 +02:00
Ryan Levick
23176f60e7
Change how edition based future compatibility warnings are handled
2021-06-25 14:51:56 +02:00
Aaron Hill
23018a55d9
Implement rustc side of report-future-incompat
2020-10-30 20:02:14 -04:00
Eric Huss
45c1e0ae07
Auto-generate lint documentation.
2020-09-13 08:48:03 -07:00
LeSeulArtichaut
3e14b684dd
Change ty.kind to a method
2020-09-04 17:47:51 +02:00
mark
9e5f7d5631
mv compiler to compiler/
2020-08-30 18:45:07 +03:00