Skip to content

Commit c6a4eae

Browse files
committed
Rustup
1 parent b464432 commit c6a4eae

File tree

4 files changed

+9
-7
lines changed

4 files changed

+9
-7
lines changed

CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
# Change Log
22
All notable changes to this project will be documented in this file.
33

4+
## 0.0.171
5+
* Rustup to *rustc 1.23.0-nightly (ff0f5de3b 2017-11-14)*
6+
47
## 0.0.170
58
* Rustup to *rustc 1.23.0-nightly (d6b06c63a 2017-11-09)*
69

Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "clippy"
3-
version = "0.0.170"
3+
version = "0.0.171"
44
authors = [
55
"Manish Goregaokar <[email protected]>",
66
"Andre Bogus <[email protected]>",
@@ -37,7 +37,7 @@ path = "src/driver.rs"
3737

3838
[dependencies]
3939
# begin automatic update
40-
clippy_lints = { version = "0.0.170", path = "clippy_lints" }
40+
clippy_lints = { version = "0.0.171", path = "clippy_lints" }
4141
# end automatic update
4242
cargo_metadata = "0.2"
4343
regex = "0.2"

clippy_lints/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "clippy_lints"
33
# begin automatic update
4-
version = "0.0.170"
4+
version = "0.0.171"
55
# end automatic update
66
authors = [
77
"Manish Goregaokar <[email protected]>",

clippy_lints/src/utils/mod.rs

+3-4
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ use rustc::lint::{LateContext, Level, Lint, LintContext};
99
use rustc::session::Session;
1010
use rustc::traits;
1111
use rustc::ty::{self, Ty, TyCtxt};
12-
use rustc::mir::transform::MirSource;
1312
use rustc_errors;
1413
use std::borrow::Cow;
1514
use std::env;
@@ -48,9 +47,9 @@ pub fn differing_macro_contexts(lhs: Span, rhs: Span) -> bool {
4847

4948
pub fn in_constant(cx: &LateContext, id: NodeId) -> bool {
5049
let parent_id = cx.tcx.hir.get_parent(id);
51-
match MirSource::from_node(cx.tcx, parent_id) {
52-
MirSource::GeneratorDrop(_) | MirSource::Fn(_) => false,
53-
MirSource::Const(_) | MirSource::Static(..) | MirSource::Promoted(..) => true,
50+
match cx.tcx.hir.body_owner_kind(parent_id) {
51+
hir::BodyOwnerKind::Fn => false,
52+
hir::BodyOwnerKind::Const | hir::BodyOwnerKind::Static(..) => true,
5453
}
5554
}
5655

0 commit comments

Comments
 (0)