You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix transmutes to/from type with unspecified layout (Utf8Char)
This crate (among others) did'nt compile with an experimental [more strict
transmute check](rust-lang/rust#51294)
Hare's the error messages: (from http://cargobomb-reports.s3.amazonaws.com/pr-51294/5298b81bebd26bb9f87d5f99764aab01595b3f69-alt/reg/encode_unicode-0.3.1/log.txt)
Jul 05 13:02:02.884 INFO kablam! error[E0912]: transmutation to a type with an unspecified layout
Jul 05 13:02:02.884 INFO kablam! --> src/utf8_char.rs:283:16
Jul 05 13:02:02.884 INFO kablam! |
Jul 05 13:02:02.884 INFO kablam! 283 | Ok(transmute(unused_zeroed))
Jul 05 13:02:02.884 INFO kablam! | ^^^^^^^^^
Jul 05 13:02:02.884 INFO kablam! |
Jul 05 13:02:02.884 INFO kablam! = note: utf8_char::Utf8Char has an unspecified layout
Jul 05 13:02:02.884 INFO kablam!
Jul 05 13:02:02.884 INFO kablam! error[E0912]: transmutation from a type with an unspecified layout
Jul 05 13:02:02.884 INFO kablam! --> src/utf8_iterator.rs:25:41
Jul 05 13:02:02.884 INFO kablam! |
Jul 05 13:02:02.884 INFO kablam! 25 | let used = u32::from_le(unsafe{ mem::transmute(uc) });
Jul 05 13:02:02.884 INFO kablam! | ^^^^^^^^^^^^^^
Jul 05 13:02:02.884 INFO kablam! |
Jul 05 13:02:02.884 INFO kablam! = note: utf8_char::Utf8Char has an unspecified layout
Jul 05 13:02:02.884 INFO kablam!
Jul 05 13:02:02.893 INFO kablam! error: aborting due to 2 previous errors
0 commit comments