Auto merge of #139234 - compiler-errors:query-tweak, r=oli-obk
Misc query tweaks Remove some redundant work around `cache_on_disk` and `ensure_ok`, since `Result<(), ErrorGuaranteed>` queries don't need to cache or recompute their "value" if they are only used for their result.
This commit is contained in:
commit
3658060890
5 changed files with 8 additions and 11 deletions
|
@ -335,7 +335,7 @@ impl<'mir, 'tcx> Checker<'mir, 'tcx> {
|
|||
self.tcx.dcx().span_bug(span, "tls access is checked in `Rvalue::ThreadLocalRef`");
|
||||
}
|
||||
if let Some(def_id) = def_id.as_local()
|
||||
&& let Err(guar) = self.tcx.at(span).check_well_formed(hir::OwnerId { def_id })
|
||||
&& let Err(guar) = self.tcx.ensure_ok().check_well_formed(hir::OwnerId { def_id })
|
||||
{
|
||||
self.error_emitted = Some(guar);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue