Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
int
Rust
提交
06a7dcd3
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,发现更多精彩内容 >>
提交
06a7dcd3
编写于
9月 28, 2016
作者:
O
Oliver Middleton
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
std: Correct stability attributes for some implementations
These are displayed by rustdoc so should be correct.
上级
5045d4e3
变更
21
隐藏空白更改
内联
并排
Showing
21 changed file
with
88 addition
and
47 deletion
+88
-47
src/libcollections/binary_heap.rs
src/libcollections/binary_heap.rs
+3
-3
src/libcollections/btree/map.rs
src/libcollections/btree/map.rs
+35
-0
src/libcollections/btree/set.rs
src/libcollections/btree/set.rs
+5
-0
src/libcollections/enum_set.rs
src/libcollections/enum_set.rs
+0
-3
src/libcollections/str.rs
src/libcollections/str.rs
+1
-1
src/libcollections/vec.rs
src/libcollections/vec.rs
+5
-5
src/libcollections/vec_deque.rs
src/libcollections/vec_deque.rs
+4
-4
src/libcore/array.rs
src/libcore/array.rs
+2
-0
src/libcore/iter/mod.rs
src/libcore/iter/mod.rs
+3
-3
src/libcore/iter/range.rs
src/libcore/iter/range.rs
+4
-2
src/libcore/num/mod.rs
src/libcore/num/mod.rs
+3
-3
src/libcore/num/wrapping.rs
src/libcore/num/wrapping.rs
+4
-4
src/libcore/ptr.rs
src/libcore/ptr.rs
+1
-1
src/librustc_unicode/u_str.rs
src/librustc_unicode/u_str.rs
+3
-0
src/libstd/collections/hash/map.rs
src/libstd/collections/hash/map.rs
+3
-3
src/libstd/net/ip.rs
src/libstd/net/ip.rs
+1
-2
src/libstd/net/parser.rs
src/libstd/net/parser.rs
+1
-1
src/libstd/panic.rs
src/libstd/panic.rs
+2
-2
src/libstd/sync/mpsc/select.rs
src/libstd/sync/mpsc/select.rs
+0
-2
src/libstd/sys/unix/ext/process.rs
src/libstd/sys/unix/ext/process.rs
+3
-3
src/libstd/sys/windows/ext/process.rs
src/libstd/sys/windows/ext/process.rs
+5
-5
未找到文件。
src/libcollections/binary_heap.rs
浏览文件 @
06a7dcd3
...
...
@@ -1029,7 +1029,7 @@ pub struct Drain<'a, T: 'a> {
iter
:
vec
::
Drain
<
'a
,
T
>
,
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
:
'a
>
Iterator
for
Drain
<
'a
,
T
>
{
type
Item
=
T
;
...
...
@@ -1044,7 +1044,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
:
'a
>
DoubleEndedIterator
for
Drain
<
'a
,
T
>
{
#[inline]
fn
next_back
(
&
mut
self
)
->
Option
<
T
>
{
...
...
@@ -1052,7 +1052,7 @@ fn next_back(&mut self) -> Option<T> {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
:
'a
>
ExactSizeIterator
for
Drain
<
'a
,
T
>
{}
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
...
...
src/libcollections/btree/map.rs
浏览文件 @
06a7dcd3
...
...
@@ -136,6 +136,7 @@ pub struct BTreeMap<K, V> {
length
:
usize
,
}
#[stable(feature
=
"btree_drop"
,
since
=
"1.7.0"
)]
impl
<
K
,
V
>
Drop
for
BTreeMap
<
K
,
V
>
{
#[unsafe_destructor_blind_to_params]
fn
drop
(
&
mut
self
)
{
...
...
@@ -146,6 +147,7 @@ fn drop(&mut self) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Clone
,
V
:
Clone
>
Clone
for
BTreeMap
<
K
,
V
>
{
fn
clone
(
&
self
)
->
BTreeMap
<
K
,
V
>
{
fn
clone_subtree
<
K
:
Clone
,
V
:
Clone
>
(
node
:
node
::
NodeRef
<
marker
::
Immut
,
...
...
@@ -1125,6 +1127,7 @@ fn fix_left_border(&mut self) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
IntoIterator
for
&
'a
BTreeMap
<
K
,
V
>
{
type
Item
=
(
&
'a
K
,
&
'a
V
);
type
IntoIter
=
Iter
<
'a
,
K
,
V
>
;
...
...
@@ -1134,6 +1137,7 @@ fn into_iter(self) -> Iter<'a, K, V> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
Iterator
for
Iter
<
'a
,
K
,
V
>
{
type
Item
=
(
&
'a
K
,
&
'a
V
);
...
...
@@ -1154,6 +1158,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
K
,
V
>
FusedIterator
for
Iter
<
'a
,
K
,
V
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
DoubleEndedIterator
for
Iter
<
'a
,
K
,
V
>
{
fn
next_back
(
&
mut
self
)
->
Option
<
(
&
'a
K
,
&
'a
V
)
>
{
if
self
.length
==
0
{
...
...
@@ -1165,12 +1170,14 @@ fn next_back(&mut self) -> Option<(&'a K, &'a V)> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
ExactSizeIterator
for
Iter
<
'a
,
K
,
V
>
{
fn
len
(
&
self
)
->
usize
{
self
.length
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
Clone
for
Iter
<
'a
,
K
,
V
>
{
fn
clone
(
&
self
)
->
Iter
<
'a
,
K
,
V
>
{
Iter
{
...
...
@@ -1180,6 +1187,7 @@ fn clone(&self) -> Iter<'a, K, V> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
IntoIterator
for
&
'a
mut
BTreeMap
<
K
,
V
>
{
type
Item
=
(
&
'a
K
,
&
'a
mut
V
);
type
IntoIter
=
IterMut
<
'a
,
K
,
V
>
;
...
...
@@ -1189,6 +1197,7 @@ fn into_iter(self) -> IterMut<'a, K, V> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
Iterator
for
IterMut
<
'a
,
K
,
V
>
{
type
Item
=
(
&
'a
K
,
&
'a
mut
V
);
...
...
@@ -1206,6 +1215,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
DoubleEndedIterator
for
IterMut
<
'a
,
K
,
V
>
{
fn
next_back
(
&
mut
self
)
->
Option
<
(
&
'a
K
,
&
'a
mut
V
)
>
{
if
self
.length
==
0
{
...
...
@@ -1217,6 +1227,7 @@ fn next_back(&mut self) -> Option<(&'a K, &'a mut V)> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
'a
,
V
:
'a
>
ExactSizeIterator
for
IterMut
<
'a
,
K
,
V
>
{
fn
len
(
&
self
)
->
usize
{
self
.length
...
...
@@ -1226,6 +1237,7 @@ fn len(&self) -> usize {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
K
,
V
>
FusedIterator
for
IterMut
<
'a
,
K
,
V
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
,
V
>
IntoIterator
for
BTreeMap
<
K
,
V
>
{
type
Item
=
(
K
,
V
);
type
IntoIter
=
IntoIter
<
K
,
V
>
;
...
...
@@ -1244,6 +1256,7 @@ fn into_iter(self) -> IntoIter<K, V> {
}
}
#[stable(feature
=
"btree_drop"
,
since
=
"1.7.0"
)]
impl
<
K
,
V
>
Drop
for
IntoIter
<
K
,
V
>
{
fn
drop
(
&
mut
self
)
{
for
_
in
&
mut
*
self
{
...
...
@@ -1260,6 +1273,7 @@ fn drop(&mut self) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
,
V
>
Iterator
for
IntoIter
<
K
,
V
>
{
type
Item
=
(
K
,
V
);
...
...
@@ -1304,6 +1318,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
,
V
>
DoubleEndedIterator
for
IntoIter
<
K
,
V
>
{
fn
next_back
(
&
mut
self
)
->
Option
<
(
K
,
V
)
>
{
if
self
.length
==
0
{
...
...
@@ -1342,6 +1357,7 @@ fn next_back(&mut self) -> Option<(K, V)> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
,
V
>
ExactSizeIterator
for
IntoIter
<
K
,
V
>
{
fn
len
(
&
self
)
->
usize
{
self
.length
...
...
@@ -1351,6 +1367,7 @@ fn len(&self) -> usize {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
K
,
V
>
FusedIterator
for
IntoIter
<
K
,
V
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
Iterator
for
Keys
<
'a
,
K
,
V
>
{
type
Item
=
&
'a
K
;
...
...
@@ -1363,12 +1380,14 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
DoubleEndedIterator
for
Keys
<
'a
,
K
,
V
>
{
fn
next_back
(
&
mut
self
)
->
Option
<&
'a
K
>
{
self
.inner
.next_back
()
.map
(|(
k
,
_
)|
k
)
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
ExactSizeIterator
for
Keys
<
'a
,
K
,
V
>
{
fn
len
(
&
self
)
->
usize
{
self
.inner
.len
()
...
...
@@ -1378,12 +1397,14 @@ fn len(&self) -> usize {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
K
,
V
>
FusedIterator
for
Keys
<
'a
,
K
,
V
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
Clone
for
Keys
<
'a
,
K
,
V
>
{
fn
clone
(
&
self
)
->
Keys
<
'a
,
K
,
V
>
{
Keys
{
inner
:
self
.inner
.clone
()
}
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
Iterator
for
Values
<
'a
,
K
,
V
>
{
type
Item
=
&
'a
V
;
...
...
@@ -1396,12 +1417,14 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
DoubleEndedIterator
for
Values
<
'a
,
K
,
V
>
{
fn
next_back
(
&
mut
self
)
->
Option
<&
'a
V
>
{
self
.inner
.next_back
()
.map
(|(
_
,
v
)|
v
)
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
ExactSizeIterator
for
Values
<
'a
,
K
,
V
>
{
fn
len
(
&
self
)
->
usize
{
self
.inner
.len
()
...
...
@@ -1411,6 +1434,7 @@ fn len(&self) -> usize {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
K
,
V
>
FusedIterator
for
Values
<
'a
,
K
,
V
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
,
V
>
Clone
for
Values
<
'a
,
K
,
V
>
{
fn
clone
(
&
self
)
->
Values
<
'a
,
K
,
V
>
{
Values
{
inner
:
self
.inner
.clone
()
}
...
...
@@ -1635,6 +1659,7 @@ unsafe fn next_back_unchecked(&mut self) -> (&'a K, &'a mut V) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Ord
,
V
>
FromIterator
<
(
K
,
V
)
>
for
BTreeMap
<
K
,
V
>
{
fn
from_iter
<
T
:
IntoIterator
<
Item
=
(
K
,
V
)
>>
(
iter
:
T
)
->
BTreeMap
<
K
,
V
>
{
let
mut
map
=
BTreeMap
::
new
();
...
...
@@ -1643,6 +1668,7 @@ fn from_iter<T: IntoIterator<Item = (K, V)>>(iter: T) -> BTreeMap<K, V> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Ord
,
V
>
Extend
<
(
K
,
V
)
>
for
BTreeMap
<
K
,
V
>
{
#[inline]
fn
extend
<
T
:
IntoIterator
<
Item
=
(
K
,
V
)
>>
(
&
mut
self
,
iter
:
T
)
{
...
...
@@ -1652,12 +1678,14 @@ fn extend<T: IntoIterator<Item = (K, V)>>(&mut self, iter: T) {
}
}
#[stable(feature
=
"extend_ref"
,
since
=
"1.2.0"
)]
impl
<
'a
,
K
:
Ord
+
Copy
,
V
:
Copy
>
Extend
<
(
&
'a
K
,
&
'a
V
)
>
for
BTreeMap
<
K
,
V
>
{
fn
extend
<
I
:
IntoIterator
<
Item
=
(
&
'a
K
,
&
'a
V
)
>>
(
&
mut
self
,
iter
:
I
)
{
self
.extend
(
iter
.into_iter
()
.map
(|(
&
key
,
&
value
)|
(
key
,
value
)));
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Hash
,
V
:
Hash
>
Hash
for
BTreeMap
<
K
,
V
>
{
fn
hash
<
H
:
Hasher
>
(
&
self
,
state
:
&
mut
H
)
{
for
elt
in
self
{
...
...
@@ -1666,6 +1694,7 @@ fn hash<H: Hasher>(&self, state: &mut H) {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Ord
,
V
>
Default
for
BTreeMap
<
K
,
V
>
{
/// Creates an empty `BTreeMap<K, V>`.
fn
default
()
->
BTreeMap
<
K
,
V
>
{
...
...
@@ -1673,14 +1702,17 @@ fn default() -> BTreeMap<K, V> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
PartialEq
,
V
:
PartialEq
>
PartialEq
for
BTreeMap
<
K
,
V
>
{
fn
eq
(
&
self
,
other
:
&
BTreeMap
<
K
,
V
>
)
->
bool
{
self
.len
()
==
other
.len
()
&&
self
.iter
()
.zip
(
other
)
.all
(|(
a
,
b
)|
a
==
b
)
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Eq
,
V
:
Eq
>
Eq
for
BTreeMap
<
K
,
V
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
PartialOrd
,
V
:
PartialOrd
>
PartialOrd
for
BTreeMap
<
K
,
V
>
{
#[inline]
fn
partial_cmp
(
&
self
,
other
:
&
BTreeMap
<
K
,
V
>
)
->
Option
<
Ordering
>
{
...
...
@@ -1688,6 +1720,7 @@ fn partial_cmp(&self, other: &BTreeMap<K, V>) -> Option<Ordering> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Ord
,
V
:
Ord
>
Ord
for
BTreeMap
<
K
,
V
>
{
#[inline]
fn
cmp
(
&
self
,
other
:
&
BTreeMap
<
K
,
V
>
)
->
Ordering
{
...
...
@@ -1695,12 +1728,14 @@ fn cmp(&self, other: &BTreeMap<K, V>) -> Ordering {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
K
:
Debug
,
V
:
Debug
>
Debug
for
BTreeMap
<
K
,
V
>
{
fn
fmt
(
&
self
,
f
:
&
mut
fmt
::
Formatter
)
->
fmt
::
Result
{
f
.debug_map
()
.entries
(
self
.iter
())
.finish
()
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
K
:
Ord
,
Q
:
?
Sized
,
V
>
Index
<&
'a
Q
>
for
BTreeMap
<
K
,
V
>
where
K
:
Borrow
<
Q
>
,
Q
:
Ord
...
...
src/libcollections/btree/set.rs
浏览文件 @
06a7dcd3
...
...
@@ -779,6 +779,7 @@ fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
T
>
Clone
for
Iter
<
'a
,
T
>
{
fn
clone
(
&
self
)
->
Iter
<
'a
,
T
>
{
Iter
{
iter
:
self
.iter
.clone
()
}
...
...
@@ -864,6 +865,7 @@ fn cmp_opt<T: Ord>(x: Option<&T>, y: Option<&T>, short: Ordering, long: Ordering
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
T
>
Clone
for
Difference
<
'a
,
T
>
{
fn
clone
(
&
self
)
->
Difference
<
'a
,
T
>
{
Difference
{
...
...
@@ -901,6 +903,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
T
:
Ord
>
FusedIterator
for
Difference
<
'a
,
T
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
T
>
Clone
for
SymmetricDifference
<
'a
,
T
>
{
fn
clone
(
&
self
)
->
SymmetricDifference
<
'a
,
T
>
{
SymmetricDifference
{
...
...
@@ -934,6 +937,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
T
:
Ord
>
FusedIterator
for
SymmetricDifference
<
'a
,
T
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
T
>
Clone
for
Intersection
<
'a
,
T
>
{
fn
clone
(
&
self
)
->
Intersection
<
'a
,
T
>
{
Intersection
{
...
...
@@ -977,6 +981,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
T
:
Ord
>
FusedIterator
for
Intersection
<
'a
,
T
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
T
>
Clone
for
Union
<
'a
,
T
>
{
fn
clone
(
&
self
)
->
Union
<
'a
,
T
>
{
Union
{
...
...
src/libcollections/enum_set.rs
浏览文件 @
06a7dcd3
...
...
@@ -48,7 +48,6 @@ fn clone(&self) -> EnumSet<E> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
E
:
CLike
+
fmt
::
Debug
>
fmt
::
Debug
for
EnumSet
<
E
>
{
fn
fmt
(
&
self
,
fmt
:
&
mut
fmt
::
Formatter
)
->
fmt
::
Result
{
fmt
.debug_set
()
.entries
(
self
)
.finish
()
...
...
@@ -277,7 +276,6 @@ fn from_iter<I: IntoIterator<Item = E>>(iter: I) -> EnumSet<E> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
'a
,
E
>
IntoIterator
for
&
'a
EnumSet
<
E
>
where
E
:
CLike
{
type
Item
=
E
;
...
...
@@ -296,7 +294,6 @@ fn extend<I: IntoIterator<Item = E>>(&mut self, iter: I) {
}
}
#[stable(feature
=
"extend_ref"
,
since
=
"1.2.0"
)]
impl
<
'a
,
E
:
'a
+
CLike
+
Copy
>
Extend
<&
'a
E
>
for
EnumSet
<
E
>
{
fn
extend
<
I
:
IntoIterator
<
Item
=
&
'a
E
>>
(
&
mut
self
,
iter
:
I
)
{
self
.extend
(
iter
.into_iter
()
.cloned
());
...
...
src/libcollections/str.rs
浏览文件 @
06a7dcd3
...
...
@@ -122,7 +122,7 @@ pub struct EncodeUtf16<'a> {
encoder
:
Utf16Encoder
<
Chars
<
'a
>>
,
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
encode_utf16"
,
since
=
"1.8
.0"
)]
impl
<
'a
>
Iterator
for
EncodeUtf16
<
'a
>
{
type
Item
=
u16
;
...
...
src/libcollections/vec.rs
浏览文件 @
06a7dcd3
...
...
@@ -1755,7 +1755,7 @@ pub struct IntoIter<T> {
end
:
*
const
T
,
}
#[stable(feature
=
"vec_intoiter_debug"
,
since
=
""
)]
#[stable(feature
=
"vec_intoiter_debug"
,
since
=
"
1.13.0
"
)]
impl
<
T
:
fmt
::
Debug
>
fmt
::
Debug
for
IntoIter
<
T
>
{
fn
fmt
(
&
self
,
f
:
&
mut
fmt
::
Formatter
)
->
fmt
::
Result
{
f
.debug_tuple
(
"IntoIter"
)
...
...
@@ -1929,7 +1929,7 @@ unsafe impl<'a, T: Sync> Sync for Drain<'a, T> {}
#[stable(feature
=
"drain"
,
since
=
"1.6.0"
)]
unsafe
impl
<
'a
,
T
:
Send
>
Send
for
Drain
<
'a
,
T
>
{}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
>
Iterator
for
Drain
<
'a
,
T
>
{
type
Item
=
T
;
...
...
@@ -1943,7 +1943,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
>
DoubleEndedIterator
for
Drain
<
'a
,
T
>
{
#[inline]
fn
next_back
(
&
mut
self
)
->
Option
<
T
>
{
...
...
@@ -1951,7 +1951,7 @@ fn next_back(&mut self) -> Option<T> {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
>
Drop
for
Drain
<
'a
,
T
>
{
fn
drop
(
&
mut
self
)
{
// exhaust self first
...
...
@@ -1973,7 +1973,7 @@ fn drop(&mut self) {
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
>
ExactSizeIterator
for
Drain
<
'a
,
T
>
{}
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
...
...
src/libcollections/vec_deque.rs
浏览文件 @
06a7dcd3
...
...
@@ -2002,7 +2002,7 @@ unsafe impl<'a, T: Sync> Sync for Drain<'a, T> {}
#[stable(feature
=
"drain"
,
since
=
"1.6.0"
)]
unsafe
impl
<
'a
,
T
:
Send
>
Send
for
Drain
<
'a
,
T
>
{}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
:
'a
>
Drop
for
Drain
<
'a
,
T
>
{
fn
drop
(
&
mut
self
)
{
for
_
in
self
.by_ref
()
{}
...
...
@@ -2051,7 +2051,7 @@ fn drop(&mut self) {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
:
'a
>
Iterator
for
Drain
<
'a
,
T
>
{
type
Item
=
T
;
...
...
@@ -2066,7 +2066,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
:
'a
>
DoubleEndedIterator
for
Drain
<
'a
,
T
>
{
#[inline]
fn
next_back
(
&
mut
self
)
->
Option
<
T
>
{
...
...
@@ -2074,7 +2074,7 @@ fn next_back(&mut self) -> Option<T> {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
T
:
'a
>
ExactSizeIterator
for
Drain
<
'a
,
T
>
{}
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
...
...
src/libcore/array.rs
浏览文件 @
06a7dcd3
...
...
@@ -93,6 +93,7 @@ fn ne(&self, other: &$Lhs) -> bool { self[..] != other[..] }
macro_rules!
array_impls
{
(
$
(
$N:expr
)
+
)
=>
{
$
(
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
T
>
AsRef
<
[
T
]
>
for
[
T
;
$N
]
{
#[inline]
fn
as_ref
(
&
self
)
->
&
[
T
]
{
...
...
@@ -100,6 +101,7 @@ fn as_ref(&self) -> &[T] {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
impl
<
T
>
AsMut
<
[
T
]
>
for
[
T
;
$N
]
{
#[inline]
fn
as_mut
(
&
mut
self
)
->
&
mut
[
T
]
{
...
...
src/libcore/iter/mod.rs
浏览文件 @
06a7dcd3
...
...
@@ -386,7 +386,7 @@ pub struct Cloned<I> {
it
:
I
,
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
iter_cloned"
,
since
=
"1.1
.0"
)]
impl
<
'a
,
I
,
T
:
'a
>
Iterator
for
Cloned
<
I
>
where
I
:
Iterator
<
Item
=&
'a
T
>
,
T
:
Clone
{
...
...
@@ -401,7 +401,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
iter_cloned"
,
since
=
"1.1
.0"
)]
impl
<
'a
,
I
,
T
:
'a
>
DoubleEndedIterator
for
Cloned
<
I
>
where
I
:
DoubleEndedIterator
<
Item
=&
'a
T
>
,
T
:
Clone
{
...
...
@@ -410,7 +410,7 @@ fn next_back(&mut self) -> Option<T> {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
iter_cloned"
,
since
=
"1.1
.0"
)]
impl
<
'a
,
I
,
T
:
'a
>
ExactSizeIterator
for
Cloned
<
I
>
where
I
:
ExactSizeIterator
<
Item
=&
'a
T
>
,
T
:
Clone
{}
...
...
src/libcore/iter/range.rs
浏览文件 @
06a7dcd3
...
...
@@ -328,7 +328,8 @@ pub fn step_by(self, by: A) -> StepBy<A, Self> {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
#[unstable(feature
=
"step_by"
,
reason
=
"recent addition"
,
issue
=
"27741"
)]
impl
<
A
>
Iterator
for
StepBy
<
A
,
ops
::
RangeFrom
<
A
>>
where
A
:
Clone
,
for
<
'a
>
&
'a
A
:
Add
<&
'a
A
,
Output
=
A
>
...
...
@@ -352,7 +353,8 @@ fn size_hint(&self) -> (usize, Option<usize>) {
impl
<
A
>
FusedIterator
for
StepBy
<
A
,
ops
::
RangeFrom
<
A
>>
where
A
:
Clone
,
for
<
'a
>
&
'a
A
:
Add
<&
'a
A
,
Output
=
A
>
{}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
#[unstable(feature
=
"step_by"
,
reason
=
"recent addition"
,
issue
=
"27741"
)]
impl
<
A
:
Step
+
Clone
>
Iterator
for
StepBy
<
A
,
ops
::
Range
<
A
>>
{
type
Item
=
A
;
...
...
src/libcore/num/mod.rs
浏览文件 @
06a7dcd3
...
...
@@ -2576,7 +2576,7 @@ fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
macro_rules!
same_sign_from_int_impl
{
(
$storage:ty
,
$target:ty
,
$
(
$source:ty
),
*
)
=>
{
$
(
#[
stable(feature
=
"rust1"
,
since
=
"1.0.0
"
)]
#[
unstable(feature
=
"try_from"
,
issue
=
"33417
"
)]
impl
TryFrom
<
$source
>
for
$target
{
type
Err
=
TryFromIntError
;
...
...
@@ -2606,7 +2606,7 @@ fn try_from(u: $source) -> Result<$target, TryFromIntError> {
macro_rules!
cross_sign_from_int_impl
{
(
$unsigned:ty
,
$
(
$signed:ty
),
*
)
=>
{
$
(
#[
stable(feature
=
"rust1"
,
since
=
"1.0.0
"
)]
#[
unstable(feature
=
"try_from"
,
issue
=
"33417
"
)]
impl
TryFrom
<
$unsigned
>
for
$signed
{
type
Err
=
TryFromIntError
;
...
...
@@ -2620,7 +2620,7 @@ fn try_from(u: $unsigned) -> Result<$signed, TryFromIntError> {
}
}
#[
stable(feature
=
"rust1"
,
since
=
"1.0.0
"
)]
#[
unstable(feature
=
"try_from"
,
issue
=
"33417
"
)]
impl
TryFrom
<
$signed
>
for
$unsigned
{
type
Err
=
TryFromIntError
;
...
...
src/libcore/num/wrapping.rs
浏览文件 @
06a7dcd3
...
...
@@ -28,7 +28,7 @@ fn shl(self, other: $f) -> Wrapping<$t> {
}
}
#[stable(feature
=
"
wrapping_impls"
,
since
=
"1.7
.0"
)]
#[stable(feature
=
"
op_assign_traits"
,
since
=
"1.8
.0"
)]
impl
ShlAssign
<
$f
>
for
Wrapping
<
$t
>
{
#[inline(always)]
fn
shl_assign
(
&
mut
self
,
other
:
$f
)
{
...
...
@@ -50,7 +50,7 @@ fn shr(self, other: $f) -> Wrapping<$t> {
}
}
#[stable(feature
=
"
wrapping_impls"
,
since
=
"1.7
.0"
)]
#[stable(feature
=
"
op_assign_traits"
,
since
=
"1.8
.0"
)]
impl
ShrAssign
<
$f
>
for
Wrapping
<
$t
>
{
#[inline(always)]
fn
shr_assign
(
&
mut
self
,
other
:
$f
)
{
...
...
@@ -72,7 +72,7 @@ fn shl(self, other: $f) -> Wrapping<$t> {
}
}
#[stable(feature
=
"
wrapping_impls"
,
since
=
"1.7
.0"
)]
#[stable(feature
=
"
op_assign_traits"
,
since
=
"1.8
.0"
)]
impl
ShlAssign
<
$f
>
for
Wrapping
<
$t
>
{
#[inline(always)]
fn
shl_assign
(
&
mut
self
,
other
:
$f
)
{
...
...
@@ -90,7 +90,7 @@ fn shr(self, other: $f) -> Wrapping<$t> {
}
}
#[stable(feature
=
"
wrapping_impls"
,
since
=
"1.7
.0"
)]
#[stable(feature
=
"
op_assign_traits"
,
since
=
"1.8
.0"
)]
impl
ShrAssign
<
$f
>
for
Wrapping
<
$t
>
{
#[inline(always)]
fn
shr_assign
(
&
mut
self
,
other
:
$f
)
{
...
...
src/libcore/ptr.rs
浏览文件 @
06a7dcd3
...
...
@@ -761,7 +761,7 @@ fn deref(&self) -> &*mut T {
}
}
#[
stable(feature
=
"rust1"
,
since
=
"1.0.
0"
)]
#[
unstable(feature
=
"unique"
,
issue
=
"2773
0"
)]
impl
<
T
>
fmt
::
Pointer
for
Unique
<
T
>
{
fn
fmt
(
&
self
,
f
:
&
mut
fmt
::
Formatter
)
->
fmt
::
Result
{
fmt
::
Pointer
::
fmt
(
&*
self
.pointer
,
f
)
...
...
src/librustc_unicode/u_str.rs
浏览文件 @
06a7dcd3
...
...
@@ -181,6 +181,7 @@ fn size_hint(&self) -> (usize, Option<usize>) {
impl
<
I
>
FusedIterator
for
Utf16Encoder
<
I
>
where
I
:
FusedIterator
<
Item
=
char
>
{}
#[stable(feature
=
"split_whitespace"
,
since
=
"1.1.0"
)]
impl
<
'a
>
Iterator
for
SplitWhitespace
<
'a
>
{
type
Item
=
&
'a
str
;
...
...
@@ -188,6 +189,8 @@ fn next(&mut self) -> Option<&'a str> {
self
.inner
.next
()
}
}
#[stable(feature
=
"split_whitespace"
,
since
=
"1.1.0"
)]
impl
<
'a
>
DoubleEndedIterator
for
SplitWhitespace
<
'a
>
{
fn
next_back
(
&
mut
self
)
->
Option
<&
'a
str
>
{
self
.inner
.next_back
()
...
...
src/libstd/collections/hash/map.rs
浏览文件 @
06a7dcd3
...
...
@@ -1606,14 +1606,14 @@ impl<'a, K, V> ExactSizeIterator for ValuesMut<'a, K, V> {
#[unstable(feature
=
"fused"
,
issue
=
"35602"
)]
impl
<
'a
,
K
,
V
>
FusedIterator
for
ValuesMut
<
'a
,
K
,
V
>
{}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
K
,
V
>
Iterator
for
Drain
<
'a
,
K
,
V
>
{
type
Item
=
(
K
,
V
);
#[inline]
fn
next
(
&
mut
self
)
->
Option
<
(
K
,
V
)
>
{
self
.inner
.next
()
.map
(|(
_
,
k
,
v
)|
(
k
,
v
))
}
#[inline]
fn
size_hint
(
&
self
)
->
(
usize
,
Option
<
usize
>
)
{
self
.inner
.size_hint
()
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
drain"
,
since
=
"1.6
.0"
)]
impl
<
'a
,
K
,
V
>
ExactSizeIterator
for
Drain
<
'a
,
K
,
V
>
{
#[inline]
fn
len
(
&
self
)
->
usize
{
self
.inner
.len
()
}
}
...
...
@@ -2055,7 +2055,7 @@ fn finish(&self) -> u64 {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
hashmap_build_hasher"
,
since
=
"1.7
.0"
)]
impl
Default
for
RandomState
{
/// Constructs a new `RandomState`.
#[inline]
...
...
src/libstd/net/ip.rs
浏览文件 @
06a7dcd3
...
...
@@ -277,8 +277,7 @@ pub fn to_ipv6_mapped(&self) -> Ipv6Addr {
}
}
#[stable(feature
=
"rust1"
,
since
=
"1.0.0"
)]
#[allow(deprecated)]
#[stable(feature
=
"ip_addr"
,
since
=
"1.7.0"
)]
impl
fmt
::
Display
for
IpAddr
{
fn
fmt
(
&
self
,
fmt
:
&
mut
fmt
::
Formatter
)
->
fmt
::
Result
{
match
*
self
{
...
...
src/libstd/net/parser.rs
浏览文件 @
06a7dcd3
...
...
@@ -302,7 +302,7 @@ fn read_socket_addr(&mut self) -> Option<SocketAddr> {
}
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
ip_addr"
,
since
=
"1.7
.0"
)]
impl
FromStr
for
IpAddr
{
type
Err
=
AddrParseError
;
fn
from_str
(
s
:
&
str
)
->
Result
<
IpAddr
,
AddrParseError
>
{
...
...
src/libstd/panic.rs
浏览文件 @
06a7dcd3
...
...
@@ -196,9 +196,9 @@ impl<'a, T: RefUnwindSafe + ?Sized> UnwindSafe for &'a T {}
impl
<
T
:
RefUnwindSafe
+
?
Sized
>
UnwindSafe
for
*
const
T
{}
#[stable(feature
=
"catch_unwind"
,
since
=
"1.9.0"
)]
impl
<
T
:
RefUnwindSafe
+
?
Sized
>
UnwindSafe
for
*
mut
T
{}
#[
stable(feature
=
"catch_unwind"
,
since
=
"1.9.
0"
)]
#[
unstable(feature
=
"unique"
,
issue
=
"2773
0"
)]
impl
<
T
:
UnwindSafe
>
UnwindSafe
for
Unique
<
T
>
{}
#[
stable(feature
=
"catch_unwind"
,
since
=
"1.9.
0"
)]
#[
unstable(feature
=
"shared"
,
issue
=
"2773
0"
)]
impl
<
T
:
RefUnwindSafe
+
?
Sized
>
UnwindSafe
for
Shared
<
T
>
{}
#[stable(feature
=
"catch_unwind"
,
since
=
"1.9.0"
)]
impl
<
T
:
?
Sized
>
UnwindSafe
for
Mutex
<
T
>
{}
...
...
src/libstd/sync/mpsc/select.rs
浏览文件 @
06a7dcd3
...
...
@@ -352,14 +352,12 @@ fn next(&mut self) -> Option<*mut Handle<'static, ()>> {
}
}
#[stable(feature
=
"mpsc_debug"
,
since
=
"1.7.0"
)]
impl
fmt
::
Debug
for
Select
{
fn
fmt
(
&
self
,
f
:
&
mut
fmt
::
Formatter
)
->
fmt
::
Result
{
write!
(
f
,
"Select {{ .. }}"
)
}
}
#[stable(feature
=
"mpsc_debug"
,
since
=
"1.7.0"
)]
impl
<
'rx
,
T
:
Send
+
'rx
>
fmt
::
Debug
for
Handle
<
'rx
,
T
>
{
fn
fmt
(
&
self
,
f
:
&
mut
fmt
::
Formatter
)
->
fmt
::
Result
{
write!
(
f
,
"Handle {{ .. }}"
)
...
...
src/libstd/sys/unix/ext/process.rs
浏览文件 @
06a7dcd3
...
...
@@ -161,21 +161,21 @@ fn as_raw_fd(&self) -> RawFd {
}
}
#[stable(feature
=
"
process_extensions"
,
since
=
"1.2
.0"
)]
#[stable(feature
=
"
into_raw_os"
,
since
=
"1.4
.0"
)]
impl
IntoRawFd
for
process
::
ChildStdin
{
fn
into_raw_fd
(
self
)
->
RawFd
{
self
.into_inner
()
.into_fd
()
.into_raw
()
}
}
#[stable(feature
=
"
process_extensions"
,
since
=
"1.2
.0"
)]
#[stable(feature
=
"
into_raw_os"
,
since
=
"1.4
.0"
)]
impl
IntoRawFd
for
process
::
ChildStdout
{
fn
into_raw_fd
(
self
)
->
RawFd
{
self
.into_inner
()
.into_fd
()
.into_raw
()
}
}
#[stable(feature
=
"
process_extensions"
,
since
=
"1.2
.0"
)]
#[stable(feature
=
"
into_raw_os"
,
since
=
"1.4
.0"
)]
impl
IntoRawFd
for
process
::
ChildStderr
{
fn
into_raw_fd
(
self
)
->
RawFd
{
self
.into_inner
()
.into_fd
()
.into_raw
()
...
...
src/libstd/sys/windows/ext/process.rs
浏览文件 @
06a7dcd3
...
...
@@ -33,7 +33,7 @@ fn as_raw_handle(&self) -> RawHandle {
}
}
#[stable(feature
=
"
process_extensions"
,
since
=
"1.2
.0"
)]
#[stable(feature
=
"
into_raw_os"
,
since
=
"1.4
.0"
)]
impl
IntoRawHandle
for
process
::
Child
{
fn
into_raw_handle
(
self
)
->
RawHandle
{
self
.into_inner
()
.into_handle
()
.into_raw
()
as
*
mut
_
...
...
@@ -61,21 +61,21 @@ fn as_raw_handle(&self) -> RawHandle {
}
}
#[stable(feature
=
"
process_extensions"
,
since
=
"1.2
.0"
)]
#[stable(feature
=
"
into_raw_os"
,
since
=
"1.4
.0"
)]
impl
IntoRawHandle
for
process
::
ChildStdin
{
fn
into_raw_handle
(
self
)
->
RawHandle
{
self
.into_inner
()
.into_handle
()
.into_raw
()
as
*
mut
_
}
}
#[stable(feature
=
"
process_extensions"
,
since
=
"1.2
.0"
)]
#[stable(feature
=
"
into_raw_os"
,
since
=
"1.4
.0"
)]
impl
IntoRawHandle
for
process
::
ChildStdout
{
fn
into_raw_handle
(
self
)
->
RawHandle
{
self
.into_inner
()
.into_handle
()
.into_raw
()
as
*
mut
_
}
}
#[stable(feature
=
"
process_extensions"
,
since
=
"1.2
.0"
)]
#[stable(feature
=
"
into_raw_os"
,
since
=
"1.4
.0"
)]
impl
IntoRawHandle
for
process
::
ChildStderr
{
fn
into_raw_handle
(
self
)
->
RawHandle
{
self
.into_inner
()
.into_handle
()
.into_raw
()
as
*
mut
_
...
...
@@ -91,7 +91,7 @@ pub trait ExitStatusExt {
fn
from_raw
(
raw
:
u32
)
->
Self
;
}
#[stable(feature
=
"
rust1"
,
since
=
"1.0
.0"
)]
#[stable(feature
=
"
exit_status_from"
,
since
=
"1.12
.0"
)]
impl
ExitStatusExt
for
process
::
ExitStatus
{
fn
from_raw
(
raw
:
u32
)
->
Self
{
process
::
ExitStatus
::
from_inner
(
From
::
from
(
raw
))
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录