-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Attribute proc-macro follow up #36
Conversation
I just stumbled on an idea. We could leave a marker to signify that this item was already handled by a derive-where macro. We control the outputted item, so we could just add a comment: |
Actually I couldn't find a way to mark the item. Comments aren't represented in the AST apparently, only doc comments, and I can't figure out how to make a "hidden" doc comment, so it doesn't show up in the documentation by the user. The other idea I had while writing this was to introduce another attribute called So I think the best would be to introduce a hidden doc comment or find some other attribute that can be no-op. If you come up with anything hit me. |
To solve the problem with |
Let's figure out #37 before we decide to merge this. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good AFAICT. If attribute macros on fields were introduced, we could circumvent all of this, probably.
19a06ec
to
ac0906f
Compare
Alright, re-based and adjusted to the latest changes we did in #37. |
Build failed because of some connection issue, would be nice if you re-start it @ModProg. |
Fixes #35.
I added a note in the README, but noticed that actually setting the path can produce some pretty unexpected behavior.
What do you think of adding an error if a
derive_where::derive_where
is found as not the first attribute? This isn't bulletproof of course becausederive_where_export::derive_where
could still remain undetected.