diff options
| author | Michael Goulet <michael@errs.io> | 2023-07-24 08:37:40 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-07-24 08:37:40 -0700 |
| commit | 3ad3bb64d97cb3e6b596f5c29ec87a572037d31a (patch) | |
| tree | bae6a42c663ff22864cb8583dc8b0f01d54b7e98 | |
| parent | f3553691a89ffeb9af770051a4f7e7ac0d771406 (diff) | |
| download | rust-3ad3bb64d97cb3e6b596f5c29ec87a572037d31a.tar.gz rust-3ad3bb64d97cb3e6b596f5c29ec87a572037d31a.zip | |
lcnr's suggestions
Co-authored-by: lcnr <rust@lcnr.de>
| -rw-r--r-- | compiler/rustc_trait_selection/src/solve/alias_relate.rs | 5 | ||||
| -rw-r--r-- | compiler/rustc_trait_selection/src/solve/mod.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_trait_selection/src/solve/weak_types.rs | 2 |
3 files changed, 5 insertions, 4 deletions
diff --git a/compiler/rustc_trait_selection/src/solve/alias_relate.rs b/compiler/rustc_trait_selection/src/solve/alias_relate.rs index c46b4df1125..a751fefc88b 100644 --- a/compiler/rustc_trait_selection/src/solve/alias_relate.rs +++ b/compiler/rustc_trait_selection/src/solve/alias_relate.rs @@ -1,5 +1,6 @@ -//! Implements the `AliasRelate` goal, which is used to unify two aliases in the -//! new solver, which uses "lazy normalization". +//! Implements the `AliasRelate` goal, which is used when unifying aliases. +//! Doing this via a separate goal is called "deferred alias relation" and part +//! of our more general approach to "lazy normalization". //! //! This goal, e.g. `A alias-relate B`, may be satisfied by one of three branches: //! * normalizes-to: If `A` is a projection, we can prove the equivalent diff --git a/compiler/rustc_trait_selection/src/solve/mod.rs b/compiler/rustc_trait_selection/src/solve/mod.rs index cc59dd5df03..63e48c94a86 100644 --- a/compiler/rustc_trait_selection/src/solve/mod.rs +++ b/compiler/rustc_trait_selection/src/solve/mod.rs @@ -3,7 +3,7 @@ //! As a user of rust, you can use `-Ztrait-solver=next` or `next-coherence` //! to enable the new trait solver always, or just within coherence, respectively. //! -//! As a developer of rustc, you probably shouldn't be using the new trait +//! As a developer of rustc, you shouldn't be using the new trait //! solver without asking the trait-system-refactor-initiative, but it can //! be enabled with `InferCtxtBuilder::with_next_trait_solver`. This will //! ensure that trait solving using that inference context will be routed diff --git a/compiler/rustc_trait_selection/src/solve/weak_types.rs b/compiler/rustc_trait_selection/src/solve/weak_types.rs index fea634a2ad2..54de32cf618 100644 --- a/compiler/rustc_trait_selection/src/solve/weak_types.rs +++ b/compiler/rustc_trait_selection/src/solve/weak_types.rs @@ -2,7 +2,7 @@ //! `#![feature(lazy_type_alias)]` and `#![feature(type_alias_impl_trait)]`. //! //! Since a weak alias is not ambiguous, this just computes the `type_of` of -//! the alias and registers any where-clause predicates on the type alias. +//! the alias and registers the where-clauses of the type alias. use rustc_middle::traits::solve::{Certainty, Goal, QueryResult}; use rustc_middle::ty; |
