Skip to content

Commit a298759

Browse files
committed
---
yaml --- r: 159027 b: refs/heads/auto c: a722f70 h: refs/heads/master i: 159025: ebf3619 159023: e7e3923 v: v3
1 parent 72e7077 commit a298759

File tree

168 files changed

+5282
-6119
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

168 files changed

+5282
-6119
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1010
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
1111
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
1212
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
13-
refs/heads/auto: efc9a441b9f48912166b0ce375efe677edc0e93a
13+
refs/heads/auto: a722f70207cf8419150c52cbf79ef5b9eadb1639
1414
refs/heads/servo: af82457af293e2a842ba6b7759b70288da276167
1515
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
1616
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336

branches/auto/configure

Lines changed: 5 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -76,24 +76,6 @@ putvar() {
7676
printf "%-20s := %s\n" $1 "$T" >>config.tmp
7777
}
7878

79-
putpathvar() {
80-
local T
81-
eval T=\$$1
82-
eval TLEN=\${#$1}
83-
if [ $TLEN -gt 35 ]
84-
then
85-
printf "configure: %-20s := %.35s ...\n" $1 "$T"
86-
else
87-
printf "configure: %-20s := %s %s\n" $1 "$T" "$2"
88-
fi
89-
if [ -z "$T" ]
90-
then
91-
printf "%-20s := \n" $1 >>config.tmp
92-
else
93-
printf "%-20s := \"%s\"\n" $1 "$T" >>config.tmp
94-
fi
95-
}
96-
9779
probe() {
9880
local V=$1
9981
shift
@@ -119,7 +101,7 @@ probe() {
119101
fi
120102
done
121103
eval $V=\$T
122-
putpathvar $V "$VER"
104+
putvar $V "$VER"
123105
}
124106

125107
probe_need() {
@@ -656,9 +638,9 @@ probe CFG_ADB adb
656638

657639
if [ ! -z "$CFG_PANDOC" ]
658640
then
659-
PV_MAJOR_MINOR=$(pandoc --version | grep '^pandoc\(.exe\)\? ' |
641+
PV_MAJOR_MINOR=$(pandoc --version | grep '^pandoc ' |
660642
# extract the first 2 version fields, ignore everything else
661-
sed 's/pandoc\(.exe\)\? \([0-9]*\)\.\([0-9]*\).*/\2 \3/')
643+
sed 's/pandoc \([0-9]*\)\.\([0-9]*\).*/\1 \2/')
662644

663645
MIN_PV_MAJOR="1"
664646
MIN_PV_MINOR="9"
@@ -1348,7 +1330,8 @@ do
13481330
done
13491331

13501332
# Munge any paths that appear in config.mk back to posix-y
1351-
perl -i.bak -p -e 's@ ([a-zA-Z]):[/\\]@ /\1/@go;' config.tmp
1333+
perl -i.bak -p -e 's@ ([a-zA-Z]):[/\\]@ /\1/@go;' \
1334+
-e 's@\\@/@go;' config.tmp
13521335
rm -f config.tmp.bak
13531336

13541337
msg

branches/auto/mk/docs.mk

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@
2828
DOCS := index intro tutorial guide guide-ffi guide-macros guide-lifetimes \
2929
guide-tasks guide-container guide-pointers guide-testing \
3030
guide-plugin guide-crates complement-bugreport \
31-
complement-lang-faq complement-design-faq complement-project-faq \
31+
complement-lang-faq complement-design-faq complement-project-faq rust \
3232
rustdoc guide-unsafe guide-strings reference
3333

3434
PDF_DOCS := guide reference
3535

36-
RUSTDOC_DEPS_reference := doc/full-toc.inc
37-
RUSTDOC_FLAGS_reference := --html-in-header=doc/full-toc.inc
36+
RUSTDOC_DEPS_rust := doc/full-toc.inc
37+
RUSTDOC_FLAGS_rust := --html-in-header=doc/full-toc.inc
3838

3939
L10N_LANGS := ja
4040

branches/auto/mk/reconfig.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ ifndef CFG_DISABLE_MANAGE_SUBMODULES
1919
# (nothing checked out at all). `./configure --{llvm,jemalloc}-root`
2020
# will explicitly deinitialize the corresponding submodules, and we don't
2121
# want to force constant rebuilds in that case.
22-
NEED_GIT_RECONFIG=$(shell cd "$(CFG_SRC_DIR)" && $(CFG_GIT) submodule status | grep -c '^+')
22+
NEED_GIT_RECONFIG=$(shell cd "$(CFG_SRC_DIR)" && "$(CFG_GIT)" submodule status | grep -c '^+')
2323
else
2424
NEED_GIT_RECONFIG=0
2525
endif

branches/auto/src/doc/guide.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1481,7 +1481,7 @@ s.push_str(", world.");
14811481
println!("{}", s);
14821482
```
14831483

1484-
You can get a `&str` view into a `String` with the `as_slice()` method:
1484+
You can coerce a `String` into a `&str` with the `as_slice()` method:
14851485

14861486
```{rust}
14871487
fn takes_slice(slice: &str) {
@@ -1514,7 +1514,7 @@ fn compare(string: String) {
15141514
}
15151515
```
15161516

1517-
Viewing a `String` as a `&str` is cheap, but converting the `&str` to a
1517+
Converting a `String` to a `&str` is cheap, but converting the `&str` to a
15181518
`String` involves allocating memory. No reason to do that unless you have to!
15191519

15201520
That's the basics of strings in Rust! They're probably a bit more complicated

branches/auto/src/doc/intro.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ including the right thing!) Even though we compiled with flags to give us as
217217
many warnings as possible, and to treat those warnings as errors, we got no
218218
errors. When we ran the program, it crashed.
219219

220-
Why does this happen? When we append to an array, its length changes. Since
220+
Why does this happen? When we prepend to an array, its length changes. Since
221221
its length changes, we may need to allocate more memory. In Ruby, this happens
222222
as well, we just don't think about it very often. So why does the C++ version
223223
segfault when we allocate more memory?

branches/auto/src/etc/vim/syntax/rust.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ syn keyword rustEnum Ordering
9393
syn keyword rustEnumVariant Less Equal Greater
9494
syn keyword rustTrait Collection Mutable Map MutableMap MutableSeq
9595
syn keyword rustTrait Set MutableSet
96-
syn keyword rustTrait FromIterator IntoIterator Extend ExactSize
96+
syn keyword rustTrait FromIterator Extendable ExactSize
9797
syn keyword rustTrait Iterator DoubleEndedIterator
9898
syn keyword rustTrait RandomAccessIterator CloneableIterator
9999
syn keyword rustTrait OrdIterator MutableDoubleEndedIterator

branches/auto/src/libcollections/binary_heap.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -555,7 +555,7 @@ impl<T: Ord> FromIterator<T> for BinaryHeap<T> {
555555
}
556556
}
557557

558-
impl<T: Ord> Extend<T> for BinaryHeap<T> {
558+
impl<T: Ord> Extendable<T> for BinaryHeap<T> {
559559
fn extend<Iter: Iterator<T>>(&mut self, mut iter: Iter) {
560560
let (lower, _) = iter.size_hint();
561561

branches/auto/src/libcollections/bit.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -835,7 +835,7 @@ impl FromIterator<bool> for Bitv {
835835
}
836836
}
837837

838-
impl Extend<bool> for Bitv {
838+
impl Extendable<bool> for Bitv {
839839
#[inline]
840840
fn extend<I: Iterator<bool>>(&mut self, mut iterator: I) {
841841
let (min, _) = iterator.size_hint();
@@ -1014,7 +1014,7 @@ impl FromIterator<bool> for BitvSet {
10141014
}
10151015
}
10161016

1017-
impl Extend<bool> for BitvSet {
1017+
impl Extendable<bool> for BitvSet {
10181018
#[inline]
10191019
fn extend<I: Iterator<bool>>(&mut self, iterator: I) {
10201020
let &BitvSet(ref mut self_bitv) = self;

branches/auto/src/libcollections/btree/map.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -727,7 +727,7 @@ impl<K: Ord, V> FromIterator<(K, V)> for BTreeMap<K, V> {
727727
}
728728
}
729729

730-
impl<K: Ord, V> Extend<(K, V)> for BTreeMap<K, V> {
730+
impl<K: Ord, V> Extendable<(K, V)> for BTreeMap<K, V> {
731731
#[inline]
732732
fn extend<T: Iterator<(K, V)>>(&mut self, mut iter: T) {
733733
for (k, v) in iter {

branches/auto/src/libcollections/btree/set.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ impl<T: Ord> FromIterator<T> for BTreeSet<T> {
316316
}
317317
}
318318

319-
impl<T: Ord> Extend<T> for BTreeSet<T> {
319+
impl<T: Ord> Extendable<T> for BTreeSet<T> {
320320
#[inline]
321321
fn extend<Iter: Iterator<T>>(&mut self, mut iter: Iter) {
322322
for elem in iter {

branches/auto/src/libcollections/dlist.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -720,7 +720,7 @@ impl<A> FromIterator<A> for DList<A> {
720720
}
721721
}
722722

723-
impl<A> Extend<A> for DList<A> {
723+
impl<A> Extendable<A> for DList<A> {
724724
fn extend<T: Iterator<A>>(&mut self, mut iterator: T) {
725725
for elt in iterator { self.push_back(elt); }
726726
}

branches/auto/src/libcollections/enum_set.rs

Lines changed: 2 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,9 @@
1616
use core::prelude::*;
1717
use core::fmt;
1818

19+
// FIXME(conventions): implement BitXor
1920
// FIXME(contentions): implement union family of methods? (general design may be wrong here)
21+
// FIXME(conventions): implement len
2022

2123
#[deriving(Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
2224
/// A specialized `Set` implementation to use enum types.
@@ -90,12 +92,6 @@ impl<E:CLike> EnumSet<E> {
9092
EnumSet {bits: 0}
9193
}
9294

93-
/// Returns the number of elements in the given `EnumSet`.
94-
#[unstable = "matches collection reform specification, waiting for dust to settle"]
95-
pub fn len(&self) -> uint {
96-
self.bits.count_ones()
97-
}
98-
9995
/// Returns true if the `EnumSet` is empty.
10096
#[unstable = "matches collection reform specification, waiting for dust to settle"]
10197
pub fn is_empty(&self) -> bool {
@@ -200,12 +196,6 @@ impl<E:CLike> BitAnd<EnumSet<E>, EnumSet<E>> for EnumSet<E> {
200196
}
201197
}
202198

203-
impl<E:CLike> BitXor<EnumSet<E>, EnumSet<E>> for EnumSet<E> {
204-
fn bitxor(&self, e: &EnumSet<E>) -> EnumSet<E> {
205-
EnumSet {bits: self.bits ^ e.bits}
206-
}
207-
}
208-
209199
/// An iterator over an EnumSet
210200
pub struct Items<E> {
211201
index: uint,
@@ -240,22 +230,6 @@ impl<E:CLike> Iterator<E> for Items<E> {
240230
}
241231
}
242232

243-
impl<E:CLike> FromIterator<E> for EnumSet<E> {
244-
fn from_iter<I:Iterator<E>>(iterator: I) -> EnumSet<E> {
245-
let mut ret = EnumSet::new();
246-
ret.extend(iterator);
247-
ret
248-
}
249-
}
250-
251-
impl<E:CLike> Extend<E> for EnumSet<E> {
252-
fn extend<I: Iterator<E>>(&mut self, mut iterator: I) {
253-
for element in iterator {
254-
self.insert(element);
255-
}
256-
}
257-
}
258-
259233
#[cfg(test)]
260234
mod test {
261235
use std::prelude::*;
@@ -295,20 +269,6 @@ mod test {
295269
assert_eq!("{A, C}", e.to_string().as_slice());
296270
}
297271

298-
#[test]
299-
fn test_len() {
300-
let mut e = EnumSet::new();
301-
assert_eq!(e.len(), 0);
302-
e.insert(A);
303-
e.insert(B);
304-
e.insert(C);
305-
assert_eq!(e.len(), 3);
306-
e.remove(&A);
307-
assert_eq!(e.len(), 2);
308-
e.clear();
309-
assert_eq!(e.len(), 0);
310-
}
311-
312272
///////////////////////////////////////////////////////////////////////////
313273
// intersect
314274

@@ -438,29 +398,9 @@ mod test {
438398
let elems = e_intersection.iter().collect();
439399
assert_eq!(vec![C], elems)
440400

441-
// Another way to express intersection
442-
let e_intersection = e1 - (e1 - e2);
443-
let elems = e_intersection.iter().collect();
444-
assert_eq!(vec![C], elems)
445-
446401
let e_subtract = e1 - e2;
447402
let elems = e_subtract.iter().collect();
448403
assert_eq!(vec![A], elems)
449-
450-
// Bitwise XOR of two sets, aka symmetric difference
451-
let e_symmetric_diff = e1 ^ e2;
452-
let elems = e_symmetric_diff.iter().collect();
453-
assert_eq!(vec![A,B], elems)
454-
455-
// Another way to express symmetric difference
456-
let e_symmetric_diff = (e1 - e2) | (e2 - e1);
457-
let elems = e_symmetric_diff.iter().collect();
458-
assert_eq!(vec![A,B], elems)
459-
460-
// Yet another way to express symmetric difference
461-
let e_symmetric_diff = (e1 | e2) - (e1 & e2);
462-
let elems = e_symmetric_diff.iter().collect();
463-
assert_eq!(vec![A,B], elems)
464404
}
465405

466406
#[test]

branches/auto/src/libcollections/ring_buf.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -735,7 +735,7 @@ impl<A> FromIterator<A> for RingBuf<A> {
735735
}
736736
}
737737

738-
impl<A> Extend<A> for RingBuf<A> {
738+
impl<A> Extendable<A> for RingBuf<A> {
739739
fn extend<T: Iterator<A>>(&mut self, mut iterator: T) {
740740
for elt in iterator {
741741
self.push_back(elt);

branches/auto/src/libcollections/string.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -683,8 +683,8 @@ impl FromIterator<char> for String {
683683
}
684684
}
685685

686-
#[experimental = "waiting on Extend stabilization"]
687-
impl Extend<char> for String {
686+
#[experimental = "waiting on Extendable stabilization"]
687+
impl Extendable<char> for String {
688688
fn extend<I:Iterator<char>>(&mut self, mut iterator: I) {
689689
for ch in iterator {
690690
self.push(ch)

branches/auto/src/libcollections/tree/map.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1260,7 +1260,7 @@ impl<K: Ord, V> FromIterator<(K, V)> for TreeMap<K, V> {
12601260
}
12611261
}
12621262

1263-
impl<K: Ord, V> Extend<(K, V)> for TreeMap<K, V> {
1263+
impl<K: Ord, V> Extendable<(K, V)> for TreeMap<K, V> {
12641264
#[inline]
12651265
fn extend<T: Iterator<(K, V)>>(&mut self, mut iter: T) {
12661266
for (k, v) in iter {

branches/auto/src/libcollections/tree/set.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -659,7 +659,7 @@ impl<T: Ord> FromIterator<T> for TreeSet<T> {
659659
}
660660
}
661661

662-
impl<T: Ord> Extend<T> for TreeSet<T> {
662+
impl<T: Ord> Extendable<T> for TreeSet<T> {
663663
#[inline]
664664
fn extend<Iter: Iterator<T>>(&mut self, mut iter: Iter) {
665665
for elem in iter {

branches/auto/src/libcollections/trie/map.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -628,7 +628,7 @@ impl<T> FromIterator<(uint, T)> for TrieMap<T> {
628628
}
629629
}
630630

631-
impl<T> Extend<(uint, T)> for TrieMap<T> {
631+
impl<T> Extendable<(uint, T)> for TrieMap<T> {
632632
fn extend<Iter: Iterator<(uint, T)>>(&mut self, mut iter: Iter) {
633633
for (k, v) in iter {
634634
self.insert(k, v);

branches/auto/src/libcollections/trie/set.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,7 @@ impl FromIterator<uint> for TrieSet {
355355
}
356356
}
357357

358-
impl Extend<uint> for TrieSet {
358+
impl Extendable<uint> for TrieSet {
359359
fn extend<Iter: Iterator<uint>>(&mut self, mut iter: Iter) {
360360
for elem in iter {
361361
self.insert(elem);

branches/auto/src/libcollections/vec.rs

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -484,8 +484,8 @@ impl<T> FromIterator<T> for Vec<T> {
484484
}
485485
}
486486

487-
#[experimental = "waiting on Extend stability"]
488-
impl<T> Extend<T> for Vec<T> {
487+
#[experimental = "waiting on Extendable stability"]
488+
impl<T> Extendable<T> for Vec<T> {
489489
#[inline]
490490
fn extend<I: Iterator<T>>(&mut self, mut iterator: I) {
491491
let (lower, _) = iterator.size_hint();
@@ -801,13 +801,14 @@ impl<T> Vec<T> {
801801
///
802802
/// # Example
803803
/// ```
804-
/// let mut v = vec!["foo", "bar", "baz", "qux"];
804+
/// let mut v = vec!["foo".to_string(), "bar".to_string(),
805+
/// "baz".to_string(), "qux".to_string()];
805806
///
806-
/// assert_eq!(v.swap_remove(1), Some("bar"));
807-
/// assert_eq!(v, vec!["foo", "qux", "baz"]);
807+
/// assert_eq!(v.swap_remove(1), Some("bar".to_string()));
808+
/// assert_eq!(v, vec!["foo".to_string(), "qux".to_string(), "baz".to_string()]);
808809
///
809-
/// assert_eq!(v.swap_remove(0), Some("foo"));
810-
/// assert_eq!(v, vec!["baz", "qux"]);
810+
/// assert_eq!(v.swap_remove(0), Some("foo".to_string()));
811+
/// assert_eq!(v, vec!["baz".to_string(), "qux".to_string()]);
811812
///
812813
/// assert_eq!(v.swap_remove(2), None);
813814
/// ```

branches/auto/src/libcollections/vec_map.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -499,7 +499,7 @@ impl<V> FromIterator<(uint, V)> for VecMap<V> {
499499
}
500500
}
501501

502-
impl<V> Extend<(uint, V)> for VecMap<V> {
502+
impl<V> Extendable<(uint, V)> for VecMap<V> {
503503
fn extend<Iter: Iterator<(uint, V)>>(&mut self, mut iter: Iter) {
504504
for (k, v) in iter {
505505
self.insert(k, v);

0 commit comments

Comments
 (0)