Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp5094769yba; Wed, 8 May 2019 07:49:30 -0700 (PDT) X-Google-Smtp-Source: APXvYqzYXwLegnk3Ac2/AMV1goVtqdOsopxitZuDIN79DGbhWa4ENSKreEh7JhJ8JoyJmx7585+7 X-Received: by 2002:a63:6ac3:: with SMTP id f186mr46827339pgc.326.1557326970804; Wed, 08 May 2019 07:49:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557326970; cv=none; d=google.com; s=arc-20160816; b=A62i3AtZEpP2R7AIhhaldvT+l3UeCHNkQnc6GfbYSZBDDzYQVfoGmkuAGhO9d9QX/r UelTIspda3rt/lZKJP1JfzGKBUs5fIi0B/91XDji8nJZhEinph+BMpTeCQ428q6hemJS i0smJjd0OoUy518U5eNcNWXacb+6fc8c9sUL3lGl4UmpXp/1SxJbM7KPng4yQFjDWjXU 2GdZQgv7+m++hfy6ru+Hn5W3sZ2Ucg5xMYsooCxgKc0tPDMZy+WmLXPWWP/nmdqGVxX5 iHMpmvQgFHGGp4FNSjhFc8Kx/7ZQC4fGXAAktDi77GF1u3mxsi5jAPt8+3D43EmjzY1q d+Jg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=gwvBAF8Z3L0P1GpjvNNb0rwFjWf/KqC2uy374nPqVoA=; b=rrQDz0vC3HtzdZ6MiSWNNdaEgpf7Pk358V92C+sZnrR6bd3iFaJylPvpVR7R8VnE20 3O87XKT/E7g4Qs9VuxP4iXmp2Ge678IMF6QaYYZaVhut+mbHlLx1GuvOLJSGEz2ZOzq2 vPV9I4YcV7tFR2LqfWms91pNx/JFyJjX1fMcg5jW1MNOZjpBRbseRJJTftmveqA1N4lX MgnTtmlvo+T9u8BPcKtH804/kE1EFINTdZxthNHpm9XV1qHG3sTZupYrWiIMsQ8qiZpG glYYNnMU30Vq1Apm7xE9zDHVH5lg/vb9MnJMj5kzMrTKYTLrfjzTEpqazQO3aM98hH8R hZlQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f34si22788264pgb.49.2019.05.08.07.49.14; Wed, 08 May 2019 07:49:30 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727794AbfEHOTe (ORCPT + 99 others); Wed, 8 May 2019 10:19:34 -0400 Received: from smtprelay0232.hostedemail.com ([216.40.44.232]:47807 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726515AbfEHOTe (ORCPT ); Wed, 8 May 2019 10:19:34 -0400 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay04.hostedemail.com (Postfix) with ESMTP id CAE7F180A885B; Wed, 8 May 2019 14:19:32 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::,RULES_HIT:41:355:379:599:982:988:989:1260:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1540:1593:1594:1711:1730:1747:1777:1792:2393:2559:2562:2693:2828:3138:3139:3140:3141:3142:3352:3622:3865:3866:3867:3870:3871:3874:4321:5007:7903:10004:10400:10848:11232:11658:11914:12296:12740:12760:12895:13069:13311:13357:13439:14181:14659:21080:21451:21627:30054:30091,0,RBL:23.242.196.136:@perches.com:.lbl8.mailshell.net-62.8.0.180 64.201.201.201,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:neutral,Custom_rules:0:0:0,LFtime:32,LUA_SUMMARY:none X-HE-Tag: slip08_190566b4c9f11 X-Filterd-Recvd-Size: 1834 Received: from XPS-9350.home (cpe-23-242-196-136.socal.res.rr.com [23.242.196.136]) (Authenticated sender: joe@perches.com) by omf08.hostedemail.com (Postfix) with ESMTPA; Wed, 8 May 2019 14:19:31 +0000 (UTC) Message-ID: Subject: Re: [PATCH 2/4] checkpatch: add --fix for warning LINE_CONTINUATIONS From: Joe Perches To: Antonio Borneo , Andy Whitcroft Cc: linux-kernel@vger.kernel.org Date: Wed, 08 May 2019 07:19:29 -0700 In-Reply-To: <20190508122721.7513-2-borneo.antonio@gmail.com> References: <20190508122721.7513-1-borneo.antonio@gmail.com> <20190508122721.7513-2-borneo.antonio@gmail.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.30.1-1build1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2019-05-08 at 14:27 +0200, Antonio Borneo wrote: > The warning LINE_CONTINUATIONS does not offer a --fix. > > Add the trivial --fix. > In case of consecutive lines with the same issue, this will > fix only the first line. [] > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl [] > @@ -5207,8 +5207,11 @@ sub process { > $line !~ /^\+\s*\#.*\\$/ && # preprocessor > $line !~ /^\+.*\b(__asm__|asm)\b.*\\$/ && # asm > $line =~ /^\+.*\\$/) { > - WARN("LINE_CONTINUATIONS", > - "Avoid unnecessary line continuations\n" . $herecurr); > + if (WARN("LINE_CONTINUATIONS", > + "Avoid unnecessary line continuations\n" . $herecurr) && I prefer to not apply this. Problem here is that these should generally be fixed by hand as the automated fix isn't very good style either. > + $fix) { > + $fixed[$fixlinenr] =~ s/\s*\\$//; > + } > } > } >