diff options
| author | Boxy <rust@boxyuwu.dev> | 2025-01-10 23:20:31 +0000 | 
|---|---|---|
| committer | Boxy <rust@boxyuwu.dev> | 2025-01-23 06:01:36 +0000 | 
| commit | 0f10ba60ffb7306dbc056a42226230eda357895c (patch) | |
| tree | 87a2fe0ec881b793ca3dbf508122444ee131d95c /compiler/rustc_lint/src/traits.rs | |
| parent | 3cd8fcbf87bd28a1f31be000ca906fb66f4d451d (diff) | |
| download | rust-0f10ba60ffb7306dbc056a42226230eda357895c.tar.gz rust-0f10ba60ffb7306dbc056a42226230eda357895c.zip | |
Make `hir::TyKind::TraitObject` use tagged ptr
Diffstat (limited to 'compiler/rustc_lint/src/traits.rs')
| -rw-r--r-- | compiler/rustc_lint/src/traits.rs | 4 | 
1 files changed, 3 insertions, 1 deletions
| diff --git a/compiler/rustc_lint/src/traits.rs b/compiler/rustc_lint/src/traits.rs index a9797c3b32a..ddb4cdb6409 100644 --- a/compiler/rustc_lint/src/traits.rs +++ b/compiler/rustc_lint/src/traits.rs @@ -111,7 +111,9 @@ impl<'tcx> LateLintPass<'tcx> for DropTraitConstraints { } fn check_ty(&mut self, cx: &LateContext<'_>, ty: &'tcx hir::Ty<'tcx>) { - let hir::TyKind::TraitObject(bounds, _lifetime, _syntax) = &ty.kind else { return }; + let hir::TyKind::TraitObject(bounds, _lifetime_and_syntax_pointer) = &ty.kind else { + return; + }; for bound in &bounds[..] { let def_id = bound.trait_ref.trait_def_id(); if def_id.is_some_and(|def_id| cx.tcx.is_lang_item(def_id, LangItem::Drop)) { | 
