From 998896c036cca6ed984f39fe28bb867055432167 Mon Sep 17 00:00:00 2001 From: Tobias Bucher Date: Tue, 26 Feb 2019 16:10:28 +0100 Subject: [PATCH] Clarify `rotate_{left,right}` docs I wondered what the `<>`! +Please note this isn't the same operation as the `>>` shifting operator! # Examples @@ -2300,7 +2300,7 @@ assert_eq!(n.trailing_zeros(), 3);", $EndFeature, " concat!("Shifts the bits to the left by a specified amount, `n`, wrapping the truncated bits to the end of the resulting integer. -Please note this isn't the same operation as `<<`! +Please note this isn't the same operation as the `<<` shifting operator! # Examples @@ -2324,7 +2324,7 @@ assert_eq!(n.rotate_left(", $rot, "), m); wrapping the truncated bits to the beginning of the resulting integer. -Please note this isn't the same operation as `>>`! +Please note this isn't the same operation as the `>>` shifting operator! # Examples diff --git a/src/libcore/num/wrapping.rs b/src/libcore/num/wrapping.rs index 50e189c9e3640..9cd5108ade411 100644 --- a/src/libcore/num/wrapping.rs +++ b/src/libcore/num/wrapping.rs @@ -429,7 +429,8 @@ assert_eq!(n.trailing_zeros(), 3); /// wrapping the truncated bits to the end of the resulting /// integer. /// - /// Please note this isn't the same operation as `>>`! + /// Please note this isn't the same operation as the `>>` shifting + /// operator! /// /// # Examples /// @@ -454,7 +455,8 @@ assert_eq!(n.trailing_zeros(), 3); /// wrapping the truncated bits to the beginning of the resulting /// integer. /// - /// Please note this isn't the same operation as `<<`! + /// Please note this isn't the same operation as the `<<` shifting + /// operator! /// /// # Examples ///