Skip to content

Commit 7fb79cf

Browse files
committed
---
yaml --- r: 235435 b: refs/heads/stable c: 68781e2 h: refs/heads/master i: 235433: 3b11a77 235431: 6fae094 v: v3
1 parent 9bc76e5 commit 7fb79cf

File tree

19 files changed

+265
-272
lines changed

19 files changed

+265
-272
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/heads/tmp: afae2ff723393b3ab4ccffef6ac7c6d1809e2da0
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: f859507de8c410b648d934d8f5ec1c52daac971d
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828
32-
refs/heads/stable: 9ac3f4277163ff8b537b998ac1549111d32f8289
32+
refs/heads/stable: 68781e25c5465021d25e2ff9d3818577e70c6545
3333
refs/tags/1.0.0: 55bd4f8ff2b323f317ae89e254ce87162d52a375
3434
refs/tags/1.1.0: bc3c16f09287e5545c1d3f76b7abd54f2eca868b
3535
refs/tags/1.2.0: f557861f822c34f07270347b94b5280de20a597e

branches/stable/CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,8 @@ Documentation improvements are very welcome. The source of `doc.rust-lang.org`
133133
is located in `src/doc` in the tree, and standard API documentation is generated
134134
from the source code itself.
135135

136-
Documentation pull requests function in the same way as other pull requests,
137-
though you may see a slightly different form of `r+`:
136+
Documentation pull requests function in the same as other pull requests, though
137+
you may see a slightly different form of `r+`:
138138

139139
@bors: r+ 38fe8d2 rollup
140140

branches/stable/RELEASES.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,6 @@ Breaking Changes
2828
in, and the same value reported by clang's
2929
`alignof`. [`mem::min_align_of`] is deprecated. This is not known to
3030
break real code.
31-
* [The `#[packed]` attribute is no longer silently accepted by the
32-
compiler][packed]. This attribute did nothing and code that
33-
mentioned it likely did not work as intended.
3431

3532
Language
3633
--------
@@ -143,7 +140,7 @@ Misc
143140
[fat]: https://github.com/rust-lang/rust/pull/26411
144141
[dst]: https://github.com/rust-lang/rfcs/blob/master/text/0982-dst-coercion.md
145142
[parcodegen]: https://github.com/rust-lang/rust/pull/26018
146-
[packed]: https://github.com/rust-lang/rust/pull/25541
143+
147144

148145
Version 1.1.0 (June 2015)
149146
=========================

branches/stable/src/doc/trpl/inline-assembly.md

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ fn main() {
103103
If you would like to use real operands in this position, however,
104104
you are required to put curly braces `{}` around the register that
105105
you want, and you are required to put the specific size of the
106-
operand. This is useful for very low level programming, where
106+
operand. This is useful for very low level programming, where
107107
which register you use is important:
108108

109109
```rust
@@ -166,12 +166,3 @@ unsafe {
166166
println!("eax is currently {}", result);
167167
# }
168168
```
169-
170-
## More Information
171-
172-
The current implementation of the `asm!` macro is a direct binding to [LLVM's
173-
inline assembler expressions][llvm-docs], so be sure to check out [their
174-
documentation as well][llvm-docs] for more information about clobbers,
175-
constraints, etc.
176-
177-
[llvm-docs]: http://llvm.org/docs/LangRef.html#inline-assembler-expressions

branches/stable/src/doc/trpl/ownership.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ With that in mind, let’s learn about ownership.
4242
# Ownership
4343

4444
[Variable bindings][bindings] have a property in Rust: they ‘have ownership’
45-
of what they’re bound to. This means that when a binding goes out of scope,
46-
Rust will free the bound resources. For example:
45+
of what they’re bound to. This means that when a binding goes out of scope, the
46+
resource that they’re bound to are freed. For example:
4747

4848
```rust
4949
fn foo() {

branches/stable/src/doc/trpl/the-stack-and-the-heap.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ After `bar()` is over, its frame is deallocated, leaving just `foo()` and
176176
| 1 | a | 5 |
177177
| 0 | x | 42 |
178178

179-
And then `foo()` ends, leaving just `main()`:
179+
And then `foo()` ends, leaving just `main()`
180180

181181
| Address | Name | Value |
182182
|---------|------|-------|
@@ -537,7 +537,7 @@ Generally, you should prefer stack allocation, and so, Rust stack-allocates by
537537
default. The LIFO model of the stack is simpler, at a fundamental level. This
538538
has two big impacts: runtime efficiency and semantic impact.
539539

540-
## Runtime Efficiency
540+
## Runtime Efficiency.
541541

542542
Managing the memory for the stack is trivial: The machine just
543543
increments or decrements a single value, the so-called “stack pointer”.

branches/stable/src/libcollections/str.rs

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -550,14 +550,6 @@ impl str {
550550
core_str::StrExt::slice_unchecked(self, begin, end)
551551
}
552552

553-
/// Takes a bytewise mutable slice from a string.
554-
///
555-
/// Same as `slice_unchecked`, but works with `&mut str` instead of `&str`.
556-
#[unstable(feature = "str_slice_mut", reason = "recently added")]
557-
pub unsafe fn slice_mut_unchecked(&mut self, begin: usize, end: usize) -> &mut str {
558-
core_str::StrExt::slice_mut_unchecked(self, begin, end)
559-
}
560-
561553
/// Returns a slice of the string from the character range [`begin`..`end`).
562554
///
563555
/// That is, start at the `begin`-th code point of the string and continue
@@ -784,7 +776,7 @@ impl str {
784776
///
785777
/// # Examples
786778
/// ```
787-
/// # #![feature(str_split_at)]
779+
/// # #![feature(collections)]
788780
/// let s = "Löwe 老虎 Léopard";
789781
/// let first_space = s.find(' ').unwrap_or(s.len());
790782
/// let (a, b) = s.split_at(first_space);
@@ -793,18 +785,10 @@ impl str {
793785
/// assert_eq!(b, " 老虎 Léopard");
794786
/// ```
795787
#[inline]
796-
#[unstable(feature = "str_split_at", reason = "recently added")]
797788
pub fn split_at(&self, mid: usize) -> (&str, &str) {
798789
core_str::StrExt::split_at(self, mid)
799790
}
800791

801-
/// Divide one mutable string slice into two at an index.
802-
#[inline]
803-
#[unstable(feature = "str_split_at", reason = "recently added")]
804-
pub fn split_at_mut(&mut self, mid: usize) -> (&mut str, &mut str) {
805-
core_str::StrExt::split_at_mut(self, mid)
806-
}
807-
808792
/// An iterator over the codepoints of `self`.
809793
///
810794
/// # Examples

branches/stable/src/libcollections/string.rs

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -979,38 +979,6 @@ impl ops::Index<ops::RangeFull> for String {
979979
}
980980
}
981981

982-
#[cfg(not(stage0))]
983-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
984-
impl ops::IndexMut<ops::Range<usize>> for String {
985-
#[inline]
986-
fn index_mut(&mut self, index: ops::Range<usize>) -> &mut str {
987-
&mut self[..][index]
988-
}
989-
}
990-
#[cfg(not(stage0))]
991-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
992-
impl ops::IndexMut<ops::RangeTo<usize>> for String {
993-
#[inline]
994-
fn index_mut(&mut self, index: ops::RangeTo<usize>) -> &mut str {
995-
&mut self[..][index]
996-
}
997-
}
998-
#[cfg(not(stage0))]
999-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
1000-
impl ops::IndexMut<ops::RangeFrom<usize>> for String {
1001-
#[inline]
1002-
fn index_mut(&mut self, index: ops::RangeFrom<usize>) -> &mut str {
1003-
&mut self[..][index]
1004-
}
1005-
}
1006-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
1007-
impl ops::IndexMut<ops::RangeFull> for String {
1008-
#[inline]
1009-
fn index_mut(&mut self, _index: ops::RangeFull) -> &mut str {
1010-
unsafe { mem::transmute(&mut *self.vec) }
1011-
}
1012-
}
1013-
1014982
#[stable(feature = "rust1", since = "1.0.0")]
1015983
impl ops::Deref for String {
1016984
type Target = str;
@@ -1021,14 +989,6 @@ impl ops::Deref for String {
1021989
}
1022990
}
1023991

1024-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
1025-
impl ops::DerefMut for String {
1026-
#[inline]
1027-
fn deref_mut(&mut self) -> &mut str {
1028-
unsafe { mem::transmute(&mut self.vec[..]) }
1029-
}
1030-
}
1031-
1032992
/// Wrapper type providing a `&String` reference via `Deref`.
1033993
#[unstable(feature = "collections")]
1034994
#[deprecated(since = "1.2.0",

branches/stable/src/libcollectionstest/lib.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
#![feature(ascii)]
1211
#![feature(append)]
1312
#![feature(bitset)]
1413
#![feature(bitvec)]
@@ -44,7 +43,6 @@
4443
#![feature(str_char)]
4544
#![feature(str_escape)]
4645
#![feature(str_match_indices)]
47-
#![feature(str_split_at)]
4846
#![feature(str_utf16)]
4947
#![feature(box_str)]
5048
#![feature(subslice_offset)]

branches/stable/src/libcollectionstest/str.rs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -701,18 +701,6 @@ fn test_split_at() {
701701
assert_eq!(b, "");
702702
}
703703

704-
#[test]
705-
fn test_split_at_mut() {
706-
use std::ascii::AsciiExt;
707-
let mut s = "Hello World".to_string();
708-
{
709-
let (a, b) = s.split_at_mut(5);
710-
a.make_ascii_uppercase();
711-
b.make_ascii_lowercase();
712-
}
713-
assert_eq!(s, "HELLO world");
714-
}
715-
716704
#[test]
717705
#[should_panic]
718706
fn test_split_at_boundscheck() {

branches/stable/src/libcore/str/mod.rs

Lines changed: 0 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -1116,23 +1116,6 @@ mod traits {
11161116
}
11171117
}
11181118

1119-
/// Returns a mutable slice of the given string from the byte range
1120-
/// [`begin`..`end`).
1121-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
1122-
impl ops::IndexMut<ops::Range<usize>> for str {
1123-
#[inline]
1124-
fn index_mut(&mut self, index: ops::Range<usize>) -> &mut str {
1125-
// is_char_boundary checks that the index is in [0, .len()]
1126-
if index.start <= index.end &&
1127-
self.is_char_boundary(index.start) &&
1128-
self.is_char_boundary(index.end) {
1129-
unsafe { self.slice_mut_unchecked(index.start, index.end) }
1130-
} else {
1131-
super::slice_error_fail(self, index.start, index.end)
1132-
}
1133-
}
1134-
}
1135-
11361119
/// Returns a slice of the string from the beginning to byte
11371120
/// `end`.
11381121
///
@@ -1155,21 +1138,6 @@ mod traits {
11551138
}
11561139
}
11571140

1158-
/// Returns a mutable slice of the string from the beginning to byte
1159-
/// `end`.
1160-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
1161-
impl ops::IndexMut<ops::RangeTo<usize>> for str {
1162-
#[inline]
1163-
fn index_mut(&mut self, index: ops::RangeTo<usize>) -> &mut str {
1164-
// is_char_boundary checks that the index is in [0, .len()]
1165-
if self.is_char_boundary(index.end) {
1166-
unsafe { self.slice_mut_unchecked(0, index.end) }
1167-
} else {
1168-
super::slice_error_fail(self, 0, index.end)
1169-
}
1170-
}
1171-
}
1172-
11731141
/// Returns a slice of the string from `begin` to its end.
11741142
///
11751143
/// Equivalent to `self[begin .. self.len()]`.
@@ -1191,21 +1159,6 @@ mod traits {
11911159
}
11921160
}
11931161

1194-
/// Returns a slice of the string from `begin` to its end.
1195-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
1196-
impl ops::IndexMut<ops::RangeFrom<usize>> for str {
1197-
#[inline]
1198-
fn index_mut(&mut self, index: ops::RangeFrom<usize>) -> &mut str {
1199-
// is_char_boundary checks that the index is in [0, .len()]
1200-
if self.is_char_boundary(index.start) {
1201-
let len = self.len();
1202-
unsafe { self.slice_mut_unchecked(index.start, len) }
1203-
} else {
1204-
super::slice_error_fail(self, index.start, self.len())
1205-
}
1206-
}
1207-
}
1208-
12091162
#[stable(feature = "rust1", since = "1.0.0")]
12101163
impl ops::Index<ops::RangeFull> for str {
12111164
type Output = str;
@@ -1215,14 +1168,6 @@ mod traits {
12151168
self
12161169
}
12171170
}
1218-
1219-
#[stable(feature = "derefmut_for_string", since = "1.2.0")]
1220-
impl ops::IndexMut<ops::RangeFull> for str {
1221-
#[inline]
1222-
fn index_mut(&mut self, _index: ops::RangeFull) -> &mut str {
1223-
self
1224-
}
1225-
}
12261171
}
12271172

12281173
/// Methods for string slices
@@ -1259,7 +1204,6 @@ pub trait StrExt {
12591204
fn char_len(&self) -> usize;
12601205
fn slice_chars<'a>(&'a self, begin: usize, end: usize) -> &'a str;
12611206
unsafe fn slice_unchecked<'a>(&'a self, begin: usize, end: usize) -> &'a str;
1262-
unsafe fn slice_mut_unchecked<'a>(&'a mut self, begin: usize, end: usize) -> &'a mut str;
12631207
fn starts_with<'a, P: Pattern<'a>>(&'a self, pat: P) -> bool;
12641208
fn ends_with<'a, P: Pattern<'a>>(&'a self, pat: P) -> bool
12651209
where P::Searcher: ReverseSearcher<'a>;
@@ -1279,7 +1223,6 @@ pub trait StrExt {
12791223
where P::Searcher: ReverseSearcher<'a>;
12801224
fn find_str<'a, P: Pattern<'a>>(&'a self, pat: P) -> Option<usize>;
12811225
fn split_at(&self, mid: usize) -> (&str, &str);
1282-
fn split_at_mut(&mut self, mid: usize) -> (&mut str, &mut str);
12831226
fn slice_shift_char<'a>(&'a self) -> Option<(char, &'a str)>;
12841227
fn subslice_offset(&self, inner: &str) -> usize;
12851228
fn as_ptr(&self) -> *const u8;
@@ -1436,14 +1379,6 @@ impl StrExt for str {
14361379
})
14371380
}
14381381

1439-
#[inline]
1440-
unsafe fn slice_mut_unchecked(&mut self, begin: usize, end: usize) -> &mut str {
1441-
mem::transmute(Slice {
1442-
data: self.as_ptr().offset(begin as isize),
1443-
len: end - begin,
1444-
})
1445-
}
1446-
14471382
#[inline]
14481383
fn starts_with<'a, P: Pattern<'a>>(&'a self, pat: P) -> bool {
14491384
pat.is_prefix_of(self)
@@ -1592,20 +1527,6 @@ impl StrExt for str {
15921527
}
15931528
}
15941529

1595-
fn split_at_mut(&mut self, mid: usize) -> (&mut str, &mut str) {
1596-
// is_char_boundary checks that the index is in [0, .len()]
1597-
if self.is_char_boundary(mid) {
1598-
let len = self.len();
1599-
unsafe {
1600-
let self2: &mut str = mem::transmute_copy(&self);
1601-
(self.slice_mut_unchecked(0, mid),
1602-
self2.slice_mut_unchecked(mid, len))
1603-
}
1604-
} else {
1605-
slice_error_fail(self, 0, mid)
1606-
}
1607-
}
1608-
16091530
#[inline]
16101531
fn slice_shift_char(&self) -> Option<(char, &str)> {
16111532
if self.is_empty() {

branches/stable/src/librustdoc/html/static/main.css

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -128,9 +128,6 @@ code, pre {
128128
border-radius: 3px;
129129
padding: 0 0.2em;
130130
}
131-
.docblock pre code {
132-
padding: 0;
133-
}
134131
pre {
135132
background-color: #F5F5F5;
136133
padding: 14px;

0 commit comments

Comments
 (0)