X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=compiler%2Frustc_hir_analysis%2Fsrc%2Fcollect.rs;h=66ca7d7aa08f9cd1d23bfb0ab1afa32d4f684453;hb=5c8bff74bc1c52bef0c79f3689bb227f51f3e82d;hp=cf7fde2a0901a9b84dbe0bfbd397007e8e263aae;hpb=2b50cd18772d3db523070d418dc0411b885a3ff4;p=rust.git diff --git a/compiler/rustc_hir_analysis/src/collect.rs b/compiler/rustc_hir_analysis/src/collect.rs index cf7fde2a090..66ca7d7aa08 100644 --- a/compiler/rustc_hir_analysis/src/collect.rs +++ b/compiler/rustc_hir_analysis/src/collect.rs @@ -100,13 +100,12 @@ pub fn provide(providers: &mut Providers) { /// It's also used for the bodies of items like structs where the body (the fields) /// are just signatures. /// -/// This is in contrast to [`FnCtxt`], which is used to type-check bodies of +/// This is in contrast to `FnCtxt`, which is used to type-check bodies of /// functions, closures, and `const`s -- anywhere that expressions and statements show up. /// /// An important thing to note is that `ItemCtxt` does no inference -- it has no [`InferCtxt`] -- /// while `FnCtxt` does do inference. /// -/// [`FnCtxt`]: crate::check::FnCtxt /// [`InferCtxt`]: rustc_infer::infer::InferCtxt /// /// # Trait predicates @@ -1582,13 +1581,6 @@ fn codegen_fn_attrs(tcx: TyCtxt<'_>, did: DefId) -> CodegenFnAttrs { codegen_fn_attrs.flags |= CodegenFnAttrFlags::TRACK_CALLER; } - // The panic_no_unwind function called by TerminatorKind::Abort will never - // unwind. If the panic handler that it invokes unwind then it will simply - // call the panic handler again. - if Some(did.to_def_id()) == tcx.lang_items().panic_no_unwind() { - codegen_fn_attrs.flags |= CodegenFnAttrFlags::NEVER_UNWIND; - } - let supported_target_features = tcx.supported_target_features(LOCAL_CRATE); let mut inline_span = None;