diff --git a/CHANGELOG.md b/CHANGELOG.md index c766a8c5123..25fcaf9d2da 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ # Change Log All notable changes to this project will be documented in this file. +## 0.0.174 +* Rustup to *rustc 1.23.0-nightly (63739ab7b 2017-11-21)* + ## 0.0.173 * Rustup to *rustc 1.23.0-nightly (33374fa9d 2017-11-20)* diff --git a/Cargo.toml b/Cargo.toml index 5afd8a1cb57..7bdb619e8d0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "clippy" -version = "0.0.173" +version = "0.0.174" authors = [ "Manish Goregaokar ", "Andre Bogus ", @@ -37,7 +37,7 @@ path = "src/driver.rs" [dependencies] # begin automatic update -clippy_lints = { version = "0.0.173", path = "clippy_lints" } +clippy_lints = { version = "0.0.174", path = "clippy_lints" } # end automatic update cargo_metadata = "0.2" regex = "0.2" diff --git a/clippy_lints/Cargo.toml b/clippy_lints/Cargo.toml index a670e8c232e..4c88cc0c071 100644 --- a/clippy_lints/Cargo.toml +++ b/clippy_lints/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "clippy_lints" # begin automatic update -version = "0.0.173" +version = "0.0.174" # end automatic update authors = [ "Manish Goregaokar ", diff --git a/clippy_lints/src/lifetimes.rs b/clippy_lints/src/lifetimes.rs index 90c532f0746..280e504d88e 100644 --- a/clippy_lints/src/lifetimes.rs +++ b/clippy_lints/src/lifetimes.rs @@ -325,8 +325,14 @@ impl<'a, 'tcx> Visitor<'tcx> for RefVisitor<'a, 'tcx> { TyPath(ref path) => { self.collect_anonymous_lifetimes(path, ty); }, - TyImplTraitExistential(ref param_bounds) | - TyImplTraitUniversal(_, ref param_bounds) => for bound in param_bounds { + TyImplTraitExistential(ref exist_ty, _) => { + for bound in &exist_ty.bounds { + if let RegionTyParamBound(_) = *bound { + self.record(&None); + } + } + } + TyImplTraitUniversal(_, ref param_bounds) => for bound in param_bounds { if let RegionTyParamBound(_) = *bound { self.record(&None); } diff --git a/tests/ui/fallible_impl_from.stderr b/tests/ui/fallible_impl_from.stderr index 89dfaf623ed..448a1fe0559 100644 --- a/tests/ui/fallible_impl_from.stderr +++ b/tests/ui/fallible_impl_from.stderr @@ -38,7 +38,7 @@ note: potential failure(s) | 31 | panic!(); | ^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: consider implementing `TryFrom` instead --> $DIR/fallible_impl_from.rs:37:1 @@ -65,7 +65,7 @@ note: potential failure(s) | ^^^^^^^^^^^^^^^^^^^^^^^^^ 43 | panic!("{:?}", s); | ^^^^^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: consider implementing `TryFrom` instead --> $DIR/fallible_impl_from.rs:55:1 @@ -87,5 +87,5 @@ note: potential failure(s) | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 58 | panic!("{:?}", s); | ^^^^^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) diff --git a/tests/ui/matches.stderr b/tests/ui/matches.stderr index e44a4dd7894..8ddb12b653c 100644 --- a/tests/ui/matches.stderr +++ b/tests/ui/matches.stderr @@ -264,7 +264,7 @@ note: consider refactoring into `Ok(3) | Ok(_)` | 238 | Ok(3) => println!("ok"), | ^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: Err(_) will match all errors, maybe not a good idea --> $DIR/matches.rs:246:9 @@ -290,7 +290,7 @@ note: consider refactoring into `Ok(3) | Ok(_)` | 244 | Ok(3) => println!("ok"), | ^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: Err(_) will match all errors, maybe not a good idea --> $DIR/matches.rs:252:9 @@ -316,7 +316,7 @@ note: consider refactoring into `Ok(3) | Ok(_)` | 250 | Ok(3) => println!("ok"), | ^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: this `match` has identical arm bodies --> $DIR/matches.rs:258:18 @@ -334,7 +334,7 @@ note: consider refactoring into `Ok(3) | Ok(_)` | 257 | Ok(3) => println!("ok"), | ^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: this `match` has identical arm bodies --> $DIR/matches.rs:265:18 @@ -352,7 +352,7 @@ note: consider refactoring into `Ok(3) | Ok(_)` | 264 | Ok(3) => println!("ok"), | ^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: this `match` has identical arm bodies --> $DIR/matches.rs:271:18 @@ -370,7 +370,7 @@ note: consider refactoring into `Ok(3) | Ok(_)` | 270 | Ok(3) => println!("ok"), | ^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: this `match` has identical arm bodies --> $DIR/matches.rs:277:18 @@ -388,5 +388,5 @@ note: consider refactoring into `Ok(3) | Ok(_)` | 276 | Ok(3) => println!("ok"), | ^^^^^^^^^^^^^^ - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) diff --git a/tests/ui/unused_io_amount.stderr b/tests/ui/unused_io_amount.stderr index 8739ac245a7..0ec8615a010 100644 --- a/tests/ui/unused_io_amount.stderr +++ b/tests/ui/unused_io_amount.stderr @@ -5,7 +5,7 @@ error: handle written amount returned or use `Write::write_all` instead | ^^^^^^^^^^^^^^^^^^^^^^^ | = note: `-D unused-io-amount` implied by `-D warnings` - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: handle read amount returned or use `Read::read_exact` instead --> $DIR/unused_io_amount.rs:13:5 @@ -13,7 +13,7 @@ error: handle read amount returned or use `Read::read_exact` instead 13 | try!(s.read(&mut buf)); | ^^^^^^^^^^^^^^^^^^^^^^^ | - = note: this error originates in a macro outside of the current crate + = note: this error originates in a macro outside of the current crate (run with -Z external-macro-backtrace for more info) error: handle written amount returned or use `Write::write_all` instead --> $DIR/unused_io_amount.rs:18:5