Skip to content

Commit da90ff6

Browse files
committed
---
yaml --- r: 83550 b: refs/heads/try c: c687f6f h: refs/heads/master v: v3
1 parent 8b62f3b commit da90ff6

File tree

3 files changed

+2
-20
lines changed

3 files changed

+2
-20
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 0e4d1fc8cae42e15e00f71d9f439b01bb25a86ae
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 6c08cc2db4f98e9f07ae7d50338396c4123c2f0a
5-
refs/heads/try: 21b24e148bd350c6f4945c35a7a30268ccf7d3cb
5+
refs/heads/try: c687f6fa92312ef05341f9da2ac261634f44ba56
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c

branches/try/src/libstd/rt/logging.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ pub struct StdErrLogger;
181181
impl Logger for StdErrLogger {
182182
fn log(&mut self, args: &fmt::Arguments) {
183183
if should_log_console() {
184-
fmt::write(self as &mut rt::io::Writer, args);
184+
fmt::writeln(self as &mut rt::io::Writer, args);
185185
}
186186
}
187187
}

branches/try/src/libstd/vec.rs

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -840,7 +840,6 @@ pub trait ImmutableVector<'self, T> {
840840
fn window_iter(self, size: uint) -> WindowIter<'self, T>;
841841
fn chunk_iter(self, size: uint) -> ChunkIter<'self, T>;
842842

843-
fn get_opt(&self, index: uint) -> Option<&'self T>;
844843
fn head(&self) -> &'self T;
845844
fn head_opt(&self) -> Option<&'self T>;
846845
fn tail(&self) -> &'self [T];
@@ -1020,13 +1019,6 @@ impl<'self,T> ImmutableVector<'self, T> for &'self [T] {
10201019
ChunkIter { v: self, size: size }
10211020
}
10221021

1023-
/// Returns the element of a vector at the given index, or `None` if the
1024-
/// index is out of bounds
1025-
#[inline]
1026-
fn get_opt(&self, index: uint) -> Option<&'self T> {
1027-
if index < self.len() { Some(&self[index]) } else { None }
1028-
}
1029-
10301022
/// Returns the first element of a vector, failing if the vector is empty.
10311023
#[inline]
10321024
fn head(&self) -> &'self T {
@@ -2582,16 +2574,6 @@ mod tests {
25822574
assert_eq!(v2.len(), 2);
25832575
}
25842576

2585-
#[test]
2586-
fn test_get_opt() {
2587-
let mut a = ~[11];
2588-
assert_eq!(a.get_opt(1), None);
2589-
a = ~[11, 12];
2590-
assert_eq!(a.get_opt(1).unwrap(), &12);
2591-
a = ~[11, 12, 13];
2592-
assert_eq!(a.get_opt(1).unwrap(), &12);
2593-
}
2594-
25952577
#[test]
25962578
fn test_head() {
25972579
let mut a = ~[11];

0 commit comments

Comments
 (0)