Skip to content

Commit 513b467

Browse files
committed
Auto merge of rust-lang#5370 - phansch:matches, r=matthiaskrgr
Remove dependency on `matches` crate The std equivalent works exactly the same. changelog: none
2 parents 100a24d + cec1e8f commit 513b467

15 files changed

+0
-15
lines changed

clippy_lints/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ cargo_metadata = "0.9.0"
2121
if_chain = "1.0.0"
2222
itertools = "0.9"
2323
lazy_static = "1.0.2"
24-
matches = "0.1.7"
2524
pulldown-cmark = { version = "0.7", default-features = false }
2625
quine-mc_cluskey = "0.2.2"
2726
regex-syntax = "0.6"

clippy_lints/src/block_in_if_condition.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
use crate::utils::{differing_macro_contexts, higher, snippet_block_with_applicability, span_lint, span_lint_and_sugg};
2-
use matches::matches;
32
use rustc::hir::map::Map;
43
use rustc::lint::in_external_macro;
54
use rustc_errors::Applicability;

clippy_lints/src/eta_reduction.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
use if_chain::if_chain;
2-
use matches::matches;
32
use rustc::lint::in_external_macro;
43
use rustc::ty::{self, Ty};
54
use rustc_errors::Applicability;

clippy_lints/src/items_after_statements.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
//! lint when items are used after statements
22
33
use crate::utils::span_lint;
4-
use matches::matches;
54
use rustc_ast::ast::{Block, ItemKind, StmtKind};
65
use rustc_lint::{EarlyContext, EarlyLintPass};
76
use rustc_session::{declare_lint_pass, declare_tool_lint};

clippy_lints/src/lifetimes.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
use matches::matches;
21
use rustc::hir::map::Map;
32
use rustc::lint::in_external_macro;
43
use rustc_data_structures::fx::{FxHashMap, FxHashSet};

clippy_lints/src/methods/mod.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ use std::fmt;
88
use std::iter;
99

1010
use if_chain::if_chain;
11-
use matches::matches;
1211
use rustc::hir::map::Map;
1312
use rustc::lint::in_external_macro;
1413
use rustc::ty::{self, Predicate, Ty};

clippy_lints/src/misc.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
use if_chain::if_chain;
2-
use matches::matches;
32
use rustc::ty;
43
use rustc_ast::ast::LitKind;
54
use rustc_errors::Applicability;

clippy_lints/src/missing_const_for_fn.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ use rustc_mir::transform::qualify_min_const_fn::is_min_const_fn;
88
use rustc_session::{declare_lint_pass, declare_tool_lint};
99
use rustc_span::Span;
1010
use rustc_typeck::hir_ty_to_ty;
11-
use std::matches;
1211

1312
declare_clippy_lint! {
1413
/// **What it does:**

clippy_lints/src/mutable_debug_assertion.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
use crate::utils::{is_direct_expn_of, span_lint};
22
use if_chain::if_chain;
3-
use matches::matches;
43
use rustc::hir::map::Map;
54
use rustc::ty;
65
use rustc_hir::intravisit::{walk_expr, NestedVisitorMap, Visitor};

clippy_lints/src/needless_pass_by_value.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ use crate::utils::{
44
snippet, snippet_opt, span_lint_and_then,
55
};
66
use if_chain::if_chain;
7-
use matches::matches;
87
use rustc::ty::{self, TypeFoldable};
98
use rustc_ast::ast::Attribute;
109
use rustc_data_structures::fx::{FxHashMap, FxHashSet};

clippy_lints/src/redundant_clone.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ use crate::utils::{
33
span_lint_hir_and_then, walk_ptrs_ty_depth,
44
};
55
use if_chain::if_chain;
6-
use matches::matches;
76
use rustc::mir::{
87
self, traversal,
98
visit::{MutatingUseContext, NonMutatingUseContext, PlaceContext, Visitor as _},

clippy_lints/src/swap.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ use crate::utils::{
44
span_lint_and_then, walk_ptrs_ty, SpanlessEq,
55
};
66
use if_chain::if_chain;
7-
use matches::matches;
87
use rustc::ty;
98
use rustc_errors::Applicability;
109
use rustc_hir::{Block, Expr, ExprKind, PatKind, QPath, StmtKind};

clippy_lints/src/trivially_copy_pass_by_ref.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ use std::cmp;
22

33
use crate::utils::{is_copy, is_self_ty, snippet, span_lint_and_sugg};
44
use if_chain::if_chain;
5-
use matches::matches;
65
use rustc::ty;
76
use rustc_errors::Applicability;
87
use rustc_hir as hir;

clippy_lints/src/utils/mod.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ use std::borrow::Cow;
2525
use std::mem;
2626

2727
use if_chain::if_chain;
28-
use matches::matches;
2928
use rustc::hir::map::Map;
3029
use rustc::traits;
3130
use rustc::ty::{

clippy_lints/src/utils/sugg.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
#![deny(clippy::missing_docs_in_private_items)]
33

44
use crate::utils::{higher, snippet, snippet_opt, snippet_with_macro_callsite};
5-
use matches::matches;
65
use rustc_ast::util::parser::AssocOp;
76
use rustc_ast::{ast, token};
87
use rustc_ast_pretty::pprust::token_kind_to_string;

0 commit comments

Comments
 (0)