Skip to content

Commit a4eff9d

Browse files
authored
Rollup merge of rust-lang#136164 - celinval:chores-fnkind, r=oli-obk
Refactor FnKind variant to hold &Fn Pulling the change suggested in rust-lang#128045 to reduce the impact of changing `Fn` item. r? `@oli-obk`
2 parents e84c8b8 + d7874f4 commit a4eff9d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: clippy_lints/src/multiple_bound_locations.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use rustc_ast::visit::FnKind;
2-
use rustc_ast::{NodeId, WherePredicateKind};
2+
use rustc_ast::{Fn, NodeId, WherePredicateKind};
33
use rustc_data_structures::fx::FxHashMap;
44
use rustc_lint::{EarlyContext, EarlyLintPass};
55
use rustc_session::declare_lint_pass;
@@ -39,7 +39,7 @@ declare_lint_pass!(MultipleBoundLocations => [MULTIPLE_BOUND_LOCATIONS]);
3939

4040
impl EarlyLintPass for MultipleBoundLocations {
4141
fn check_fn(&mut self, cx: &EarlyContext<'_>, kind: FnKind<'_>, _: Span, _: NodeId) {
42-
if let FnKind::Fn(_, _, _, _, generics, _) = kind
42+
if let FnKind::Fn(_, _, _, Fn { generics, .. }) = kind
4343
&& !generics.params.is_empty()
4444
&& !generics.where_clause.predicates.is_empty()
4545
{

0 commit comments

Comments
 (0)