From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 97BDFC433E7 for ; Sun, 18 Oct 2020 20:19:29 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5D51C22276 for ; Sun, 18 Oct 2020 20:19:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727682AbgJRUT2 (ORCPT ); Sun, 18 Oct 2020 16:19:28 -0400 Received: from smtprelay0231.hostedemail.com ([216.40.44.231]:37566 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726422AbgJRUT1 (ORCPT ); Sun, 18 Oct 2020 16:19:27 -0400 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay02.hostedemail.com (Postfix) with ESMTP id 2A1F212D5; Sun, 18 Oct 2020 20:19:27 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-HE-Tag: test32_5216ff127231 X-Filterd-Recvd-Size: 1529 Received: from XPS-9350.home (unknown [47.151.133.149]) (Authenticated sender: joe@perches.com) by omf19.hostedemail.com (Postfix) with ESMTPA; Sun, 18 Oct 2020 20:19:26 +0000 (UTC) Message-ID: <49c87dede8d06ba90ecb3200b2a773860d61a3c8.camel@perches.com> Subject: Re: [PATCH] checkpatch: Allow --fix removal of unnecessary break statements From: Joe Perches To: Tom Rix , Andrew Morton Cc: Julia Lawall , linux-kernel@vger.kernel.org, cocci Date: Sun, 18 Oct 2020 13:19:24 -0700 In-Reply-To: References: <20201017160928.12698-1-trix@redhat.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.36.4-0ubuntu1 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 2020-10-18 at 13:07 -0700, Tom Rix wrote: > I like! [] > could add a '|break' here to catch the couple [] > break; > > break; Unfortunately, checkpatch is really stupid and it wouldn't catch those cases as there are blank lines between the existing consecutive break statements. It would catch break; break; but there aren't any of those so it seems unlikely to be a very useful addition.