Update (doc) comments
Several (doc) comments were super outdated or didn't provide enough context. Some doc comments shoved everything in a single paragraph without respecting the fact that the first paragraph should be a single sentence because rustdoc treats these as item descriptions / synopses on module pages.
This commit is contained in:
parent
05d48b936f
commit
82c2c8deb1
36 changed files with 332 additions and 252 deletions
|
@ -1,5 +1,5 @@
|
|||
//! Computes a normalizes-to (projection) goal for inherent associated types,
|
||||
//! `#![feature(inherent_associated_type)]`. Since astconv already determines
|
||||
//! `#![feature(inherent_associated_type)]`. Since HIR ty lowering already determines
|
||||
//! which impl the IAT is being projected from, we just:
|
||||
//! 1. instantiate generic parameters,
|
||||
//! 2. equate the self type, and
|
||||
|
|
|
@ -32,8 +32,9 @@ use std::ops::ControlFlow;
|
|||
|
||||
pub use crate::traits::{MethodViolationCode, ObjectSafetyViolation};
|
||||
|
||||
/// Returns the object safety violations that affect
|
||||
/// astconv -- currently, `Self` in supertraits. This is needed
|
||||
/// Returns the object safety violations that affect HIR ty lowering.
|
||||
///
|
||||
/// Currently that is `Self` in supertraits. This is needed
|
||||
/// because `object_safety_violations` can't be used during
|
||||
/// type collection.
|
||||
pub fn hir_ty_lowering_object_safety_violations(
|
||||
|
|
|
@ -1264,7 +1264,7 @@ impl<'cx, 'tcx> SelectionContext<'cx, 'tcx> {
|
|||
|
||||
// Extract `TailField<T>` and `TailField<U>` from `Struct<T>` and `Struct<U>`,
|
||||
// normalizing in the process, since `type_of` returns something directly from
|
||||
// astconv (which means it's un-normalized).
|
||||
// HIR ty lowering (which means it's un-normalized).
|
||||
let source_tail = normalize_with_depth_to(
|
||||
self,
|
||||
obligation.param_env,
|
||||
|
|
|
@ -396,7 +396,7 @@ pub(crate) fn assoc_def(
|
|||
// associated type. Normally this situation
|
||||
// could only arise through a compiler bug --
|
||||
// if the user wrote a bad item name, it
|
||||
// should have failed in astconv.
|
||||
// should have failed during HIR ty lowering.
|
||||
bug!(
|
||||
"No associated type `{}` for {}",
|
||||
tcx.item_name(assoc_def_id),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue