Skip to content
This repository was archived by the owner on Apr 5, 2024. It is now read-only.

Commit 7c4da60

Browse files
committed
Auto merge of #269 - jdisanti:rustups-2022-02, r=JohnTitor
Update nightly toolchain Attempting to update the nightly toolchain version. I don't know what I'm getting into, but I'll try my best 😅 I understand there were CI issues with nightly-2021-10-15 in #227, but the logs are gone from that time. I will push each nightly upgrade as its own commit in this PR so we can see CI for each.
2 parents 459fbf1 + 5572ce6 commit 7c4da60

File tree

6 files changed

+13
-11
lines changed

6 files changed

+13
-11
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ repository and compiled from source or installed from
2727
of the nightly toolchain is supported at any given time.
2828

2929
<!-- NOTE: Keep in sync with nightly date on rust-toolchain. -->
30-
It's recommended to use `nightly-2021-09-30` toolchain.
31-
You can install it by using `rustup install nightly-2021-09-30` if you already have rustup.
30+
It's recommended to use `nightly-2021-10-25` toolchain.
31+
You can install it by using `rustup install nightly-2021-10-25` if you already have rustup.
3232
Then you can do:
3333

3434
```sh
35-
$ rustup component add rustc-dev llvm-tools-preview --toolchain nightly-2021-09-30
36-
$ cargo +nightly-2021-09-30 install --git https://github.com/rust-lang/rust-semverver
35+
$ rustup component add rustc-dev llvm-tools-preview --toolchain nightly-2021-10-25
36+
$ cargo +nightly-2021-10-25 install --git https://github.com/rust-lang/rust-semverver
3737
```
3838

3939
You'd also need `cmake` for some dependencies, and a few common libraries (if you hit

rust-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# NOTE: Keep in sync with nightly date on README
22
[toolchain]
3-
channel = "nightly-2021-09-30"
3+
channel = "nightly-2021-10-25"
44
components = ["llvm-tools-preview", "rustc-dev"]

src/translate.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -393,6 +393,7 @@ impl<'a, 'tcx> TranslationContext<'a, 'tcx> {
393393
substs: target_substs,
394394
},
395395
constness: pred.constness,
396+
polarity: pred.polarity,
396397
}
397398
} else {
398399
return None;

src/traverse.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ use crate::{
1717
typeck::{BoundContext, TypeComparisonContext},
1818
};
1919
use log::{debug, info};
20-
use rustc_const_eval::const_eval::is_const_fn;
2120
use rustc_hir::def::{CtorKind, CtorOf, DefKind, Res, Res::Def};
2221
use rustc_hir::def_id::DefId;
2322
use rustc_hir::hir_id::HirId;
@@ -363,8 +362,8 @@ fn diff_fn<'tcx>(changes: &mut ChangeSet, tcx: TyCtxt<'tcx>, old: Res, new: Res)
363362
let old_def_id = old.def_id();
364363
let new_def_id = new.def_id();
365364

366-
let old_const = is_const_fn(tcx, old_def_id);
367-
let new_const = is_const_fn(tcx, new_def_id);
365+
let old_const = tcx.is_const_fn(old_def_id);
366+
let new_const = tcx.is_const_fn(new_def_id);
368367

369368
if old_const != new_const {
370369
changes.add_change(

src/typeck.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ use rustc_middle::{
1818
error::TypeError,
1919
fold::TypeFoldable,
2020
subst::{GenericArg, InternalSubsts, SubstsRef},
21-
GenericParamDefKind, ParamEnv, Predicate, PredicateKind, TraitRef, Ty, TyCtxt,
21+
GenericParamDefKind, ImplPolarity, ParamEnv, Predicate, PredicateKind, TraitRef, Ty,
22+
TyCtxt,
2223
},
2324
};
2425
use rustc_trait_selection::traits::FulfillmentContext;
@@ -77,6 +78,7 @@ impl<'a, 'tcx> BoundContext<'a, 'tcx> {
7778
let predicate = ty::Binder::dummy(PredicateKind::Trait(TraitPredicate {
7879
trait_ref: checked_trait_ref,
7980
constness: BoundConstness::NotConst,
81+
polarity: ImplPolarity::Positive,
8082
}))
8183
.to_predicate(self.infcx.tcx);
8284
let obligation = Obligation::new(ObligationCause::dummy(), self.given_param_env, predicate);

tests/cases/pathologic_paths/stdout

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ warning: path changes to `a`
99
... |
1010
16 | | _ _ _ _ _ _ _ _
1111
17 | | _ _ _ _ _ _ _ _);
12-
| |_______________________^
12+
| |______________________^
1313
|
1414
= note: added definition (technically breaking)
1515
= note: this warning originates in the macro `blow` (in Nightly builds, run with -Z macro-backtrace for more info)
@@ -24,7 +24,7 @@ warning: path changes to `b`
2424
... |
2525
16 | | _ _ _ _ _ _ _ _
2626
17 | | _ _ _ _ _ _ _ _);
27-
| |_______________________^
27+
| |______________________^
2828
|
2929
= note: added definition (technically breaking)
3030
= note: this warning originates in the macro `blow` (in Nightly builds, run with -Z macro-backtrace for more info)

0 commit comments

Comments
 (0)