Add missing `From` impls for dynamically sized types like str, [T], etc.
sunjay opened this issue · 0 comments
sunjay commented
The difficulty with copying these impls directly from std is that you need to have a version of from_raw
that works with ?Sized
types. This currently doesn't work because memoffset::offset_of
only supports Sized
types.
@Manishearth might have a way to do it using the existing support for DSTs.
-
From<&[T]>
-
From<&CStr>
-
From<&OsStr>
-
From<&Path>
-
From<&str>
-
From<Arc<W>>
-
From<Box<T>>
-
From<CString>
-
From<OsString>
-
From<PathBuf>
-
From<String>
-
From<Vec<T>>