Skip to content

rust-analyzer doesn't pass attributes to derive macros the same way rustc does #10246

@jplatte

Description

@jplatte

I have a proc-macro that uses doc comments. It gets invoked through a macro_rules! macro which seems somewhat relevant, but I can actually reproduce the issue by writing out #[doc = "something"] and bypassing the macro_rules! macro:

#[doc = "some docs"]
#[derive(SomeMacroThatFailsIfThereIsNoDocAttribute)]
pub struct MyStruct;

Works with rustc, fails with rust-analyzer.

Metadata

Metadata

Assignees

Labels

A-macromacro expansionC-bugCategory: bugS-actionableSomeone could pick this issue up and work on it right now

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions