Skip to content

Commit c295b81

Browse files
committed
---
yaml --- r: 95415 b: refs/heads/dist-snap c: 40b324f h: refs/heads/master i: 95413: e57fe31 95411: f9c34fc 95407: 35f95d3 v: v3
1 parent 208451c commit c295b81

File tree

4 files changed

+1
-20
lines changed

4 files changed

+1
-20
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ refs/heads/try: c274a6888410ce3e357e014568b43310ed787d36
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
9-
refs/heads/dist-snap: 0c7e8f7a92318d19fd9de96ba70fa36fc41de1e2
9+
refs/heads/dist-snap: 40b324f0dec364a9fa71f9f8b47b8ab156f6d61e
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1212
refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0

branches/dist-snap/src/libstd/path/mod.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -179,9 +179,6 @@ pub trait GenericPath: Clone + GenericPathUnsafe {
179179
str::from_utf8_slice_opt(self.as_vec())
180180
}
181181

182-
/// Converts the Path into an owned string, if possible
183-
fn into_str(self) -> Option<~str>;
184-
185182
/// Returns the path as a byte vector
186183
fn as_vec<'a>(&'a self) -> &'a [u8];
187184

branches/dist-snap/src/libstd/path/posix.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -178,10 +178,6 @@ impl GenericPath for Path {
178178
self.repr
179179
}
180180

181-
fn into_str(self) -> Option<~str> {
182-
str::from_utf8_owned_opt(self.repr)
183-
}
184-
185181
fn dirname<'a>(&'a self) -> &'a [u8] {
186182
match self.sepidx {
187183
None if bytes!("..") == self.repr => self.repr.as_slice(),
@@ -614,12 +610,9 @@ mod tests {
614610
assert_eq!(Path::new(b!("foo/bar")).into_vec(), b!("foo/bar").to_owned());
615611
assert_eq!(Path::new(b!("/foo/../../bar")).into_vec(),
616612
b!("/bar").to_owned());
617-
assert_eq!(Path::new("foo/bar").into_str(), Some(~"foo/bar"));
618-
assert_eq!(Path::new("/foo/../../bar").into_str(), Some(~"/bar"));
619613

620614
let p = Path::new(b!("foo/bar", 0x80));
621615
assert_eq!(p.as_str(), None);
622-
assert_eq!(Path::new(b!("foo", 0xff, "/bar")).into_str(), None);
623616
}
624617

625618
#[test]

branches/dist-snap/src/libstd/path/windows.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -327,13 +327,6 @@ impl GenericPath for Path {
327327
Some(self.repr.as_slice())
328328
}
329329

330-
/// See `GenericPath::into_str` for info.
331-
/// Always returns a `Some` value.
332-
#[inline]
333-
fn into_str(self) -> Option<~str> {
334-
Some(self.repr)
335-
}
336-
337330
#[inline]
338331
fn as_vec<'a>(&'a self) -> &'a [u8] {
339332
self.repr.as_bytes()
@@ -1260,8 +1253,6 @@ mod tests {
12601253
assert_eq!(Path::new(b!("foo\\bar")).into_vec(), b!("foo\\bar").to_owned());
12611254
assert_eq!(Path::new(b!("\\foo\\..\\..\\bar")).into_vec(),
12621255
b!("\\bar").to_owned());
1263-
assert_eq!(Path::new("foo\\bar").into_str(), Some(~"foo\\bar"));
1264-
assert_eq!(Path::new("\\foo\\..\\..\\bar").into_str(), Some(~"\\bar"));
12651256

12661257
t!(s: Path::new("\\\\a"), "\\a");
12671258
t!(s: Path::new("\\\\a\\"), "\\a");

0 commit comments

Comments
 (0)