@@ -38,10 +38,10 @@ declare_lint_pass!(ByteCount => [NAIVE_BYTECOUNT]);
38
38
impl < ' a , ' tcx > LateLintPass < ' a , ' tcx > for ByteCount {
39
39
fn check_expr ( & mut self , cx : & LateContext < ' _ , ' _ > , expr : & Expr < ' _ > ) {
40
40
if_chain ! {
41
- if let ExprKind :: MethodCall ( ref count, _, ref count_args) = expr. kind;
41
+ if let ExprKind :: MethodCall ( ref count, _, ref count_args, _ ) = expr. kind;
42
42
if count. ident. name == sym!( count) ;
43
43
if count_args. len( ) == 1 ;
44
- if let ExprKind :: MethodCall ( ref filter, _, ref filter_args) = count_args[ 0 ] . kind;
44
+ if let ExprKind :: MethodCall ( ref filter, _, ref filter_args, _ ) = count_args[ 0 ] . kind;
45
45
if filter. ident. name == sym!( filter) ;
46
46
if filter_args. len( ) == 2 ;
47
47
if let ExprKind :: Closure ( _, _, body_id, _, _) = filter_args[ 1 ] . kind;
@@ -66,7 +66,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for ByteCount {
66
66
if ty:: Uint ( UintTy :: U8 ) != walk_ptrs_ty( cx. tables. expr_ty( needle) ) . kind {
67
67
return ;
68
68
}
69
- let haystack = if let ExprKind :: MethodCall ( ref path, _, ref args) =
69
+ let haystack = if let ExprKind :: MethodCall ( ref path, _, ref args, _ ) =
70
70
filter_args[ 0 ] . kind {
71
71
let p = path. ident. name;
72
72
if ( p == sym!( iter) || p == sym!( iter_mut) ) && args. len( ) == 1 {
0 commit comments