diff options
| author | bors <bors@rust-lang.org> | 2023-05-12 04:45:50 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-05-12 04:45:50 +0000 |
| commit | 699a862a3d4e4a2d5603c93297c0c44021ea72f5 (patch) | |
| tree | db4fb9e6c49c6fec354956b6ecf1ec896b83656b /compiler/rustc_middle/src | |
| parent | 26e0c57dde7ea664457e3bf1340f832c722bd349 (diff) | |
| parent | 6641b49cddbde1462d20c0f222444ec5f4ee0400 (diff) | |
| download | rust-699a862a3d4e4a2d5603c93297c0c44021ea72f5.tar.gz rust-699a862a3d4e4a2d5603c93297c0c44021ea72f5.zip | |
Auto merge of #111489 - compiler-errors:rollup-g3vgzss, r=compiler-errors
Rollup of 7 pull requests Successful merges: - #106038 (use implied bounds when checking opaque types) - #111366 (Make `NonUseContext::AscribeUserTy` carry `ty::Variance`) - #111375 (CFI: Fix SIGILL reached via trait objects) - #111439 (Fix backtrace normalization in ice-bug-report-url.rs) - #111444 (Only warn single-use lifetime when the binders match.) - #111459 (Update browser-ui-test version to 0.16.0) - #111460 (Improve suggestion for `self: Box<self>`) Failed merges: - #110454 (Require impl Trait in associated types to appear in method signatures) r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_middle/src')
| -rw-r--r-- | compiler/rustc_middle/src/mir/visit.rs | 8 | ||||
| -rw-r--r-- | compiler/rustc_middle/src/ty/util.rs | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/compiler/rustc_middle/src/mir/visit.rs b/compiler/rustc_middle/src/mir/visit.rs index 6718605ed0b..4b7014e3109 100644 --- a/compiler/rustc_middle/src/mir/visit.rs +++ b/compiler/rustc_middle/src/mir/visit.rs @@ -64,7 +64,7 @@ use crate::mir::*; use crate::ty::subst::SubstsRef; -use crate::ty::{CanonicalUserTypeAnnotation, Ty}; +use crate::ty::{self, CanonicalUserTypeAnnotation, Ty}; use rustc_span::Span; macro_rules! make_mir_visitor { @@ -782,12 +782,12 @@ macro_rules! make_mir_visitor { fn super_ascribe_user_ty(&mut self, place: & $($mutability)? Place<'tcx>, - _variance: $(& $mutability)? ty::Variance, + variance: $(& $mutability)? ty::Variance, user_ty: & $($mutability)? UserTypeProjection, location: Location) { self.visit_place( place, - PlaceContext::NonUse(NonUseContext::AscribeUserTy), + PlaceContext::NonUse(NonUseContext::AscribeUserTy($(* &$mutability *)? variance)), location ); self.visit_user_type_projection(user_ty); @@ -1320,7 +1320,7 @@ pub enum NonUseContext { /// Ending a storage live range. StorageDead, /// User type annotation assertions for NLL. - AscribeUserTy, + AscribeUserTy(ty::Variance), /// The data of a user variable, for debug info. VarDebugInfo, } diff --git a/compiler/rustc_middle/src/ty/util.rs b/compiler/rustc_middle/src/ty/util.rs index e5b2d342452..bcb51db9bcf 100644 --- a/compiler/rustc_middle/src/ty/util.rs +++ b/compiler/rustc_middle/src/ty/util.rs @@ -1253,7 +1253,7 @@ pub enum ExplicitSelf<'tcx> { impl<'tcx> ExplicitSelf<'tcx> { /// Categorizes an explicit self declaration like `self: SomeType` - /// into either `self`, `&self`, `&mut self`, `Box<self>`, or + /// into either `self`, `&self`, `&mut self`, `Box<Self>`, or /// `Other`. /// This is mainly used to require the arbitrary_self_types feature /// in the case of `Other`, to improve error messages in the common cases, |
