mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-10 15:14:29 +00:00
rustup
This commit is contained in:
parent
433c834897
commit
b7ecb6e7c7
2 changed files with 2 additions and 2 deletions
|
@ -3,7 +3,7 @@ use syntax::ast;
|
|||
use syntax::ast::*;
|
||||
use syntax::visit::{FnKind};
|
||||
use rustc::lint::{Context, LintPass, LintArray, Lint, Level};
|
||||
use rustc::middle::ty::{mod, expr_ty, ty_str, ty_ptr, ty_rptr};
|
||||
use rustc::middle::ty::{self, expr_ty, ty_str, ty_ptr, ty_rptr};
|
||||
use syntax::codemap::Span;
|
||||
|
||||
use types::span_note_and_lint;
|
||||
|
|
|
@ -57,7 +57,7 @@ impl LintPass for TypePass {
|
|||
use std::boxed::Box;
|
||||
use std::vec::Vec;
|
||||
}
|
||||
match_ty_unwrap(ty, &["std", "boxed", "Box"]).and_then(|t| t.head())
|
||||
match_ty_unwrap(ty, &["std", "boxed", "Box"]).and_then(|t| t.first())
|
||||
.map(|t| match_ty_unwrap(&**t, &["std", "vec", "Vec"]))
|
||||
.map(|_| {
|
||||
span_note_and_lint(cx, BOX_VEC, ty.span,
|
||||
|
|
Loading…
Reference in a new issue