Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
int
Rust
提交
ece9a57d
R
Rust
项目概览
int
/
Rust
大约 1 年 前同步成功
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
Rust
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
ece9a57d
编写于
11月 21, 2017
作者:
M
Martin Lindhe
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix some typos
上级
ebda7662
变更
24
显示空白变更内容
内联
并排
Showing
24 changed file
with
37 addition
and
37 deletion
+37
-37
CONTRIBUTING.md
CONTRIBUTING.md
+1
-1
RELEASES.md
RELEASES.md
+10
-10
src/bootstrap/job.rs
src/bootstrap/job.rs
+1
-1
src/bootstrap/sanity.rs
src/bootstrap/sanity.rs
+1
-1
src/ci/docker/README.md
src/ci/docker/README.md
+2
-2
src/ci/docker/dist-x86_64-netbsd/build-netbsd-toolchain.sh
src/ci/docker/dist-x86_64-netbsd/build-netbsd-toolchain.sh
+1
-1
src/ci/run.sh
src/ci/run.sh
+1
-1
src/doc/rustdoc/src/command-line-arguments.md
src/doc/rustdoc/src/command-line-arguments.md
+2
-2
src/doc/rustdoc/src/documentation-tests.md
src/doc/rustdoc/src/documentation-tests.md
+1
-1
src/doc/unstable-book/src/language-features/optin-builtin-traits.md
...stable-book/src/language-features/optin-builtin-traits.md
+1
-1
src/doc/unstable-book/src/language-features/unboxed-closures.md
...c/unstable-book/src/language-features/unboxed-closures.md
+1
-1
src/etc/installer/exe/modpath.iss
src/etc/installer/exe/modpath.iss
+1
-1
src/liballoc/fmt.rs
src/liballoc/fmt.rs
+1
-1
src/liballoc/macros.rs
src/liballoc/macros.rs
+1
-1
src/liballoc/rc.rs
src/liballoc/rc.rs
+1
-1
src/liballoc/string.rs
src/liballoc/string.rs
+1
-1
src/liballoc/tests/str.rs
src/liballoc/tests/str.rs
+3
-3
src/liballoc/vec.rs
src/liballoc/vec.rs
+1
-1
src/libbacktrace/configure
src/libbacktrace/configure
+1
-1
src/libbacktrace/ltmain.sh
src/libbacktrace/ltmain.sh
+1
-1
src/libcore/fmt/mod.rs
src/libcore/fmt/mod.rs
+1
-1
src/librustc_data_structures/array_vec.rs
src/librustc_data_structures/array_vec.rs
+1
-1
src/libstd/path.rs
src/libstd/path.rs
+1
-1
src/test/mir-opt/issue-41697.rs
src/test/mir-opt/issue-41697.rs
+1
-1
未找到文件。
CONTRIBUTING.md
浏览文件 @
ece9a57d
...
@@ -421,7 +421,7 @@ Here are those same steps in detail:
...
@@ -421,7 +421,7 @@ Here are those same steps in detail:
These instructions are specific to updating
`rustfmt`
, however they may apply
These instructions are specific to updating
`rustfmt`
, however they may apply
to the other submodules as well. Please help by improving these instructions
to the other submodules as well. Please help by improving these instructions
if you find any discrep
e
ncies or special cases that need to be addressed.
if you find any discrep
a
ncies or special cases that need to be addressed.
To update the
`rustfmt`
submodule, start by running the appropriate
To update the
`rustfmt`
submodule, start by running the appropriate
[
`git submodule` command
](
https://git-scm.com/book/en/v2/Git-Tools-Submodules
)
.
[
`git submodule` command
](
https://git-scm.com/book/en/v2/Git-Tools-Submodules
)
.
...
...
RELEASES.md
浏览文件 @
ece9a57d
...
@@ -624,7 +624,7 @@ Misc
...
@@ -624,7 +624,7 @@ Misc
----
----
-
[
rustdoc can now use pulldown-cmark with the `--enable-commonmark` flag
][
40338
]
-
[
rustdoc can now use pulldown-cmark with the `--enable-commonmark` flag
][
40338
]
-
[
Added rust-winbg script for better debugging on Windows
][
39983
]
-
[
Added rust-win
d
bg script for better debugging on Windows
][
39983
]
-
[
Rust now uses the official cross compiler for NetBSD
][
40612
]
-
[
Rust now uses the official cross compiler for NetBSD
][
40612
]
-
[
rustdoc now accepts `#` at the start of files
][
40828
]
-
[
rustdoc now accepts `#` at the start of files
][
40828
]
-
[
Fixed jemalloc support for musl
][
41168
]
-
[
Fixed jemalloc support for musl
][
41168
]
...
@@ -1658,7 +1658,7 @@ Diagnostics
...
@@ -1658,7 +1658,7 @@ Diagnostics
-----------
-----------
*
[
Replace macro backtraces with labeled local uses
][
35702
]
*
[
Replace macro backtraces with labeled local uses
][
35702
]
*
[
Improve error message for mis
s
placed doc comments
][
33922
]
*
[
Improve error message for misplaced doc comments
][
33922
]
*
[
Buffer unix and lock windows to prevent message interleaving
][
35975
]
*
[
Buffer unix and lock windows to prevent message interleaving
][
35975
]
*
[
Update lifetime errors to specifically note temporaries
][
36171
]
*
[
Update lifetime errors to specifically note temporaries
][
36171
]
*
[
Special case a few colors for Windows
][
36178
]
*
[
Special case a few colors for Windows
][
36178
]
...
@@ -1966,7 +1966,7 @@ Language
...
@@ -1966,7 +1966,7 @@ Language
useful
](
https://github.com/rust-lang/rust/pull/34908
)
useful
](
https://github.com/rust-lang/rust/pull/34908
)
*
[
`macro_rules!` `stmt` matchers correctly consume the entire contents when
*
[
`macro_rules!` `stmt` matchers correctly consume the entire contents when
inside non-braces invocations
](
https://github.com/rust-lang/rust/pull/34886
)
inside non-braces invocations
](
https://github.com/rust-lang/rust/pull/34886
)
*
[
Semicolons are properly required as statement delim
e
ters inside
*
[
Semicolons are properly required as statement delim
i
ters inside
`macro_rules!` invocations
](
https://github.com/rust-lang/rust/pull/34660
)
`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
)
*
[
`cfg_attr` works on `path` attributes
](
https://github.com/rust-lang/rust/pull/34546
)
...
@@ -2191,7 +2191,7 @@ Compatibility Notes
...
@@ -2191,7 +2191,7 @@ Compatibility Notes
*
[
`const`s and `static`s may not have unsized types
](
https://github.com/rust-lang/rust/pull/34443
)
*
[
`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!`
*
[
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
)
in order to ensure syntax forward-compatibility have been enabled
](
https://github.com/rust-lang/rust/pull/33982
)
This was an
[
am
m
endment 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.
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
)
.
*
[
`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.
This causes breakage in some corner cases.
...
@@ -3348,7 +3348,7 @@ Libraries
...
@@ -3348,7 +3348,7 @@ Libraries
*
`FromStr`
is
[
implemented for `SockAddrV4` and `SockAddrV6`
][
1.5s
]
.
*
`FromStr`
is
[
implemented for `SockAddrV4` and `SockAddrV6`
][
1.5s
]
.
*
There are now
`From`
conversions
[
between floating point
*
There are now
`From`
conversions
[
between floating point
types
][
1.5f
]
where the conversions are lossless.
types
][
1.5f
]
where the conversions are lossless.
*
Ther
a
are now
`From`
conversions
[
between integer types
][
1.5i
]
where
*
Ther
e
are now
`From`
conversions
[
between integer types
][
1.5i
]
where
the conversions are lossless.
the conversions are lossless.
*
[
`fs::Metadata` implements `Clone`
][
1.5fs
]
.
*
[
`fs::Metadata` implements `Clone`
][
1.5fs
]
.
*
The
`parse`
method
[
accepts a leading "+" when parsing
*
The
`parse`
method
[
accepts a leading "+" when parsing
...
@@ -3548,7 +3548,7 @@ Libraries
...
@@ -3548,7 +3548,7 @@ Libraries
*
[
`IntoIterator` is implemented for references to `Option` and
*
[
`IntoIterator` is implemented for references to `Option` and
`Result`
][
into2
]
.
`Result`
][
into2
]
.
*
[
`HashMap` and `HashSet` implement `Extend<&T>` where `T:
*
[
`HashMap` and `HashSet` implement `Extend<&T>` where `T:
Copy`
][
ext
]
as part of [RFC 839]. This will cause type infer
a
nce
Copy`
][
ext
]
as part of [RFC 839]. This will cause type infer
e
nce
breakage in rare situations.
breakage in rare situations.
*
[
`BinaryHeap` implements `Debug`
][
bh2
]
.
*
[
`BinaryHeap` implements `Debug`
][
bh2
]
.
*
[
`Borrow` and `BorrowMut` are implemented for fixed-size
*
[
`Borrow` and `BorrowMut` are implemented for fixed-size
...
@@ -3559,7 +3559,7 @@ Libraries
...
@@ -3559,7 +3559,7 @@ Libraries
*
`&mut T`
where
`T: std::fmt::Write`
[
also implements
*
`&mut T`
where
`T: std::fmt::Write`
[
also implements
`std::fmt::Write`
][
mutw
]
.
`std::fmt::Write`
][
mutw
]
.
*
[
A stable regression in `VecDeque::push_back` and other
*
[
A stable regression in `VecDeque::push_back` and other
cap
i
city-altering methods that caused panics for zero-sized types
cap
a
city-altering methods that caused panics for zero-sized types
was fixed
][
vd
]
.
was fixed
][
vd
]
.
*
[
Function pointers implement traits for up to 12 parameters
][
fp2
]
.
*
[
Function pointers implement traits for up to 12 parameters
][
fp2
]
.
...
@@ -3746,7 +3746,7 @@ Libraries
...
@@ -3746,7 +3746,7 @@ Libraries
[
better for long data
][
sh
]
.
[
better for long data
][
sh
]
.
*
[
`AtomicPtr`
] implements [
`Send`
].
*
[
`AtomicPtr`
] implements [
`Send`
].
*
The [
`read_to_end`
] implementations for [
`Stdin`
] and [
`File`
]
*
The [
`read_to_end`
] implementations for [
`Stdin`
] and [
`File`
]
are now
[
specialized to use uninitalized buffers for increased
are now
[
specialized to use uninit
i
alized buffers for increased
performance
][
rte
]
.
performance
][
rte
]
.
*
Lifetime parameters of foreign functions
[
are now resolved
*
Lifetime parameters of foreign functions
[
are now resolved
properly
][
f
]
.
properly
][
f
]
.
...
@@ -3875,7 +3875,7 @@ Highlights
...
@@ -3875,7 +3875,7 @@ Highlights
*
This is the first release with
[
experimental support for linking
*
This is the first release with
[
experimental support for linking
with the MSVC linker and lib C on Windows (instead of using the GNU
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
variants via MinGW)
][
win
]
. It is yet recommended only for the most
intrepid Rust
ici
ans.
intrepid Rust
ace
ans.
*
Benchmark compilations are showing a 30% improvement in
*
Benchmark compilations are showing a 30% improvement in
bootstrapping over 1.1.
bootstrapping over 1.1.
...
@@ -4741,7 +4741,7 @@ Version 0.11.0 (2014-07-02)
...
@@ -4741,7 +4741,7 @@ Version 0.11.0 (2014-07-02)
*
Libraries
*
Libraries
*
The standard library is now a "facade" over a number of underlying
*
The standard library is now a "facade" over a number of underlying
libraries. This means that development on the standard library should
libraries. This means that development on the standard library should
be speeder due to smaller crates, as well as a clearer line between
be speed
i
er due to smaller crates, as well as a clearer line between
all dependencies.
all dependencies.
*
A new library, libcore, lives under the standard library's facade
*
A new library, libcore, lives under the standard library's facade
which is Rust's "0-assumption" library, suitable for embedded and
which is Rust's "0-assumption" library, suitable for embedded and
...
...
src/bootstrap/job.rs
浏览文件 @
ece9a57d
...
@@ -185,7 +185,7 @@ pub unsafe fn setup(build: &mut Build) {
...
@@ -185,7 +185,7 @@ pub unsafe fn setup(build: &mut Build) {
0
,
FALSE
,
DUPLICATE_SAME_ACCESS
);
0
,
FALSE
,
DUPLICATE_SAME_ACCESS
);
// If this failed, well at least we tried! An example of DuplicateHandle
// 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 spaw
n
ed this
// build system (e.g. the `python2` package in MSYS instead of
// build system (e.g. the `python2` package in MSYS instead of
// `mingw-w64-x86_64-python2`. Not sure why it failed, but the "failure
// `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
// mode" here is that we only clean everything up when the build system
...
...
src/bootstrap/sanity.rs
浏览文件 @
ece9a57d
...
@@ -78,7 +78,7 @@ pub fn check(build: &mut Build) {
...
@@ -78,7 +78,7 @@ pub fn check(build: &mut Build) {
}
}
let
mut
cmd_finder
=
Finder
::
new
();
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 gon
n
a need git to update
// submodules and learn about various other aspects.
// submodules and learn about various other aspects.
if
build
.rust_info
.is_git
()
{
if
build
.rust_info
.is_git
()
{
cmd_finder
.must_have
(
"git"
);
cmd_finder
.must_have
(
"git"
);
...
...
src/ci/docker/README.md
浏览文件 @
ece9a57d
...
@@ -36,14 +36,14 @@ a Docker image.
...
@@ -36,14 +36,14 @@ a Docker image.
1. Select the "default" virtual machine inside VirtualBox, then click
1. Select the "default" virtual machine inside VirtualBox, then click
"Settings"
"Settings"
2. Go to "Shared Folders", click "Add shared fold
r
er" (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":
a plus sign), fill in the following information, then click "OK":
* Folder path: `E:\rust`
* Folder path: `E:\rust`
* Folder name: `e/rust`
* Folder name: `e/rust`
* Read-only: ☐ *unchecked*
* Read-only: ☐ *unchecked*
* Auto-mount: ☑ *checked*
* Auto-mount: ☑ *checked*
* Make Perman
a
nt: ☑ *checked*
* Make Perman
e
nt: ☑ *checked*
3.
VirtualBox might not support creating symbolic links inside a shared folder
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`
:
by default. You can enable it manually by running these from
`cmd.exe`
:
...
...
src/ci/docker/dist-x86_64-netbsd/build-netbsd-toolchain.sh
浏览文件 @
ece9a57d
...
@@ -52,7 +52,7 @@ curl $URL/2017-03-17-netbsd-comp.tgz | \
...
@@ -52,7 +52,7 @@ curl $URL/2017-03-17-netbsd-comp.tgz | \
cd
usr/src
cd
usr/src
# The options, in order, do the following
# The options, in order, do the following
# * this is an unprivile
d
ged build
# * this is an unprivileged build
# * output to a predictable location
# * output to a predictable location
# * disable various uneeded stuff
# * disable various uneeded stuff
MKUNPRIVED
=
yes
TOOLDIR
=
/x-tools/x86_64-unknown-netbsd
\
MKUNPRIVED
=
yes
TOOLDIR
=
/x-tools/x86_64-unknown-netbsd
\
...
...
src/ci/run.sh
浏览文件 @
ece9a57d
...
@@ -37,7 +37,7 @@ if [ "$DIST_SRC" = "" ]; then
...
@@ -37,7 +37,7 @@ if [ "$DIST_SRC" = "" ]; then
fi
fi
# If we're deploying artifacts then we set the release channel, otherwise if
# 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 becau
a
se
# we're not deploying then we want to be sure to enable all assertions because
# we'll be running tests
# we'll be running tests
#
#
# FIXME: need a scheme for changing this `nightly` value to `beta` and `stable`
# FIXME: need a scheme for changing this `nightly` value to `beta` and `stable`
...
...
src/doc/rustdoc/src/command-line-arguments.md
浏览文件 @
ece9a57d
...
@@ -279,7 +279,7 @@ $ rustdoc README.md --markdown-playground-url https://play.rust-lang.org/
...
@@ -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
When rendering a Markdown file, this flag gives the base URL of the Rust
Playround, to use for generating
`Run`
buttons.
Play
g
round, to use for generating
`Run`
buttons.
## `--markdown-no-toc`: don't generate a table of contents
## `--markdown-no-toc`: don't generate a table of contents
...
@@ -291,7 +291,7 @@ $ rustdoc README.md --markdown-no-toc
...
@@ -291,7 +291,7 @@ $ rustdoc README.md --markdown-no-toc
```
```
When generating documentation from a Markdown file, by default,
`rustdoc`
will
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 sup
p
resses that, and no TOC will be
generated.
generated.
...
...
src/doc/rustdoc/src/documentation-tests.md
浏览文件 @
ece9a57d
...
@@ -50,7 +50,7 @@ running them. Here's the full algorithm rustdoc uses to preprocess examples:
...
@@ -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
5.
Finally, if the example does not contain
`fn main`
, the remainder of the
text is wrapped in
`fn main() { your_code }`
.
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 "Docume
n
ting Macros" below.
## Hiding portions of the example
## Hiding portions of the example
...
...
src/doc/unstable-book/src/language-features/optin-builtin-traits.md
浏览文件 @
ece9a57d
...
@@ -10,7 +10,7 @@ The `optin_builtin_traits` feature gate allows you to define auto traits.
...
@@ -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
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,
that are automatically implemented for every type, unless the type, or a type it contains,
has explictly opted out via a negative impl.
has explic
i
tly opted out via a negative impl.
[
`Send`
]:
https://doc.rust-lang.org/std/marker/trait.Send.html
[
`Send`
]:
https://doc.rust-lang.org/std/marker/trait.Send.html
[
`Sync`
]:
https://doc.rust-lang.org/std/marker/trait.Sync.html
[
`Sync`
]:
https://doc.rust-lang.org/std/marker/trait.Sync.html
...
...
src/doc/unstable-book/src/language-features/unboxed-closures.md
浏览文件 @
ece9a57d
...
@@ -9,7 +9,7 @@ See Also: [`fn_traits`](library-features/fn-traits.html)
...
@@ -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,
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 impl
e
menting the [
`Fn*`
] family of traits.
`"rust-call"`
functions must have
exactly one (non self) argument, a tuple representing the argument list.
exactly one (non self) argument, a tuple representing the argument list.
[
`Fn*`
]:
https://doc.rust-lang.org/std/ops/trait.Fn.html
[
`Fn*`
]:
https://doc.rust-lang.org/std/ops/trait.Fn.html
...
...
src/etc/installer/exe/modpath.iss
浏览文件 @
ece9a57d
...
@@ -144,7 +144,7 @@ begin
...
@@ -144,7 +144,7 @@ begin
end;
end;
end;
end;
// Split a string into an array using passed delim
e
ter
// Split a string into an array using passed delim
i
ter
procedure Explode(var Dest: TArrayOfString; Text: String; Separator: String);
procedure Explode(var Dest: TArrayOfString; Text: String; Separator: String);
var
var
i: Integer;
i: Integer;
...
...
src/liballoc/fmt.rs
浏览文件 @
ece9a57d
...
@@ -536,7 +536,7 @@
...
@@ -536,7 +536,7 @@
/// assert_eq!(s, "Hello, world!");
/// assert_eq!(s, "Hello, world!");
/// ```
/// ```
///
///
/// Please note that using [`format!`] might be prefer
r
able.
/// Please note that using [`format!`] might be preferable.
/// Example:
/// Example:
///
///
/// ```
/// ```
...
...
src/liballoc/macros.rs
浏览文件 @
ece9a57d
...
@@ -72,7 +72,7 @@
...
@@ -72,7 +72,7 @@
/// Creates a `String` using interpolation of runtime expressions.
/// Creates a `String` using interpolation of runtime expressions.
///
///
/// The first argument `format!` rec
ie
ves is a format string. This must be a string
/// The first argument `format!` rec
ei
ves is a format string. This must be a string
/// literal. The power of the formatting string is in the `{}`s contained.
/// literal. The power of the formatting string is in the `{}`s contained.
///
///
/// Additional parameters passed to `format!` replace the `{}`s within the
/// Additional parameters passed to `format!` replace the `{}`s within the
...
...
src/liballoc/rc.rs
浏览文件 @
ece9a57d
...
@@ -346,7 +346,7 @@ pub fn try_unwrap(this: Self) -> Result<T, Self> {
...
@@ -346,7 +346,7 @@ pub fn try_unwrap(this: Self) -> Result<T, Self> {
unsafe
{
unsafe
{
let
val
=
ptr
::
read
(
&*
this
);
// copy the contained object
let
val
=
ptr
::
read
(
&*
this
);
// copy the contained object
// Indicate to Weaks that they can't be promoted by decreme
m
ting
// Indicate to Weaks that they can't be promoted by decreme
n
ting
// the strong count, and then remove the implicit "strong weak"
// the strong count, and then remove the implicit "strong weak"
// pointer while also handling drop logic by just crafting a
// pointer while also handling drop logic by just crafting a
// fake Weak.
// fake Weak.
...
...
src/liballoc/string.rs
浏览文件 @
ece9a57d
...
@@ -596,7 +596,7 @@ pub fn from_utf8_lossy<'a>(v: &'a [u8]) -> Cow<'a, str> {
...
@@ -596,7 +596,7 @@ pub fn from_utf8_lossy<'a>(v: &'a [u8]) -> Cow<'a, str> {
/// Decode a UTF-16 encoded vector `v` into a `String`, returning [`Err`]
/// Decode a UTF-16 encoded vector `v` into a `String`, returning [`Err`]
/// if `v` contains any invalid data.
/// if `v` contains any invalid data.
///
///
/// [`Err`]: ../../std/result/enum.Result.ht
lm
#variant.Err
/// [`Err`]: ../../std/result/enum.Result.ht
ml
#variant.Err
///
///
/// # Examples
/// # Examples
///
///
...
...
src/liballoc/tests/str.rs
浏览文件 @
ece9a57d
...
@@ -1427,12 +1427,12 @@ fn cmp_search_to_vec<'a, P: Pattern<'a>>(rev: bool, pat: P, haystack: &'a str,
...
@@ -1427,12 +1427,12 @@ fn cmp_search_to_vec<'a, P: Pattern<'a>>(rev: bool, pat: P, haystack: &'a str,
Reject
(
6
,
7
),
Reject
(
6
,
7
),
Match
(
7
,
7
),
Match
(
7
,
7
),
]);
]);
make_test!
(
str_searcher_mulibyte_haystack
,
" "
,
"├──"
,
[
make_test!
(
str_searcher_mul
t
ibyte_haystack
,
" "
,
"├──"
,
[
Reject
(
0
,
3
),
Reject
(
0
,
3
),
Reject
(
3
,
6
),
Reject
(
3
,
6
),
Reject
(
6
,
9
),
Reject
(
6
,
9
),
]);
]);
make_test!
(
str_searcher_empty_needle_mulibyte_haystack
,
""
,
"├──"
,
[
make_test!
(
str_searcher_empty_needle_mul
t
ibyte_haystack
,
""
,
"├──"
,
[
Match
(
0
,
0
),
Match
(
0
,
0
),
Reject
(
0
,
3
),
Reject
(
0
,
3
),
Match
(
3
,
3
),
Match
(
3
,
3
),
...
@@ -1455,7 +1455,7 @@ fn cmp_search_to_vec<'a, P: Pattern<'a>>(rev: bool, pat: P, haystack: &'a str,
...
@@ -1455,7 +1455,7 @@ fn cmp_search_to_vec<'a, P: Pattern<'a>>(rev: bool, pat: P, haystack: &'a str,
Match
(
5
,
6
),
Match
(
5
,
6
),
Reject
(
6
,
7
),
Reject
(
6
,
7
),
]);
]);
make_test!
(
char_searcher_mulibyte_haystack
,
' '
,
"├──"
,
[
make_test!
(
char_searcher_mul
t
ibyte_haystack
,
' '
,
"├──"
,
[
Reject
(
0
,
3
),
Reject
(
0
,
3
),
Reject
(
3
,
6
),
Reject
(
3
,
6
),
Reject
(
6
,
9
),
Reject
(
6
,
9
),
...
...
src/liballoc/vec.rs
浏览文件 @
ece9a57d
...
@@ -1089,7 +1089,7 @@ pub fn drain<R>(&mut self, range: R) -> Drain<T>
...
@@ -1089,7 +1089,7 @@ pub fn drain<R>(&mut self, range: R) -> Drain<T>
// Memory safety
// Memory safety
//
//
// When the Drain is first created, it shortens the length of
// 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 uninit
i
alized or moved-from elements
// are accessible at all if the Drain's destructor never gets to run.
// are accessible at all if the Drain's destructor never gets to run.
//
//
// Drain will ptr::read out the values to remove.
// Drain will ptr::read out the values to remove.
...
...
src/libbacktrace/configure
浏览文件 @
ece9a57d
...
@@ -14584,7 +14584,7 @@ func_basename ()
...
@@ -14584,7 +14584,7 @@ func_basename ()
# to NONDIR_REPLACEMENT.
# to NONDIR_REPLACEMENT.
# value returned in "
$func_dirname_result
"
# value returned in "
$func_dirname_result
"
# basename: Compute filename of FILE.
# basename: Compute filename of FILE.
# value retuned in "
$func_basename_result
"
# value retu
r
ned in "
$func_basename_result
"
# Implementation must be kept synchronized with func_dirname
# Implementation must be kept synchronized with func_dirname
# and func_basename. For efficiency, we do not delegate to
# and func_basename. For efficiency, we do not delegate to
# those functions but instead duplicate the functionality here.
# those functions but instead duplicate the functionality here.
...
...
src/libbacktrace/ltmain.sh
浏览文件 @
ece9a57d
...
@@ -177,7 +177,7 @@ basename="s,^.*/,,"
...
@@ -177,7 +177,7 @@ basename="s,^.*/,,"
# to NONDIR_REPLACEMENT.
# to NONDIR_REPLACEMENT.
# value returned in "$func_dirname_result"
# value returned in "$func_dirname_result"
# basename: Compute filename of FILE.
# basename: Compute filename of FILE.
# value retuned in "$func_basename_result"
# value retu
r
ned in "$func_basename_result"
# Implementation must be kept synchronized with func_dirname
# Implementation must be kept synchronized with func_dirname
# and func_basename. For efficiency, we do not delegate to
# and func_basename. For efficiency, we do not delegate to
# those functions but instead duplicate the functionality here.
# those functions but instead duplicate the functionality here.
...
...
src/libcore/fmt/mod.rs
浏览文件 @
ece9a57d
...
@@ -952,7 +952,7 @@ pub trait UpperExp {
...
@@ -952,7 +952,7 @@ pub trait UpperExp {
/// assert_eq!(output, "Hello world!");
/// assert_eq!(output, "Hello world!");
/// ```
/// ```
///
///
/// Please note that using [`write!`] might be prefer
r
able. Example:
/// Please note that using [`write!`] might be preferable. Example:
///
///
/// ```
/// ```
/// use std::fmt::Write;
/// use std::fmt::Write;
...
...
src/librustc_data_structures/array_vec.rs
浏览文件 @
ece9a57d
...
@@ -111,7 +111,7 @@ pub fn drain<R>(&mut self, range: R) -> Drain<A>
...
@@ -111,7 +111,7 @@ pub fn drain<R>(&mut self, range: R) -> Drain<A>
// Memory safety
// Memory safety
//
//
// When the Drain is first created, it shortens the length of
// 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 uninit
i
alized or moved-from elements
// are accessible at all if the Drain's destructor never gets to run.
// are accessible at all if the Drain's destructor never gets to run.
//
//
// Drain will ptr::read out the values to remove.
// Drain will ptr::read out the values to remove.
...
...
src/libstd/path.rs
浏览文件 @
ece9a57d
...
@@ -3752,7 +3752,7 @@ pub fn test_set_extension() {
...
@@ -3752,7 +3752,7 @@ pub fn test_set_extension() {
}
}
#[test]
#[test]
fn
test_eq_rec
ie
vers
()
{
fn
test_eq_rec
ei
vers
()
{
use
borrow
::
Cow
;
use
borrow
::
Cow
;
let
borrowed
:
&
Path
=
Path
::
new
(
"foo/bar"
);
let
borrowed
:
&
Path
=
Path
::
new
(
"foo/bar"
);
...
...
src/test/mir-opt/issue-41697.rs
浏览文件 @
ece9a57d
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
// artificial cycles: during type-checking, we had to get the MIR for
// artificial cycles: during type-checking, we had to get the MIR for
// the constant expressions in `[u8; 2]`, which in turn would trigger
// the constant expressions in `[u8; 2]`, which in turn would trigger
// an attempt to get the item-path, which in turn would request the
// 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 sup
p
ressed this
// cycle now by forcing mir-dump to avoid asking for types of an impl.
// cycle now by forcing mir-dump to avoid asking for types of an impl.
#![feature(rustc_attrs)]
#![feature(rustc_attrs)]
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录