Skip to content

Commit 7968df1

Browse files
committed
w
1 parent 7e26bf2 commit 7968df1

File tree

1 file changed

+5
-4
lines changed
  • compiler/rustc_middle/src/ty

1 file changed

+5
-4
lines changed

compiler/rustc_middle/src/ty/mod.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1136,7 +1136,7 @@ impl<'tcx, T> ParamEnvAnd<'tcx, T> {
11361136
/// Most of the time you only need to care about the `ParamEnv`
11371137
/// as the `TypingMode` is simply stored in the `InferCtxt`.
11381138
///
1139-
/// However, there are some placeds which rely on trait solving
1139+
/// However, there are some places which rely on trait solving
11401140
/// without using an `InferCtxt` themselves. For these to be
11411141
/// able to use the trait system they have to be able to initialize
11421142
/// such an `InferCtxt` with the right `typing_mode`, so they need
@@ -1149,7 +1149,7 @@ pub struct TypingEnv<'tcx> {
11491149
}
11501150

11511151
impl<'tcx> TypingEnv<'tcx> {
1152-
// FIXME(#132279): THis method should be removed but simplifies the
1152+
// FIXME(#132279): This method should be removed but simplifies the
11531153
// transition.
11541154
pub fn from_param_env(param_env: ParamEnv<'tcx>) -> TypingEnv<'tcx> {
11551155
TypingEnv { typing_mode: TypingMode::from_param_env(param_env), param_env }
@@ -1159,7 +1159,7 @@ impl<'tcx> TypingEnv<'tcx> {
11591159
/// where all opaque types and default associated items are revealed.
11601160
///
11611161
/// This is only suitable for monomorphized, post-typeck environments.
1162-
/// Do not use this during MIR optimizations, as even though they also
1162+
/// Do not use this for MIR optimizations, as even though they also
11631163
/// use `TypingMode::PostAnalysis`, they may still have where-clauses
11641164
/// in scope.
11651165
pub fn fully_monomorphized() -> TypingEnv<'tcx> {
@@ -1214,7 +1214,8 @@ impl<'tcx> TypingEnv<'tcx> {
12141214
/// contain anything local to the `infcx` of the caller, so we don't actually canonicalize
12151215
/// anything.
12161216
///
1217-
/// This should be created by using `infcx.pseudo_canonicalize_query(param_env, value)`.
1217+
/// This should be created by using `infcx.pseudo_canonicalize_query(param_env, value)`
1218+
/// or by using `typing_env.as_query_input(value)`.
12181219
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
12191220
#[derive(HashStable)]
12201221
pub struct PseudoCanonicalInput<'tcx, T> {

0 commit comments

Comments
 (0)