Skip to content

Commit c464be9

Browse files
authored
Rollup merge of rust-lang#110893 - BoxyUwU:inline_const_nits, r=compiler-errors
remove inline const deadcode in typeck inline consts get typeck'd with their parent so this is not reachable
2 parents 0246af8 + bdb956e commit c464be9

File tree

1 file changed

+0
-6
lines changed
  • compiler/rustc_hir_typeck/src

1 file changed

+0
-6
lines changed

compiler/rustc_hir_typeck/src/lib.rs

-6
Original file line numberDiff line numberDiff line change
@@ -221,12 +221,6 @@ fn typeck_with_fallback<'tcx>(
221221
}))
222222
} else if let Node::AnonConst(_) = node {
223223
match tcx.hir().get(tcx.hir().parent_id(id)) {
224-
Node::Expr(&hir::Expr {
225-
kind: hir::ExprKind::ConstBlock(ref anon_const), ..
226-
}) if anon_const.hir_id == id => Some(fcx.next_ty_var(TypeVariableOrigin {
227-
kind: TypeVariableOriginKind::TypeInference,
228-
span,
229-
})),
230224
Node::Ty(&hir::Ty { kind: hir::TyKind::Typeof(ref anon_const), .. })
231225
if anon_const.hir_id == id =>
232226
{

0 commit comments

Comments
 (0)