aboutsummaryrefslogtreecommitdiffstats
path: root/components/script_plugins/unrooted_must_root.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/script_plugins/unrooted_must_root.rs')
-rw-r--r--components/script_plugins/unrooted_must_root.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/components/script_plugins/unrooted_must_root.rs b/components/script_plugins/unrooted_must_root.rs
index 1f05539490c..c4694b5e56a 100644
--- a/components/script_plugins/unrooted_must_root.rs
+++ b/components/script_plugins/unrooted_must_root.rs
@@ -121,7 +121,10 @@ 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_by_hir_id(cx.tcx.hir().get_parent_item(id)),
};
if item.attrs.iter().all(|a| !a.check_name("must_root")) {
for ref field in def.fields() {