Skip to content

Commit 5cbe9b5

Browse files
authored
Merge pull request #1686 from bkchr/fix_nightly_rust_compilation_error
Fixes compilation error with latest nightly rust
2 parents 6f2fe14 + 54affdf commit 5cbe9b5

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
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.125 — 2017-04-19
5+
* Update to *rustc 1.18.0-nightly (9f2abadca 2017-04-18)*
6+
47
## 0.0.124 — 2017-04-16
58
* Update to *rustc 1.18.0-nightly (d5cf1cb64 2017-04-15)*
69

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "clippy"
3-
version = "0.0.124"
3+
version = "0.0.125"
44
authors = [
55
"Manish Goregaokar <[email protected]>",
66
"Andre Bogus <[email protected]>",
@@ -30,7 +30,7 @@ test = false
3030

3131
[dependencies]
3232
# begin automatic update
33-
clippy_lints = { version = "0.0.124", path = "clippy_lints" }
33+
clippy_lints = { version = "0.0.125", path = "clippy_lints" }
3434
# end automatic update
3535
cargo_metadata = "0.1.1"
3636

clippy_lints/Cargo.toml

Lines changed: 1 addition & 1 deletion
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.124"
4+
version = "0.0.125"
55
# end automatic update
66
authors = [
77
"Manish Goregaokar <[email protected]>",

clippy_lints/src/enum_clike.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for UnportableVariant {
4444
let variant = &var.node;
4545
if let Some(body_id) = variant.disr_expr {
4646
use rustc_const_eval::*;
47-
let constcx = ConstContext::new(cx.tcx, body_id);
47+
let constcx = ConstContext::with_tables(cx.tcx, cx.tcx.body_tables(body_id));
4848
let bad = match constcx.eval(&cx.tcx.hir.body(body_id).value) {
4949
Ok(ConstVal::Integral(Usize(Us64(i)))) => i as u32 as u64 != i,
5050
Ok(ConstVal::Integral(Isize(Is64(i)))) => i as i32 as i64 != i,

0 commit comments

Comments
 (0)