Auto merge of #17973 - Veykril:proc-macro-curr-dir, r=Veykril

Expand proc-macros in workspace root, not package root

Should fix https://github.com/rust-lang/rust-analyzer/issues/17748. The approach is generally not perfect though as rust-project.json projects don't benefit from this (still, nothing changes in that regard)
This commit is contained in:
bors 2024-08-27 11:53:04 +00:00
commit 06a40a61b0
7 changed files with 34 additions and 14 deletions

View file

@ -241,6 +241,10 @@ impl TargetKind {
pub fn is_executable(self) -> bool {
matches!(self, TargetKind::Bin | TargetKind::Example)
}
pub fn is_proc_macro(self) -> bool {
matches!(self, TargetKind::Lib { is_proc_macro: true })
}
}
// Deserialize helper for the cargo metadata