1
Fork 0

Rollup merge of #129345 - compiler-errors:scratch4, r=jieyouxu

Use shorthand field initialization syntax more aggressively in the compiler

Caught these when cleaning up #129344 and decided to run clippy to find the rest
This commit is contained in:
Matthias Krüger 2024-08-21 18:15:06 +02:00 committed by GitHub
commit 4137f3bc15
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 19 additions and 30 deletions

View file

@ -316,7 +316,7 @@ pub fn transform_instance<'tcx>(
.drop_trait()
.unwrap_or_else(|| bug!("typeid_for_instance: couldn't get drop_trait lang item"));
let predicate = ty::ExistentialPredicate::Trait(ty::ExistentialTraitRef {
def_id: def_id,
def_id,
args: List::empty(),
});
let predicates = tcx.mk_poly_existential_predicates(&[ty::Binder::dummy(predicate)]);