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=-0.8 required=3.0 tests=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 9C531C32753 for ; Thu, 15 Aug 2019 02:44:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 72ED320C01 for ; Thu, 15 Aug 2019 02:44:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729042AbfHOCoy (ORCPT ); Wed, 14 Aug 2019 22:44:54 -0400 Received: from smtprelay0126.hostedemail.com ([216.40.44.126]:39195 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726585AbfHOCox (ORCPT ); Wed, 14 Aug 2019 22:44:53 -0400 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay04.hostedemail.com (Postfix) with ESMTP id 35DF3180A7FA2; Thu, 15 Aug 2019 02:44:52 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-HE-Tag: move54_d38b8fd79e23 X-Filterd-Recvd-Size: 2898 Received: from XPS-9350 (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; Thu, 15 Aug 2019 02:44:50 +0000 (UTC) Message-ID: <128728a0965240aa5b68970d7721d857176ae7cd.camel@perches.com> Subject: Re: [PATCH] Makefile: Convert -Wimplicit-fallthrough=3 to just -Wimplicit-fallthrough for clang From: Joe Perches To: Miguel Ojeda , Nick Desaulniers Cc: Nathan Chancellor , Linus Torvalds , "Gustavo A. R. Silva" , LKML , clang-built-linux Date: Wed, 14 Aug 2019 19:44:49 -0700 In-Reply-To: References: <9c7a79b4d21aea52464d00c8fa4e4b92638560b6.camel@perches.com> <6a5f470c1375289908c37632572c4aa60d6486fa.camel@perches.com> <20190811020442.GA22736@archlinux-threadripper> <871efd6113ee2f6491410409511b871b7637f9e3.camel@perches.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.30.5-0ubuntu0.18.10.1 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 Tue, 2019-08-13 at 14:44 +0200, Miguel Ojeda wrote: > Hm... I would go for either __fallthrough as the rest of attributes, > or simply fallthrough -- FALLTHROUGH seems wrong. If you want it that > way for visibility, then I would choose __fallthrough, since the > underscores are quite prominent and anyway IDEs typically highlight > macros in a different color than keywords (return etc.). Just fyi: I added this line to my .emacs and "fallthrough" is now syntax highlighted like every other keyword. (font-lock-add-keywords 'c-mode '(("\\<\\(fallthrough\\)\\>" . font-lock-keyword-face))) So now my linux-c-mode block is: (defun linux-c-mode () "C mode with adjusted defaults for use with the Linux kernel." (interactive) (font-lock-add-keywords 'c-mode '(("\\<\\(fallthrough\\)\\>" . font-lock-keyword-face))) (c-mode) (c-set-style "K&R") (setq c-basic-offset 8) (setq c-indent-level 8) (setq c-brace-imaginary-offset 0) (setq c-brace-offset -8) (setq c-argdecl-indent 8) (setq c-label-offset -8) (setq c-continued-statement-offset 8) (setq indent-tabs-mode t) (setq tab-width 8) (setq show-trailing-whitespace t) ) I don't know to do that for vim nor any other ide, but I trust someone will know and show how it's done.