Check representation of unnamed fields
This commit is contained in:
parent
7d012e8f19
commit
7660d6bf2c
12 changed files with 309 additions and 30 deletions
|
@ -2216,11 +2216,9 @@ impl<'tcx> SelectionContext<'_, 'tcx> {
|
|||
// if all of its fields are `Copy` and `Clone`
|
||||
ty::Adt(adt, args) if adt.is_anonymous() => {
|
||||
// (*) binder moved here
|
||||
Where(
|
||||
obligation
|
||||
.predicate
|
||||
.rebind(adt.non_enum_variant().fields.iter().map(|f| f.ty(self.tcx(), args)).collect()),
|
||||
)
|
||||
Where(obligation.predicate.rebind(
|
||||
adt.non_enum_variant().fields.iter().map(|f| f.ty(self.tcx(), args)).collect(),
|
||||
))
|
||||
}
|
||||
|
||||
ty::Adt(..) | ty::Alias(..) | ty::Param(..) | ty::Placeholder(..) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue