Typing inside proc-macro only changing trivia tokens re-expands proc-macro #17213
Open
Description
#[foo]
fn f() {
// comment
}
Changing the comment content here currently invalidates relative spans in the macro input, invalidating the macro argument subtree as the contained spans change, and as such we re-expand the proc-macro even though logically the macro can't really observe this change unless it actually uses the proc-macro API to introspect spans. We should fix this by having the proc-macro server record whether an expansion did introspection or not and somehow instruct salsa that it shouldnt need to re-expand these queries in those cases.
Activity