-
Notifications
You must be signed in to change notification settings - Fork 13.6k
take attr style into account in diagnostics #145243
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
base: master
Are you sure you want to change the base?
Conversation
rustbot has assigned @petrochenkov. Use |
@@ -690,7 +691,7 @@ impl<'a, G: EmissionGuarantee> Diagnostic<'a, G> for AttributeParseError { | |||
} | |||
} | |||
|
|||
let suggestions = self.template.suggestions(false, &name); | |||
let suggestions = self.template.suggestions(self.attr_style == AttrStyle::Inner, &name); |
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.
Should this method take an AttrStyle parameter?
65316eb
to
3578447
Compare
fair enough, should be fixed :) |
This comment has been minimized.
This comment has been minimized.
oh this actually got some more improved diagnostics, awesome |
3578447
to
68d388f
Compare
@rustbot review |
when the original attribute was specified as an inner attribute, the suggestion will now match that attribute style