Rollup merge of #77176 - austinkeeley:intrinsics-documentatation-error, r=jyn514

Removing erroneous semicolon in transmute documentation

There is a semicolon in the example code that causes the expected value to not be returned.
This commit is contained in:
Jonas Schievink 2020-09-25 19:42:50 +02:00 committed by GitHub
commit a7bdf851cf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -905,7 +905,7 @@ extern "rust-intrinsic" {
/// let raw_bytes = [0x78, 0x56, 0x34, 0x12];
///
/// let num = unsafe {
/// std::mem::transmute::<[u8; 4], u32>(raw_bytes);
/// std::mem::transmute::<[u8; 4], u32>(raw_bytes)
/// };
///
/// // use `u32::from_ne_bytes` instead