Tamir Duberstein
d3f9fdc298
scripts: generate_rust_analyzer: add missing macros deps
[ Upstream commit 2e0f91aba507a3cb59f7a12fc3ea2b7d4d6675b7 ]
The macros crate has depended on std and proc_macro since its
introduction in commit 1fbde52bde ("rust: add `macros` crate"). These
dependencies were omitted from commit 8c4555ccc5 ("scripts: add
`generate_rust_analyzer.py`") resulting in missing go-to-definition and
autocomplete, and false-positive warnings emitted from rust-analyzer
such as:
[{
"resource": "/Users/tamird/src/linux/rust/macros/module.rs",
"owner": "_generated_diagnostic_collection_name_#1",
"code": {
"value": "non_snake_case",
"target": {
"$mid": 1,
"path": "/rustc/",
"scheme": "https",
"authority": "doc.rust-lang.org",
"query": "search=non_snake_case"
}
},
"severity": 4,
"message": "Variable `None` should have snake_case name, e.g. `none`",
"source": "rust-analyzer",
"startLineNumber": 123,
"startColumn": 17,
"endLineNumber": 123,
"endColumn": 21
}]
Add the missing dependencies to improve the developer experience.
[ Fiona had a different approach (thanks!) at:
https://lore.kernel.org/rust-for-linux/20241205115438.234221-1-me@kloenk.dev/
But Tamir and Fiona agreed to this one. - Miguel ]
Fixes: 8c4555ccc5 ("scripts: add `generate_rust_analyzer.py`")
Reviewed-by: Fiona Behrens <me@kloenk.dev>
Diagnosed-by: Chayim Refael Friedman <chayimfr@gmail.com>
Link: https://github.com/rust-lang/rust-analyzer/issues/17759#issuecomment-2646328275
Signed-off-by: Tamir Duberstein <tamird@gmail.com>
Tested-by: Andreas Hindborg <a.hindborg@kernel.org>
Link: https://lore.kernel.org/r/20250210-rust-analyzer-macros-core-dep-v3-1-45eb4836f218@gmail.com
[ Removed `return`. Changed tag name. Added Link. Slightly
reworded. - Miguel ]
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-03-22 12:50:48 -07:00
..
2024-06-27 13:49:11 +02:00
2023-06-22 21:21:06 +09:00
2024-03-26 18:19:11 -04:00
2023-07-29 11:05:31 -04:00
2023-12-13 18:45:03 +01:00
2023-09-01 16:38:04 +09:00
2024-04-13 13:07:40 +02:00
2025-02-17 09:40:39 +01:00
2025-02-08 09:52:32 +01:00
2025-02-08 09:52:34 +01:00
2025-01-09 13:32:06 +01:00
2023-10-01 23:06:06 +09:00
2022-09-20 14:12:25 -04:00
2023-02-18 14:34:09 -05:00
2023-07-19 09:32:53 -06:00
2023-01-26 12:41:38 +09:00
2023-04-21 08:58:00 -07:00
2023-08-21 13:46:25 -07:00
2024-04-10 16:35:40 +02:00
2023-04-24 10:18:32 -07:00
2023-03-16 22:46:12 +09:00
2023-05-23 21:43:26 -07:00
2023-01-26 12:43:33 +09:00
2024-12-09 10:32:18 +01:00
2023-12-20 17:01:59 +01:00
2023-03-23 17:18:32 -07:00
2023-02-25 20:11:06 +01:00
2023-02-08 13:33:29 +01:00
2024-01-20 11:51:49 +01:00
2023-02-21 16:53:54 -08:00
2023-08-29 22:38:23 +09:00
2023-01-26 12:43:33 +09:00
2022-08-29 13:58:47 +09:00
2022-11-16 10:42:10 +01:00
2024-08-03 08:54:24 +02:00
2024-08-03 08:54:24 +02:00
2025-03-22 12:50:48 -07:00
2022-09-28 09:02:45 +02:00
2024-01-31 16:18:55 -08:00
2023-06-19 13:19:32 -07:00
2023-06-15 14:04:19 +10:00
2023-09-06 23:50:46 +02:00
2023-01-16 20:15:20 +09:00
2023-07-29 15:57:32 +09:00
2023-01-22 23:43:33 +09:00
2024-08-03 08:53:21 +02:00
2023-08-18 11:14:08 -06:00
2024-07-18 13:21:27 +02:00
2023-03-29 06:52:08 -04:00
2024-07-11 12:49:21 +02:00
2023-07-19 09:32:53 -06:00
2022-11-22 23:40:02 +09:00
2024-05-02 16:32:42 +02:00
2023-07-01 09:24:31 -07:00
2023-06-25 23:12:20 +09:00
2024-03-06 14:48:41 +00:00
2022-11-21 10:18:39 +09:00
2023-02-13 20:18:28 +01:00
2024-07-05 09:34:02 +02:00
2025-02-17 09:40:27 +01:00
2022-08-16 12:25:53 -07:00
2023-07-24 03:15:31 +09:00
2023-04-18 16:29:43 -07:00
2022-10-03 14:03:19 -07:00
2025-02-08 09:52:35 +01:00
2024-05-17 12:02:12 +02:00
2023-09-25 16:01:05 +09:00
2023-07-25 00:59:32 +09:00
2024-07-05 09:33:56 +02:00
2023-05-16 13:57:14 -07:00
2024-06-12 11:12:33 +02:00
2023-11-28 17:19:36 +00:00
2023-11-20 11:58:52 +01:00
2024-02-16 19:10:43 +01:00
2023-01-22 23:43:33 +09:00
2022-09-29 04:40:15 +09:00
2024-02-23 09:24:59 +01:00
2024-06-12 11:12:12 +02:00
2022-12-14 15:42:40 +09:00
2023-04-14 16:08:28 +02:00
2023-06-16 17:17:42 +02:00
2023-05-12 11:47:05 -07:00
2023-04-25 21:10:20 -04:00
2023-04-19 07:46:31 -07:00
2023-07-25 00:59:33 +09:00
2022-09-28 09:02:06 +02:00
2023-08-10 01:18:34 +02:00
2024-08-29 17:33:29 +02:00
2023-07-19 09:32:53 -06:00
2023-07-19 09:32:53 -06:00
2024-12-14 20:00:17 +01:00
2023-12-20 17:01:49 +01:00
2022-12-14 08:36:11 +08:00
2025-01-09 13:32:07 +01:00
2023-07-27 13:07:04 -07:00
2022-10-13 11:14:43 -06:00
2023-07-03 12:46:47 -07:00
2023-04-17 11:23:06 +09:00