Skip to content

Commit b677a63

Browse files
committed
---
yaml --- r: 82356 b: refs/heads/master c: 7fcdcae h: refs/heads/master v: v3
1 parent 974d13d commit b677a63

File tree

3 files changed

+17
-1
lines changed

3 files changed

+17
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 33adf6dd6e0dd69af29ee11a1a7a2e11c998938c
2+
refs/heads/master: 7fcdcaeda7c264cde63df79ce5d189d91567f70b
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 6c08cc2db4f98e9f07ae7d50338396c4123c2f0a
55
refs/heads/try: 70152ff55722878cde684ee6462c14c65f2c4729

trunk/src/libstd/path2/posix.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ use iter::{AdditiveIterator, Extendable, Iterator};
1919
use option::{Option, None, Some};
2020
use str;
2121
use str::Str;
22+
use to_bytes::IterBytes;
2223
use util;
2324
use vec;
2425
use vec::CopyableVector;
@@ -75,6 +76,13 @@ impl ToCStr for Path {
7576
}
7677
}
7778

79+
impl IterBytes for Path {
80+
#[inline]
81+
fn iter_bytes(&self, lsb0: bool, f: &fn(buf: &[u8]) -> bool) -> bool {
82+
self.repr.iter_bytes(lsb0, f)
83+
}
84+
}
85+
7886
impl GenericPathUnsafe for Path {
7987
unsafe fn from_vec_unchecked(path: &[u8]) -> Path {
8088
let path = Path::normalize(path);

trunk/src/libstd/path2/windows.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ use iter::{AdditiveIterator, Extendable, Iterator};
1919
use option::{Option, Some, None};
2020
use str;
2121
use str::{OwnedStr, Str, StrVector};
22+
use to_bytes::IterBytes;
2223
use util;
2324
use vec::Vector;
2425
use super::{GenericPath, GenericPathUnsafe};
@@ -97,6 +98,13 @@ impl ToCStr for Path {
9798
}
9899
}
99100

101+
impl IterBytes for Path {
102+
#[inline]
103+
fn iter_bytes(&self, lsb0: bool, f: &fn(&[u8]) -> bool) -> bool {
104+
self.repr.iter_bytes(lsb0, f)
105+
}
106+
}
107+
100108
impl GenericPathUnsafe for Path {
101109
/// See `GenericPathUnsafe::from_vec_unchecked`.
102110
///

0 commit comments

Comments
 (0)