-
-
Notifications
You must be signed in to change notification settings - Fork 90
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
Added public API sealed in trait_newly_sealed #1160
Conversation
{ | ||
"name": String("WIllGainDocHiddenMethodWithoutDefault"), | ||
"path": List([ | ||
String("trait_method_added"), | ||
String("WIllGainDocHiddenMethodWithoutDefault"), | ||
]), | ||
"span_begin_line": Uint64(24), | ||
"span_end_line": Uint64(27), | ||
"span_filename": String("src/lib.rs"), | ||
"visibility_limit": String("public"), | ||
}, |
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.
Adding a hidden method also makes the trait sealed
{ | ||
"name": String("WillGainADocHiddenType"), | ||
"path": List([ | ||
String("trait_associated_type_added"), | ||
String("WillGainADocHiddenType"), | ||
]), | ||
"span_begin_line": Uint64(51), | ||
"span_end_line": Uint64(56), | ||
"span_filename": String("src/lib.rs"), | ||
"visibility_limit": String("public"), | ||
}, |
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.
same reason as above
{ | ||
"name": String("WillGainADocHiddenConst"), | ||
"path": List([ | ||
String("trait_associated_const_added"), | ||
String("WillGainADocHiddenConst"), | ||
]), | ||
"span_begin_line": Uint64(46), | ||
"span_end_line": Uint64(51), | ||
"span_filename": String("src/lib.rs"), | ||
"visibility_limit": String("public"), | ||
}, |
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.
The trait WillGainADocHiddenConst
becomes public api sealed due addition of a hidden const. Hence it is newly sealed now and error is raised
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.
In the spirit of mirroring the existing code, I'm adding some explanatory comments to the new test cases to explain what's going on. They make it much easier for me to look back and figure out what we're testing down the line, e.g. if someone reports a bug in our lints.
Resolves #1115