Don't import primitive type modules

This commit is contained in:
Linus Färnstrand 2020-04-07 23:44:24 +02:00
parent 51bb1d28c5
commit 518568ae0a
2 changed files with 1 additions and 3 deletions

View file

@ -6,7 +6,7 @@ use rustc_hir as hir;
use rustc_lint::{LateContext, LateLintPass};
use rustc_middle::ty;
use rustc_session::{declare_lint_pass, declare_tool_lint};
use std::{f32, f64, fmt};
use std::fmt;
declare_clippy_lint! {
/// **What it does:** Checks for float literals with a precision greater

View file

@ -1973,8 +1973,6 @@ impl Ord for FullInt {
}
fn numeric_cast_precast_bounds<'a>(cx: &LateContext<'_, '_>, expr: &'a Expr<'_>) -> Option<(FullInt, FullInt)> {
use std::{i128, i16, i32, i64, i8, isize, u128, u16, u32, u64, u8, usize};
if let ExprKind::Cast(ref cast_exp, _) = expr.kind {
let pre_cast_ty = cx.tables.expr_ty(cast_exp);
let cast_ty = cx.tables.expr_ty(expr);