I noticed that the sys::windows::os_str::Slice type is not repr(transparent) while sys::unix::os_str::Slice is. However, they are required to have a transparent representation.
While the standard library may(?) assume they will properly transmute, it might be better to add #[repr(transparent)] to sys::windows::os_str::Slice. Possibly this affects other systems as well.
See also this thread/post on URLO.
I noticed that the
sys::windows::os_str::Slicetype is notrepr(transparent)whilesys::unix::os_str::Sliceis. However, they are required to have a transparent representation.While the standard library may(?) assume they will properly transmute, it might be better to add
#[repr(transparent)]tosys::windows::os_str::Slice. Possibly this affects other systems as well.See also this thread/post on URLO.