diff options
| author | bors <bors@rust-lang.org> | 2023-01-17 20:53:05 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-01-17 20:53:05 +0000 |
| commit | edefa4189f16f368c4de3b21615c07abcef0fe1a (patch) | |
| tree | 1c14817ccbc9d78cd1b1a93723b0f60b2f081aaa /compiler/rustc_hir_analysis/src/lib.rs | |
| parent | 3984bc5833db8bfb0acc522c9775383e4171f3de (diff) | |
| parent | 48bd3ab81dc87a4e5850c5c36ac01bb354dc3857 (diff) | |
| download | rust-edefa4189f16f368c4de3b21615c07abcef0fe1a.tar.gz rust-edefa4189f16f368c4de3b21615c07abcef0fe1a.zip | |
Auto merge of #106998 - matthiaskrgr:rollup-hmfisji, r=matthiaskrgr
Rollup of 7 pull requests Successful merges: - #104505 (Remove double spaces after dots in comments) - #106784 (prevent E0512 from emitting [type error] by checking the references_error) - #106834 (new trait solver: only consider goal changed if response is not identity) - #106889 (Mention the lack of `windows_mut` in `windows`) - #106963 (Use `scope_expr_id` from `ProbeCtxt`) - #106970 (Switch to `EarlyBinder` for `item_bounds` query) - #106980 (Hide `_use_mk_alias_ty_instead` in `<AliasTy as Debug>::fmt`) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_hir_analysis/src/lib.rs')
| -rw-r--r-- | compiler/rustc_hir_analysis/src/lib.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_hir_analysis/src/lib.rs b/compiler/rustc_hir_analysis/src/lib.rs index ddc5b766881..9f8da463650 100644 --- a/compiler/rustc_hir_analysis/src/lib.rs +++ b/compiler/rustc_hir_analysis/src/lib.rs @@ -22,7 +22,7 @@ several major phases: 4. Finally, the check phase then checks function bodies and so forth. Within the check phase, we check each function body one at a time (bodies of function expressions are checked as part of the - containing function). Inference is used to supply types wherever + containing function). Inference is used to supply types wherever they are unknown. The actual checking of a function itself has several phases (check, regionck, writeback), as discussed in the documentation for the [`check`] module. @@ -46,7 +46,7 @@ independently: local variables, type parameters, etc as necessary. - infer: finds the types to use for each type variable such that - all subtyping and assignment constraints are met. In essence, the check + all subtyping and assignment constraints are met. In essence, the check module specifies the constraints, and the infer module solves them. ## Note @@ -542,7 +542,7 @@ pub fn check_crate(tcx: TyCtxt<'_>) -> Result<(), ErrorGuaranteed> { pub fn hir_ty_to_ty<'tcx>(tcx: TyCtxt<'tcx>, hir_ty: &hir::Ty<'_>) -> Ty<'tcx> { // In case there are any projections, etc., find the "environment" // def-ID that will be used to determine the traits/predicates in - // scope. This is derived from the enclosing item-like thing. + // scope. This is derived from the enclosing item-like thing. let env_def_id = tcx.hir().get_parent_item(hir_ty.hir_id); let item_cx = self::collect::ItemCtxt::new(tcx, env_def_id.to_def_id()); item_cx.astconv().ast_ty_to_ty(hir_ty) @@ -555,7 +555,7 @@ pub fn hir_trait_to_predicates<'tcx>( ) -> Bounds<'tcx> { // In case there are any projections, etc., find the "environment" // def-ID that will be used to determine the traits/predicates in - // scope. This is derived from the enclosing item-like thing. + // scope. This is derived from the enclosing item-like thing. let env_def_id = tcx.hir().get_parent_item(hir_trait.hir_ref_id); let item_cx = self::collect::ItemCtxt::new(tcx, env_def_id.to_def_id()); let mut bounds = Bounds::default(); |
