about summary refs log tree commit diff
path: root/clippy_lints/src/new_without_default.rs
diff options
context:
space:
mode:
Diffstat (limited to 'clippy_lints/src/new_without_default.rs')
-rw-r--r--clippy_lints/src/new_without_default.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/clippy_lints/src/new_without_default.rs b/clippy_lints/src/new_without_default.rs
index cfd24e9b2d3..6017117e1ec 100644
--- a/clippy_lints/src/new_without_default.rs
+++ b/clippy_lints/src/new_without_default.rs
@@ -84,7 +84,7 @@ impl<'tcx> LateLintPass<'tcx> for NewWithoutDefault {
                             // can't be implemented for unsafe new
                             return;
                         }
-                        if cx.tcx.is_doc_hidden(impl_item.def_id) {
+                        if cx.tcx.is_doc_hidden(impl_item.def_id.def_id) {
                             // shouldn't be implemented when it is hidden in docs
                             return;
                         }
@@ -96,7 +96,7 @@ impl<'tcx> LateLintPass<'tcx> for NewWithoutDefault {
                         if_chain! {
                             if sig.decl.inputs.is_empty();
                             if name == sym::new;
-                            if cx.access_levels.is_reachable(impl_item.def_id);
+                            if cx.access_levels.is_reachable(impl_item.def_id.def_id);
                             let self_def_id = cx.tcx.hir().get_parent_item(id);
                             let self_ty = cx.tcx.type_of(self_def_id);
                             if self_ty == return_ty(cx, id);