mirror of
https://github.com/servo/servo.git
synced 2025-08-02 20:20:14 +01:00
Upgrade to rustc 1.37.0-nightly (04a3dd8a8 2019-06-18)
This commit is contained in:
parent
97ad913dc2
commit
112f1ddeba
3 changed files with 4 additions and 10 deletions
|
@ -153,10 +153,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for UnrootedPass {
|
|||
) {
|
||||
let item = match cx.tcx.hir().get_by_hir_id(id) {
|
||||
hir::Node::Item(item) => item,
|
||||
_ => cx
|
||||
.tcx
|
||||
.hir()
|
||||
.expect_item_by_hir_id(cx.tcx.hir().get_parent_item(id)),
|
||||
_ => cx.tcx.hir().expect_item(cx.tcx.hir().get_parent_item(id)),
|
||||
};
|
||||
if item
|
||||
.attrs
|
||||
|
@ -177,7 +174,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for UnrootedPass {
|
|||
fn check_variant(&mut self, cx: &LateContext, var: &hir::Variant, _gen: &hir::Generics) {
|
||||
let ref map = cx.tcx.hir();
|
||||
if map
|
||||
.expect_item_by_hir_id(map.get_parent_item(var.node.id))
|
||||
.expect_item(map.get_parent_item(var.node.id))
|
||||
.attrs
|
||||
.iter()
|
||||
.all(|a| !a.check_name(self.symbols.must_root))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue