summaryrefslogtreecommitdiffstats
path: root/src/common
diff options
context:
space:
mode:
authorPaul Masurel <paul.masurel@gmail.com>2018-02-19 12:36:24 +0900
committerPaul Masurel <paul.masurel@gmail.com>2018-02-19 12:36:24 +0900
commit0540ebb49e048fa44d14be6e210f1c2736be1c8e (patch)
tree98e30c26e0ce30c7a21dca6d5db2ee179413e364 /src/common
parentef94582203178195fc512acc66e2e5f41688cb7e (diff)
Cargo clippy
Diffstat (limited to 'src/common')
-rw-r--r--src/common/bitset.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/bitset.rs b/src/common/bitset.rs
index 5284d65..c0edea2 100644
--- a/src/common/bitset.rs
+++ b/src/common/bitset.rs
@@ -51,7 +51,7 @@ impl TinySet {
/// within `[0; 64[`
#[inline(always)]
pub fn singleton(el: u32) -> TinySet {
- TinySet(1u64 << (el as u64))
+ TinySet(1u64 << u64::from(el))
}
/// Insert a new element within [0..64[
@@ -109,7 +109,7 @@ impl TinySet {
///
/// The limit is assumed to be strictly lower than 64.
pub fn range_lower(upper_bound: u32) -> TinySet {
- TinySet((1u64 << ((upper_bound % 64u32) as u64)) - 1u64)
+ TinySet((1u64 << u64::from(upper_bound % 64u32)) - 1u64)
}
/// Returns a `TinySet` that contains all values greater