Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 5afdf8b

Browse files
authoredOct 14, 2018
Merge pull request #3315 from rust-lang-nursery/oli-obk-patch-1
fix for rustc master
2 parents 1cb90cc + 212a4fe commit 5afdf8b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎clippy_lints/src/len_zero.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,7 @@ fn has_is_empty(cx: &LateContext<'_, '_>, expr: &Expr) -> bool {
276276
let ty = &walk_ptrs_ty(cx.tables.expr_ty(expr));
277277
match ty.sty {
278278
ty::Dynamic(ref tt, ..) => cx.tcx
279-
.associated_items(tt.principal().expect("trait impl not found").def_id())
279+
.associated_items(tt.principal().def_id())
280280
.any(|item| is_is_empty(cx, &item)),
281281
ty::Projection(ref proj) => has_is_empty_impl(cx, proj.item_def_id),
282282
ty::Adt(id, _) => has_is_empty_impl(cx, id.did),

0 commit comments

Comments
 (0)
Please sign in to comment.