diff options
author | Mark Swanson <maswanso@Akamai.com> | 2016-05-31 10:20:43 -0400 |
---|---|---|
committer | Mark Swanson <maswanso@Akamai.com> | 2016-05-31 10:20:43 -0400 |
commit | 3639e62a3b3dbe0b9830810192a1ef61549e727e (patch) | |
tree | 07be8175fdb3553f50320faa559e4b64abcaf652 /src | |
parent | 010e34f63756ae7b83584b5f9cd79a85308b52eb (diff) | |
download | milf-rs-3639e62a3b3dbe0b9830810192a1ef61549e727e.tar.gz milf-rs-3639e62a3b3dbe0b9830810192a1ef61549e727e.zip |
Rely on lifetime elision.
Diffstat (limited to 'src')
-rw-r--r-- | src/lib.rs | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -180,7 +180,7 @@ impl Value { /// let no_bar = value.lookup("test.bar"); /// assert_eq!(no_bar.is_none(), true); /// ``` - pub fn lookup<'a, 'b>(&'a self, path: &'b str) -> Option<&'a Value> { + pub fn lookup(&self, path: &str) -> Option<&Value> { let ref path = match Parser::new(path).lookup() { Some(path) => path, None => return None, @@ -240,7 +240,7 @@ impl Value { /// let result = value.lookup_mut("test.foo").unwrap(); /// assert_eq!(result.as_str().unwrap(), "foo"); /// ``` - pub fn lookup_mut<'a, 'b>(&'a mut self, path: &'b str) -> Option<&'a mut Value> { + pub fn lookup_mut(&mut self, path: &str) -> Option<&mut Value> { let ref path = match Parser::new(path).lookup() { Some(path) => path, None => return None, |