File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ use std::{
77 fmt:: { self , Write } ,
88} ;
99
10- use bstr:: ByteSlice ;
10+ use bstr:: { BStr , ByteSlice } ;
1111
1212///
1313pub mod parse;
@@ -101,18 +101,18 @@ impl Url {
101101 }
102102}
103103
104- impl TryFrom < & [ u8 ] > for Url {
104+ impl TryFrom < & BStr > for Url {
105105 type Error = parse:: Error ;
106106
107- fn try_from ( value : & [ u8 ] ) -> Result < Self , Self :: Error > {
107+ fn try_from ( value : & BStr ) -> Result < Self , Self :: Error > {
108108 Self :: from_bytes ( value)
109109 }
110110}
111111
112- impl < ' a > TryFrom < std:: borrow:: Cow < ' a , [ u8 ] > > for Url {
112+ impl < ' a > TryFrom < std:: borrow:: Cow < ' a , BStr > > for Url {
113113 type Error = parse:: Error ;
114114
115- fn try_from ( value : std:: borrow:: Cow < ' a , [ u8 ] > ) -> Result < Self , Self :: Error > {
115+ fn try_from ( value : std:: borrow:: Cow < ' a , BStr > ) -> Result < Self , Self :: Error > {
116116 Self :: try_from ( & * value)
117117 }
118118}
You can’t perform that action at this time.
0 commit comments