Create AttrTarget for attribute parsing#143284
Create AttrTarget for attribute parsing#143284mejrs wants to merge 1 commit intorust-lang:masterfrom
AttrTarget for attribute parsing#143284Conversation
|
|
|
Some changes occurred in compiler/rustc_passes/src/check_attr.rs Some changes occurred in compiler/rustc_attr_data_structures Some changes occurred in compiler/rustc_attr_parsing |
This comment has been minimized.
This comment has been minimized.
|
☔ The latest upstream changes (presumably #143363) made this pull request unmergeable. Please resolve the merge conflicts. |
|
☔ The latest upstream changes (presumably #143645) made this pull request unmergeable. Please resolve the merge conflicts. |
|
I did look at this version, and asked @JonathanBrouwer to come up with a version that'd combine this PR and my version which I pushed to my fork a while ago. I'll compare the two implementations. That version is #145085 |
I see. The primary motivation for my approach where the target enum references the ast of the target is that it lets us move a lot of logic from various passes (not only CheckAttr) into attribute parsing. That's what I'm missing from your and jonathan's versions. |
|
hmm, I quite like reusing the old Target, and the current version is quite declarative which I liked a lot. I'm sorry, but I'm not sure I'd want to do in this direction. |
I went back and forth on the design a bit, this is what I settled on.
r? @jdonszelmann