Skip to content

Commit 77478e9

Browse files
surechentshepang
authored andcommitted
fix some typos
1 parent b6d4a49 commit 77478e9

6 files changed

+10
-10
lines changed

src/borrow_check/opaque-types-region-inference-restrictions.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ fn good() -> Opaque<'static> {}
102102
**Motivation:** an attempt to implement the uniqueness restriction for RPITs resulted in a
103103
[breakage found by crater]( https://github.com/rust-lang/rust/pull/112842#issuecomment-1610057887).
104104
This can be mitigated by this exception to the rule.
105-
An example of the the code that would otherwise break:
105+
An example of the code that would otherwise break:
106106
```rust
107107
struct Type<'a>(&'a ());
108108
impl<'a> Type<'a> {
@@ -224,7 +224,7 @@ fn test::{closure#0}(_upvar: &'?8 str) -> Opaque<'?6, '?7> {
224224
// But in the parent fn it is known that `'?6: '?8`.
225225
//
226226
// When encountering an opaque definition `Opaque<'?6, '?7> := &'8 str`,
227-
// The member constraints algotithm does not know enough to safely make `?8 = '?6`.
227+
// The member constraints algorithm does not know enough to safely make `?8 = '?6`.
228228
// For this reason, it errors with a sensible message:
229229
// "hidden type captures lifetime that does not appear in bounds".
230230
```
@@ -235,7 +235,7 @@ in closures.
235235

236236
**Output types:**
237237
I believe the most common scenario where this causes issues in real-world code is with
238-
closure/async-block output types. It is worth noting that there is a discrepancy betweeen closures
238+
closure/async-block output types. It is worth noting that there is a discrepancy between closures
239239
and async blocks that further demonstrates this issue and is attributed to the
240240
[hack of `replace_opaque_types_with_inference_vars`][source-replace-opaques],
241241
which is applied to futures only.

src/building/bootstrapping/what-bootstrapping-does.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@ to use it.
358358
Finally, `MAGIC_EXTRA_RUSTFLAGS` bypasses the `cargo` cache to pass flags to rustc without
359359
recompiling all dependencies.
360360

361-
`RUSTDOCFLAGS`, `RUSTDOCFLAGS_BOOTSTRAP`, and `RUSTDOCFLAGS_NOT_BOOTSTRAP` are anologous to
361+
`RUSTDOCFLAGS`, `RUSTDOCFLAGS_BOOTSTRAP`, and `RUSTDOCFLAGS_NOT_BOOTSTRAP` are analogous to
362362
`RUSTFLAGS`, but for rustdoc.
363363

364364
`CARGOFLAGS` will pass arguments to cargo itself (e.g. `--timings`). `CARGOFLAGS_BOOTSTRAP` and

src/building/quickstart.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ rustc +stage1 testfile.rs
4646
After doing a change, you can run the compiler test suite with `./x test`.
4747

4848
`./x test` runs the full test suite, which is slow and rarely what you want.
49-
Usually, `./x test tests/ui` is what you want after a comiler change,
49+
Usually, `./x test tests/ui` is what you want after a compiler change,
5050
testing all [UI tests](../tests/ui.md) that invoke the compiler on a specific test file and check the output.
5151

5252
```sh

src/overview.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ queries are cached on disk so that the compiler can tell which queries' results
284284
changed from the last compilation and only redo those. This is how incremental
285285
compilation works.
286286

287-
In principle, for the query-fied steps, we do each of the above for each item
287+
In principle, for the query-field steps, we do each of the above for each item
288288
individually. For example, we will take the `HIR` for a function and use queries
289289
to ask for the `LLVM-IR` for that HIR. This drives the generation of optimized
290290
`MIR`, which drives the borrow checker, which drives the generation of `MIR`, and
@@ -303,11 +303,11 @@ to remain to ensure that unreachable functions still have their errors emitted.
303303
[passes]: https://github.com/rust-lang/rust/blob/e69c7306e2be08939d95f14229e3f96566fb206c/compiler/rustc_interface/src/passes.rs#L791
304304

305305
Moreover, the compiler wasn't originally built to use a query system; the query
306-
system has been retrofitted into the compiler, so parts of it are not query-fied
306+
system has been retrofitted into the compiler, so parts of it are not query-field
307307
yet. Also, LLVM isn't our code, so that isn't querified either. The plan is to
308308
eventually query-fy all of the steps listed in the previous section,
309309
but as of <!-- date-check --> November 2022, only the steps between `HIR` and
310-
`LLVM-IR` are query-fied. That is, lexing, parsing, name resolution, and macro
310+
`LLVM-IR` are query-field. That is, lexing, parsing, name resolution, and macro
311311
expansion are done all at once for the whole program.
312312

313313
One other thing to mention here is the all-important "typing context",

src/return-position-impl-trait-in-trait.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ conceptually inherits most of its information from the parent function
119119
(e.g. `visibility`), or because it's trivially knowable because it's an
120120
associated type (`opt_def_kind`).
121121

122-
Some other queries are more involved, or cannot be feeded, and we
122+
Some other queries are more involved, or cannot be fed, and we
123123
document the interesting ones of those below:
124124

125125
##### `generics_of` for the trait

src/walkthrough.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ some requested changes. When you finished iterating on the changes, you can mark
195195
Feel free to ask questions or discuss things you don't understand or disagree with. However,
196196
recognize that the PR won't be merged unless someone on the Rust team approves
197197
it. If a reviewer leave a comment like `r=me after fixing ...`, that means they approve the PR and
198-
you can merge it with comment with `@bors r=reviwer-github-id`(e.g. `@bors r=eddyb`) to merge it
198+
you can merge it with comment with `@bors r=reviewer-github-id`(e.g. `@bors r=eddyb`) to merge it
199199
after fixing trivial issues. Note that `r=someone` requires permission and bors could say
200200
something like "🔑 Insufficient privileges..." when commenting `r=someone`. In that case,
201201
you have to ask the reviewer to revisit your PR.

0 commit comments

Comments
 (0)