about summary refs log tree commit diff
path: root/src/libstd/rt
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstd/rt')
-rw-r--r--src/libstd/rt/io/file.rs4
-rw-r--r--src/libstd/rt/io/mod.rs6
-rw-r--r--src/libstd/rt/uv/uvio.rs3
-rw-r--r--src/libstd/rt/uv/uvll.rs4
4 files changed, 13 insertions, 4 deletions
diff --git a/src/libstd/rt/io/file.rs b/src/libstd/rt/io/file.rs
index 3869f99adea..a43bcd8142e 100644
--- a/src/libstd/rt/io/file.rs
+++ b/src/libstd/rt/io/file.rs
@@ -59,8 +59,8 @@ use path::Path;
 ///     }).inside {
 ///         let stream = match open(p, Create, ReadWrite) {
 ///             Some(s) => s,
-///             None => fail!("whoops! I'm sure this raised, anyways..");
-///         }
+///             None => fail!("whoops! I'm sure this raised, anyways..")
+///         };
 ///         // do some stuff with that stream
 ///
 ///         // the file stream will be closed at the end of this block
diff --git a/src/libstd/rt/io/mod.rs b/src/libstd/rt/io/mod.rs
index f78a20dd111..a80c1aab398 100644
--- a/src/libstd/rt/io/mod.rs
+++ b/src/libstd/rt/io/mod.rs
@@ -654,6 +654,12 @@ pub struct FileStat {
     is_file: bool,
     /// `true` if the file pointed at by the `PathInfo` is a directory
     is_dir: bool,
+    /// The file pointed at by the `PathInfo`'s device
+    device: u64,
+    /// The file pointed at by the `PathInfo`'s mode
+    mode: u64,
+    /// The file pointed at by the `PathInfo`'s inode
+    inode: u64,
     /// The file pointed at by the `PathInfo`'s size in bytes
     size: u64,
     /// The file pointed at by the `PathInfo`'s creation time
diff --git a/src/libstd/rt/uv/uvio.rs b/src/libstd/rt/uv/uvio.rs
index 13c3a30eed3..8dd0f8a6b10 100644
--- a/src/libstd/rt/uv/uvio.rs
+++ b/src/libstd/rt/uv/uvio.rs
@@ -635,6 +635,9 @@ impl IoFactory for UvIoFactory {
                                 path: Path::new(path_str.as_slice()),
                                 is_file: stat.is_file(),
                                 is_dir: stat.is_dir(),
+                                device: stat.st_dev,
+                                mode: stat.st_mode,
+                                inode: stat.st_ino,
                                 size: stat.st_size,
                                 created: stat.st_ctim.tv_sec as u64,
                                 modified: stat.st_mtim.tv_sec as u64,
diff --git a/src/libstd/rt/uv/uvll.rs b/src/libstd/rt/uv/uvll.rs
index 96c5dd068d0..367585b0f0e 100644
--- a/src/libstd/rt/uv/uvll.rs
+++ b/src/libstd/rt/uv/uvll.rs
@@ -138,13 +138,13 @@ pub struct uv_timespec_t {
 }
 
 pub struct uv_stat_t {
-    priv st_dev: libc::uint64_t,
+    st_dev: libc::uint64_t,
     st_mode: libc::uint64_t,
     priv st_nlink: libc::uint64_t,
     priv st_uid: libc::uint64_t,
     priv st_gid: libc::uint64_t,
     priv st_rdev: libc::uint64_t,
-    priv st_ino: libc::uint64_t,
+    st_ino: libc::uint64_t,
     st_size: libc::uint64_t,
     priv st_blksize: libc::uint64_t,
     priv st_blocks: libc::uint64_t,