Rollup merge of #46157 - martinlindhe:master, r=kennytm

fix some typos

This is the result of me testing out a WIP source code typo-finder
and your project was the random target this time.
This commit is contained in:
kennytm 2017-11-22 01:13:06 +08:00 committed by GitHub
commit 7c8b36f6f1
24 changed files with 37 additions and 37 deletions

View File

@ -421,7 +421,7 @@ Here are those same steps in detail:
These instructions are specific to updating `rustfmt`, however they may apply
to the other submodules as well. Please help by improving these instructions
if you find any discrepencies or special cases that need to be addressed.
if you find any discrepancies or special cases that need to be addressed.
To update the `rustfmt` submodule, start by running the appropriate
[`git submodule` command](https://git-scm.com/book/en/v2/Git-Tools-Submodules).

View File

@ -621,7 +621,7 @@ Misc
----
- [rustdoc can now use pulldown-cmark with the `--enable-commonmark` flag][40338]
- [Added rust-winbg script for better debugging on Windows][39983]
- [Added rust-windbg script for better debugging on Windows][39983]
- [Rust now uses the official cross compiler for NetBSD][40612]
- [rustdoc now accepts `#` at the start of files][40828]
- [Fixed jemalloc support for musl][41168]
@ -1655,7 +1655,7 @@ Diagnostics
-----------
* [Replace macro backtraces with labeled local uses][35702]
* [Improve error message for missplaced doc comments][33922]
* [Improve error message for misplaced doc comments][33922]
* [Buffer unix and lock windows to prevent message interleaving][35975]
* [Update lifetime errors to specifically note temporaries][36171]
* [Special case a few colors for Windows][36178]
@ -1963,7 +1963,7 @@ Language
useful](https://github.com/rust-lang/rust/pull/34908)
* [`macro_rules!` `stmt` matchers correctly consume the entire contents when
inside non-braces invocations](https://github.com/rust-lang/rust/pull/34886)
* [Semicolons are properly required as statement delimeters inside
* [Semicolons are properly required as statement delimiters inside
`macro_rules!` invocations](https://github.com/rust-lang/rust/pull/34660)
* [`cfg_attr` works on `path` attributes](https://github.com/rust-lang/rust/pull/34546)
@ -2188,7 +2188,7 @@ Compatibility Notes
* [`const`s and `static`s may not have unsized types](https://github.com/rust-lang/rust/pull/34443)
* [The new follow-set rules that place restrictions on `macro_rules!`
in order to ensure syntax forward-compatibility have been enabled](https://github.com/rust-lang/rust/pull/33982)
This was an [ammendment to RFC 550](https://github.com/rust-lang/rfcs/pull/1384),
This was an [amendment to RFC 550](https://github.com/rust-lang/rfcs/pull/1384),
and has been a warning since 1.10.
* [`cfg` attribute process has been refactored to fix various bugs](https://github.com/rust-lang/rust/pull/33706).
This causes breakage in some corner cases.
@ -3345,7 +3345,7 @@ Libraries
* `FromStr` is [implemented for `SockAddrV4` and `SockAddrV6`][1.5s].
* There are now `From` conversions [between floating point
types][1.5f] where the conversions are lossless.
* Thera are now `From` conversions [between integer types][1.5i] where
* There are now `From` conversions [between integer types][1.5i] where
the conversions are lossless.
* [`fs::Metadata` implements `Clone`][1.5fs].
* The `parse` method [accepts a leading "+" when parsing
@ -3545,7 +3545,7 @@ Libraries
* [`IntoIterator` is implemented for references to `Option` and
`Result`][into2].
* [`HashMap` and `HashSet` implement `Extend<&T>` where `T:
Copy`][ext] as part of [RFC 839]. This will cause type inferance
Copy`][ext] as part of [RFC 839]. This will cause type inference
breakage in rare situations.
* [`BinaryHeap` implements `Debug`][bh2].
* [`Borrow` and `BorrowMut` are implemented for fixed-size
@ -3556,7 +3556,7 @@ Libraries
* `&mut T` where `T: std::fmt::Write` [also implements
`std::fmt::Write`][mutw].
* [A stable regression in `VecDeque::push_back` and other
capicity-altering methods that caused panics for zero-sized types
capacity-altering methods that caused panics for zero-sized types
was fixed][vd].
* [Function pointers implement traits for up to 12 parameters][fp2].
@ -3743,7 +3743,7 @@ Libraries
[better for long data][sh].
* [`AtomicPtr`] implements [`Send`].
* The [`read_to_end`] implementations for [`Stdin`] and [`File`]
are now [specialized to use uninitalized buffers for increased
are now [specialized to use uninitialized buffers for increased
performance][rte].
* Lifetime parameters of foreign functions [are now resolved
properly][f].
@ -3872,7 +3872,7 @@ Highlights
* This is the first release with [experimental support for linking
with the MSVC linker and lib C on Windows (instead of using the GNU
variants via MinGW)][win]. It is yet recommended only for the most
intrepid Rusticians.
intrepid Rustaceans.
* Benchmark compilations are showing a 30% improvement in
bootstrapping over 1.1.
@ -4738,7 +4738,7 @@ Version 0.11.0 (2014-07-02)
* Libraries
* The standard library is now a "facade" over a number of underlying
libraries. This means that development on the standard library should
be speeder due to smaller crates, as well as a clearer line between
be speedier due to smaller crates, as well as a clearer line between
all dependencies.
* A new library, libcore, lives under the standard library's facade
which is Rust's "0-assumption" library, suitable for embedded and

View File

@ -185,7 +185,7 @@ pub unsafe fn setup(build: &mut Build) {
0, FALSE, DUPLICATE_SAME_ACCESS);
// If this failed, well at least we tried! An example of DuplicateHandle
// failing in the past has been when the wrong python2 package spawed this
// failing in the past has been when the wrong python2 package spawned this
// build system (e.g. the `python2` package in MSYS instead of
// `mingw-w64-x86_64-python2`. Not sure why it failed, but the "failure
// mode" here is that we only clean everything up when the build system

View File

@ -78,7 +78,7 @@ pub fn check(build: &mut Build) {
}
let mut cmd_finder = Finder::new();
// If we've got a git directory we're gona need git to update
// If we've got a git directory we're gonna need git to update
// submodules and learn about various other aspects.
if build.rust_info.is_git() {
cmd_finder.must_have("git");

View File

@ -36,14 +36,14 @@ a Docker image.
1. Select the "default" virtual machine inside VirtualBox, then click
"Settings"
2. Go to "Shared Folders", click "Add shared foldrer" (the folder icon with
2. Go to "Shared Folders", click "Add shared folder" (the folder icon with
a plus sign), fill in the following information, then click "OK":
* Folder path: `E:\rust`
* Folder name: `e/rust`
* Read-only: ☐ *unchecked*
* Auto-mount: ☑ *checked*
* Make Permanant: ☑ *checked*
* Make Permanent: ☑ *checked*
3. VirtualBox might not support creating symbolic links inside a shared folder
by default. You can enable it manually by running these from `cmd.exe`:

View File

@ -52,7 +52,7 @@ curl $URL/2017-03-17-netbsd-comp.tgz | \
cd usr/src
# The options, in order, do the following
# * this is an unpriviledged build
# * this is an unprivileged build
# * output to a predictable location
# * disable various uneeded stuff
MKUNPRIVED=yes TOOLDIR=/x-tools/x86_64-unknown-netbsd \

View File

@ -37,7 +37,7 @@ if [ "$DIST_SRC" = "" ]; then
fi
# If we're deploying artifacts then we set the release channel, otherwise if
# we're not deploying then we want to be sure to enable all assertions becauase
# we're not deploying then we want to be sure to enable all assertions because
# we'll be running tests
#
# FIXME: need a scheme for changing this `nightly` value to `beta` and `stable`

View File

@ -279,7 +279,7 @@ $ rustdoc README.md --markdown-playground-url https://play.rust-lang.org/
```
When rendering a Markdown file, this flag gives the base URL of the Rust
Playround, to use for generating `Run` buttons.
Playground, to use for generating `Run` buttons.
## `--markdown-no-toc`: don't generate a table of contents
@ -291,7 +291,7 @@ $ rustdoc README.md --markdown-no-toc
```
When generating documentation from a Markdown file, by default, `rustdoc` will
generate a table of contents. This flag supresses that, and no TOC will be
generate a table of contents. This flag suppresses that, and no TOC will be
generated.

View File

@ -50,7 +50,7 @@ running them. Here's the full algorithm rustdoc uses to preprocess examples:
5. Finally, if the example does not contain `fn main`, the remainder of the
text is wrapped in `fn main() { your_code }`.
For more about that caveat in rule 4, see "Documeting Macros" below.
For more about that caveat in rule 4, see "Documenting Macros" below.
## Hiding portions of the example

View File

@ -10,7 +10,7 @@ The `optin_builtin_traits` feature gate allows you to define auto traits.
Auto traits, like [`Send`] or [`Sync`] in the standard library, are marker traits
that are automatically implemented for every type, unless the type, or a type it contains,
has explictly opted out via a negative impl.
has explicitly opted out via a negative impl.
[`Send`]: https://doc.rust-lang.org/std/marker/trait.Send.html
[`Sync`]: https://doc.rust-lang.org/std/marker/trait.Sync.html

View File

@ -9,7 +9,7 @@ See Also: [`fn_traits`](library-features/fn-traits.html)
----
The `unboxed_closures` feature allows you to write functions using the `"rust-call"` ABI,
required for implmenting the [`Fn*`] family of traits. `"rust-call"` functions must have
required for implementing the [`Fn*`] family of traits. `"rust-call"` functions must have
exactly one (non self) argument, a tuple representing the argument list.
[`Fn*`]: https://doc.rust-lang.org/std/ops/trait.Fn.html

View File

@ -144,7 +144,7 @@ begin
end;
end;
// Split a string into an array using passed delimeter
// Split a string into an array using passed delimiter
procedure Explode(var Dest: TArrayOfString; Text: String; Separator: String);
var
i: Integer;

View File

@ -536,7 +536,7 @@ use string;
/// assert_eq!(s, "Hello, world!");
/// ```
///
/// Please note that using [`format!`] might be preferrable.
/// Please note that using [`format!`] might be preferable.
/// Example:
///
/// ```

View File

@ -72,7 +72,7 @@ macro_rules! vec {
/// Creates a `String` using interpolation of runtime expressions.
///
/// The first argument `format!` recieves is a format string. This must be a string
/// The first argument `format!` receives is a format string. This must be a string
/// literal. The power of the formatting string is in the `{}`s contained.
///
/// Additional parameters passed to `format!` replace the `{}`s within the

View File

@ -346,7 +346,7 @@ impl<T> Rc<T> {
unsafe {
let val = ptr::read(&*this); // copy the contained object
// Indicate to Weaks that they can't be promoted by decrememting
// Indicate to Weaks that they can't be promoted by decrementing
// the strong count, and then remove the implicit "strong weak"
// pointer while also handling drop logic by just crafting a
// fake Weak.

View File

@ -596,7 +596,7 @@ impl String {
/// Decode a UTF-16 encoded vector `v` into a `String`, returning [`Err`]
/// if `v` contains any invalid data.
///
/// [`Err`]: ../../std/result/enum.Result.htlm#variant.Err
/// [`Err`]: ../../std/result/enum.Result.html#variant.Err
///
/// # Examples
///

View File

@ -1427,12 +1427,12 @@ mod pattern {
Reject(6, 7),
Match (7, 7),
]);
make_test!(str_searcher_mulibyte_haystack, " ", "├──", [
make_test!(str_searcher_multibyte_haystack, " ", "├──", [
Reject(0, 3),
Reject(3, 6),
Reject(6, 9),
]);
make_test!(str_searcher_empty_needle_mulibyte_haystack, "", "├──", [
make_test!(str_searcher_empty_needle_multibyte_haystack, "", "├──", [
Match (0, 0),
Reject(0, 3),
Match (3, 3),
@ -1455,7 +1455,7 @@ mod pattern {
Match (5, 6),
Reject(6, 7),
]);
make_test!(char_searcher_mulibyte_haystack, ' ', "├──", [
make_test!(char_searcher_multibyte_haystack, ' ', "├──", [
Reject(0, 3),
Reject(3, 6),
Reject(6, 9),

View File

@ -1089,7 +1089,7 @@ impl<T> Vec<T> {
// Memory safety
//
// When the Drain is first created, it shortens the length of
// the source vector to make sure no uninitalized or moved-from elements
// the source vector to make sure no uninitialized or moved-from elements
// are accessible at all if the Drain's destructor never gets to run.
//
// Drain will ptr::read out the values to remove.

View File

@ -14584,7 +14584,7 @@ func_basename ()
# to NONDIR_REPLACEMENT.
# value returned in "$func_dirname_result"
# basename: Compute filename of FILE.
# value retuned in "$func_basename_result"
# value returned in "$func_basename_result"
# Implementation must be kept synchronized with func_dirname
# and func_basename. For efficiency, we do not delegate to
# those functions but instead duplicate the functionality here.

View File

@ -177,7 +177,7 @@ basename="s,^.*/,,"
# to NONDIR_REPLACEMENT.
# value returned in "$func_dirname_result"
# basename: Compute filename of FILE.
# value retuned in "$func_basename_result"
# value returned in "$func_basename_result"
# Implementation must be kept synchronized with func_dirname
# and func_basename. For efficiency, we do not delegate to
# those functions but instead duplicate the functionality here.

View File

@ -952,7 +952,7 @@ pub trait UpperExp {
/// assert_eq!(output, "Hello world!");
/// ```
///
/// Please note that using [`write!`] might be preferrable. Example:
/// Please note that using [`write!`] might be preferable. Example:
///
/// ```
/// use std::fmt::Write;

View File

@ -111,7 +111,7 @@ impl<A: Array> ArrayVec<A> {
// Memory safety
//
// When the Drain is first created, it shortens the length of
// the source vector to make sure no uninitalized or moved-from elements
// the source vector to make sure no uninitialized or moved-from elements
// are accessible at all if the Drain's destructor never gets to run.
//
// Drain will ptr::read out the values to remove.

View File

@ -3752,7 +3752,7 @@ mod tests {
}
#[test]
fn test_eq_recievers() {
fn test_eq_receivers() {
use borrow::Cow;
let borrowed: &Path = Path::new("foo/bar");

View File

@ -12,7 +12,7 @@
// artificial cycles: during type-checking, we had to get the MIR for
// the constant expressions in `[u8; 2]`, which in turn would trigger
// an attempt to get the item-path, which in turn would request the
// types of the impl, which would trigger a cycle. We supressed this
// types of the impl, which would trigger a cycle. We suppressed this
// cycle now by forcing mir-dump to avoid asking for types of an impl.
#![feature(rustc_attrs)]