From 655aef7c6c1469ab647185b570b1689bb9417815 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Kr=C3=BCger?= Date: Thu, 23 May 2019 17:23:59 +0200 Subject: [PATCH] update if_chain to 1.0.0 --- clippy_lints/Cargo.toml | 2 +- clippy_lints/src/consts.rs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/clippy_lints/Cargo.toml b/clippy_lints/Cargo.toml index 20b3a3e4937d..42e92bc1c794 100644 --- a/clippy_lints/Cargo.toml +++ b/clippy_lints/Cargo.toml @@ -29,7 +29,7 @@ toml = "0.5" unicode-normalization = "0.1" pulldown-cmark = "0.5.0" url = "1.7.0" -if_chain = "0.1.3" +if_chain = "1.0.0" smallvec = { version = "0.6.5", features = ["union"] } [features] diff --git a/clippy_lints/src/consts.rs b/clippy_lints/src/consts.rs index cbc10768bbc1..16f1f1cab19d 100644 --- a/clippy_lints/src/consts.rs +++ b/clippy_lints/src/consts.rs @@ -251,7 +251,8 @@ pub fn expr(&mut self, e: &Expr) -> Option { if let ExprKind::Path(qpath) = &callee.node; let res = self.tables.qpath_res(qpath, callee.hir_id); if let Some(def_id) = res.opt_def_id(); - let def_path = self.lcx.get_def_path(def_id) + let get_def_path = self.lcx.get_def_path(def_id); + let def_path = get_def_path .iter() .map(LocalInternedString::get) .collect::>();