impl From<&'a str> for Link

This commit is contained in:
Matthias Beyer 2016-07-08 21:41:11 +02:00
parent 91e3b58f3e
commit 437b3133cc

View file

@ -15,6 +15,14 @@ impl From<String> for Link {
}
impl<'a> From<&'a str> for Link {
fn from(s: &'a str) -> Link {
Link(String::from(s))
}
}
impl Deref for Link {
type Target = String;