Skip to content

Commit f54df44

Browse files
committed
Remove note about transmute for float bitpatterns.
1 parent 9f9f2c0 commit f54df44

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

src/libcore/intrinsics.rs

-10
Original file line numberDiff line numberDiff line change
@@ -737,16 +737,6 @@ extern "rust-intrinsic" {
737737
///
738738
/// There are a few things that `transmute` is really useful for.
739739
///
740-
/// Getting the bitpattern of a floating point type (or, more generally,
741-
/// type punning, when `T` and `U` aren't pointers):
742-
///
743-
/// ```
744-
/// let bitpattern = unsafe {
745-
/// std::mem::transmute::<f32, u32>(1.0)
746-
/// };
747-
/// assert_eq!(bitpattern, 0x3F800000);
748-
/// ```
749-
///
750740
/// Turning a pointer into a function pointer. This is *not* portable to
751741
/// machines where function pointers and data pointers have different sizes.
752742
///

0 commit comments

Comments
 (0)