Skip to content

Commit 9ccfabe

Browse files
author
Jorge Aparicio
committed
---
yaml --- r: 163447 b: refs/heads/snap-stage3 c: 949b55e h: refs/heads/master i: 163445: a365629 163443: 2a0dd94 163439: 1a45e19 v: v3
1 parent e5f2270 commit 9ccfabe

File tree

3 files changed

+18
-1
lines changed

3 files changed

+18
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: 9146a919b616e39e528e4d7100d16eef52f1f852
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: f4abb12b0c822e119e69023ab94664415061d955
4+
refs/heads/snap-stage3: 949b55e58e8a26e5c05cc5350dee8017e7653ad5
55
refs/heads/try: 20cbbffeefc1f35e2ea63afce7b42fbd79611d42
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d

branches/snap-stage3/src/libcollections/string.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -874,6 +874,14 @@ impl<'a> Add<&'a str, String> for String {
874874
}
875875
}
876876

877+
#[cfg(not(stage0))] // NOTE(stage0): Remove cfg after a snapshot
878+
impl<'a> Add<String, String> for &'a str {
879+
fn add(self, mut other: String) -> String {
880+
other.push_str(self);
881+
other
882+
}
883+
}
884+
877885
impl ops::Slice<uint, str> for String {
878886
#[inline]
879887
fn as_slice_<'a>(&'a self) -> &'a str {

branches/snap-stage3/src/libcollections/vec.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1295,6 +1295,15 @@ impl<'a, T: Clone> Add<&'a [T], Vec<T>> for Vec<T> {
12951295
}
12961296
}
12971297

1298+
#[cfg(not(stage0))] // NOTE(stage0): Remove impl after a snapshot
1299+
impl<'a, T: Clone> Add<Vec<T>, Vec<T>> for &'a [T] {
1300+
#[inline]
1301+
fn add(self, mut rhs: Vec<T>) -> Vec<T> {
1302+
rhs.push_all(self);
1303+
rhs
1304+
}
1305+
}
1306+
12981307
#[unsafe_destructor]
12991308
impl<T> Drop for Vec<T> {
13001309
fn drop(&mut self) {

0 commit comments

Comments
 (0)