mirror of
https://github.com/servo/servo.git
synced 2025-06-20 23:28:59 +01:00
Upgrade to rustc 1.40.0-nightly (084beb83e 2019-09-27)
This commit is contained in:
parent
b0b01b86b8
commit
5b935a60a5
3 changed files with 5 additions and 5 deletions
|
@ -151,7 +151,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for UnrootedPass {
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if let hir::ItemKind::Struct(def, ..) = &item.node {
|
if let hir::ItemKind::Struct(def, ..) = &item.kind {
|
||||||
for ref field in def.fields() {
|
for ref field in def.fields() {
|
||||||
let def_id = cx.tcx.hir().local_def_id(field.hir_id);
|
let def_id = cx.tcx.hir().local_def_id(field.hir_id);
|
||||||
if is_unrooted_ty(&self.symbols, cx, cx.tcx.type_of(def_id), false) {
|
if is_unrooted_ty(&self.symbols, cx, cx.tcx.type_of(def_id), false) {
|
||||||
|
@ -257,7 +257,7 @@ impl<'a, 'b, 'tcx> visit::Visitor<'tcx> for FnDefVisitor<'a, 'b, 'tcx> {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
match expr.node {
|
match expr.kind {
|
||||||
// Trait casts from #[must_root] types are not allowed
|
// Trait casts from #[must_root] types are not allowed
|
||||||
ExprKind::Cast(ref subexpr, _) => require_rooted(cx, self.in_new_function, &*subexpr),
|
ExprKind::Cast(ref subexpr, _) => require_rooted(cx, self.in_new_function, &*subexpr),
|
||||||
// This catches assignments... the main point of this would be to catch mutable
|
// This catches assignments... the main point of this would be to catch mutable
|
||||||
|
@ -286,7 +286,7 @@ impl<'a, 'b, 'tcx> visit::Visitor<'tcx> for FnDefVisitor<'a, 'b, 'tcx> {
|
||||||
// When "default binding modes" https://github.com/rust-lang/rust/issues/42640
|
// When "default binding modes" https://github.com/rust-lang/rust/issues/42640
|
||||||
// are implemented, the `Unannotated` case could cause false-positives.
|
// are implemented, the `Unannotated` case could cause false-positives.
|
||||||
// These should be fixable by adding an explicit `ref`.
|
// These should be fixable by adding an explicit `ref`.
|
||||||
match pat.node {
|
match pat.kind {
|
||||||
hir::PatKind::Binding(hir::BindingAnnotation::Unannotated, ..) |
|
hir::PatKind::Binding(hir::BindingAnnotation::Unannotated, ..) |
|
||||||
hir::PatKind::Binding(hir::BindingAnnotation::Mutable, ..) => {
|
hir::PatKind::Binding(hir::BindingAnnotation::Mutable, ..) => {
|
||||||
let ty = cx.tables.pat_ty(pat);
|
let ty = cx.tables.pat_ty(pat);
|
||||||
|
|
|
@ -177,7 +177,7 @@ impl LintPass for WebIdlPass {
|
||||||
|
|
||||||
impl<'a, 'tcx> LateLintPass<'a, 'tcx> for WebIdlPass {
|
impl<'a, 'tcx> LateLintPass<'a, 'tcx> for WebIdlPass {
|
||||||
fn check_item(&mut self, cx: &LateContext<'a, 'tcx>, item: &'tcx hir::Item) {
|
fn check_item(&mut self, cx: &LateContext<'a, 'tcx>, item: &'tcx hir::Item) {
|
||||||
let def = match &item.node {
|
let def = match &item.kind {
|
||||||
hir::ItemKind::Struct(def, ..) => def,
|
hir::ItemKind::Struct(def, ..) => def,
|
||||||
_ => return,
|
_ => return,
|
||||||
};
|
};
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
nightly-2019-09-27
|
nightly-2019-09-28
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue