diff options
author | Ben S <ogham@bsago.me> | 2014-11-26 07:40:52 +0000 |
---|---|---|
committer | Ben S <ogham@bsago.me> | 2014-11-26 07:40:52 +0000 |
commit | 8b3602f20f9d611b4bf644250da5f670a139dc9a (patch) | |
tree | 349c7be32b9b7c35f78512bca697fd7d5b85d07e /src/dir.rs | |
parent | 05dd644c92ed32ad29117f5ea01bad94e07e9067 (diff) |
Remove unused lifetime
Diffstat (limited to 'src/dir.rs')
-rw-r--r-- | src/dir.rs | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -7,20 +7,20 @@ use file::File; // surrounding files, such as whether it needs to be coloured // differently if a certain other file exists. -pub struct Dir<'a> { +pub struct Dir { pub contents: Vec<Path>, pub path: Path, } -impl<'a> Dir<'a> { - pub fn readdir(path: Path) -> IoResult<Dir<'a>> { +impl Dir { + pub fn readdir(path: Path) -> IoResult<Dir> { fs::readdir(&path).map(|paths| Dir { contents: paths, path: path.clone(), }) } - pub fn files(&'a self) -> Vec<File<'a>> { + pub fn files(&self) -> Vec<File> { let mut files = vec![]; for path in self.contents.iter() { |