-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Mark ErrorGuaranteed
constructor as deprecated so people don't use it
#111261
Mark ErrorGuaranteed
constructor as deprecated so people don't use it
#111261
Conversation
@@ -854,9 +854,13 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> { | |||
let result = self | |||
.resolve_fully_qualified_call(span, item_name, ty.normalized, qself.span, hir_id) | |||
.or_else(|error| { | |||
let guar = self |
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.
I'm pretty sure this is not introducing any ICEs, since we later error on bad privacy in type-dependent resolutions.
I think delaying a bug here would actually make sure we catch any subtle cases where private methods aren't being error'd correctly.
r=me if CI passes lol |
0d2fcb7
to
6077fdd
Compare
@bors r=BoxyUwU |
Rollup of 8 pull requests Successful merges: - rust-lang#109677 (Stabilize raw-dylib, link_ordinal, import_name_type and -Cdlltool) - rust-lang#110780 (rustdoc-search: add slices and arrays to index) - rust-lang#110830 (Add FreeBSD cpuset support to `std::thread::available_concurrency`) - rust-lang#111139 (Fix MXCSR configuration dependent timing) - rust-lang#111239 (Remove unnecessary attribute from a diagnostic) - rust-lang#111246 (forbid escaping bound vars in combine) - rust-lang#111251 (Issue 109502 follow up, remove unnecessary Vec::new() from compile_test()) - rust-lang#111261 (Mark `ErrorGuaranteed` constructor as deprecated so people don't use it) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
You should never ever ever ever ever ever ever ever ever ever ever ever ever ever ever ever ever use this function unless you know what you're doing, so make it harder to accidentally use it!
Alternatives are to change the name to sound scarier, make it
unsafe
(though it's not really a soundness thing), or work on deeper refactors to make it private.r? @BoxyUwU