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=-11.1 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, NICE_REPLY_A,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=ham 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 9EBA7C433E7 for ; Mon, 19 Oct 2020 11:34:21 +0000 (UTC) Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D2F1E22257 for ; Mon, 19 Oct 2020 11:34:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=g001.emailsrvr.com header.i=@g001.emailsrvr.com header.b="D5nNsi9E"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=mev.co.uk header.i=@mev.co.uk header.b="AKRebitm" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D2F1E22257 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=mev.co.uk Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=driverdev-devel-bounces@linuxdriverproject.org Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 33480871EC; Mon, 19 Oct 2020 11:34:20 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id YGWrWjeovIvs; Mon, 19 Oct 2020 11:34:19 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 401D4871C9; Mon, 19 Oct 2020 11:34:19 +0000 (UTC) Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 74A251BF37F for ; Mon, 19 Oct 2020 11:34:18 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 6EE8D86CE6 for ; Mon, 19 Oct 2020 11:34:18 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cPSOlcTt63NE for ; Mon, 19 Oct 2020 11:34:17 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from smtp66.ord1c.emailsrvr.com (smtp66.ord1c.emailsrvr.com [108.166.43.66]) by whitealder.osuosl.org (Postfix) with ESMTPS id 6E371871C9 for ; Mon, 19 Oct 2020 11:34:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=g001.emailsrvr.com; s=20190322-9u7zjiwi; t=1603107256; bh=yBp9rr7OZNRF/u7GaFtOixl1IsNd9gKNYKczRfG2RCc=; h=Subject:To:From:Date:From; b=D5nNsi9EH/WEqFWYMIWqbDvk3ohHDgURKoDoiWXC1BlWQKUvDaOrWjGWrIybCjLAo dmh+wer8maGKT0HQTIHUT2HWbWLISmcho1p6I9lnpVJAYqRRQLbGIJt4SnWdlV8S51 ZXCr+QbXvGJYGhd92062NQ0SCQ0aHY5O+uuz7J6Y= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=mev.co.uk; s=20190130-41we5z8j; t=1603107256; bh=yBp9rr7OZNRF/u7GaFtOixl1IsNd9gKNYKczRfG2RCc=; h=Subject:To:From:Date:From; b=AKRebitmsSqOyDIduwAl0ccKH5BxQsiDmyE01D/oY58uxE43u7PQbM8cD7BOE1ls8 xUzwwUKhGLoehb7DJyU9viC21GUQkDQno0n6QPQ3eHSJmsKDMTbmv5KX//qjz1YOV8 PNzzLC3AXORgRIuZrdcdoDmpHK6FN6nALYpxfbOg= X-Auth-ID: abbotti@mev.co.uk Received: by smtp1.relay.ord1c.emailsrvr.com (Authenticated sender: abbotti-AT-mev.co.uk) with ESMTPSA id E7A9B2011A; Mon, 19 Oct 2020 07:34:15 -0400 (EDT) Subject: Re: [Outreachy kernel] Re: [PATCH 2/2] staging: comedi: combine split lines for improved readability To: Deepak R Varma , Julia Lawall References: <0fbce7fd820c72b6dd6dc8964d4bdaf433e39540.1603050372.git.mh12gx2825@gmail.com> <7c30530bad3aba50805fc6be39461e11c0580952.1603050372.git.mh12gx2825@gmail.com> <20201019105731.GB9681@ubuntu204> From: Ian Abbott Organization: MEV Ltd. Message-ID: <3bcf050c-97e4-666a-20fd-44585a913a8d@mev.co.uk> Date: Mon, 19 Oct 2020 12:34:15 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 MIME-Version: 1.0 In-Reply-To: <20201019105731.GB9681@ubuntu204> Content-Language: en-GB X-Classification-ID: eb7ae317-66c9-4ae4-a4f2-e696b587c4ac-1-1 X-BeenThere: driverdev-devel@linuxdriverproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Driver Project Developer List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devel@driverdev.osuosl.org, outreachy-kernel@googlegroups.com, Greg Kroah-Hartman Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: driverdev-devel-bounces@linuxdriverproject.org Sender: "devel" On 19/10/2020 11:57, Deepak R Varma wrote: > On Mon, Oct 19, 2020 at 12:41:14PM +0200, Julia Lawall wrote: >> >> >> On Mon, 19 Oct 2020, Ian Abbott wrote: >> >>> On 18/10/2020 20:49, Deepak R Varma wrote: >>>> Instructions split on multiple lines can be combined on a single line >>>> for improved readability of the code. >>>> >>>> Signed-off-by: Deepak R Varma >>>> --- >>>> .../staging/comedi/drivers/tests/ni_routes_test.c | 12 ++++-------- >>>> 1 file changed, 4 insertions(+), 8 deletions(-) >>>> >>>> diff --git a/drivers/staging/comedi/drivers/tests/ni_routes_test.c >>>> b/drivers/staging/comedi/drivers/tests/ni_routes_test.c >>>> index 7db83cf5e4aa..a3b1be623861 100644 >>>> --- a/drivers/staging/comedi/drivers/tests/ni_routes_test.c >>>> +++ b/drivers/staging/comedi/drivers/tests/ni_routes_test.c >>>> @@ -499,14 +499,10 @@ void test_route_register_is_valid(void) >>>> const struct ni_route_tables *T = &private.routing_tables; >>>> init_pci_fake(); >>>> - unittest(!route_register_is_valid(4, O(4), T), >>>> - "check for bad source 4-->4\n"); >>>> - unittest(!route_register_is_valid(0, O(1), T), >>>> - "find first source\n"); >>>> - unittest(!route_register_is_valid(4, O(6), T), >>>> - "find middle source\n"); >>>> - unittest(!route_register_is_valid(9, O(8), T), >>>> - "find last source"); >>>> + unittest(!route_register_is_valid(4, O(4), T), "check for bad source >>>> 4-->4\n"); >>>> + unittest(!route_register_is_valid(0, O(1), T), "find first source\n"); >>>> + unittest(!route_register_is_valid(4, O(6), T), "find middle >>>> source\n"); >>>> + unittest(!route_register_is_valid(9, O(8), T), "find last source"); >>>> } >>>> void test_ni_check_trigger_arg(void) >>>> >>> >>> Is it worth breaking the 80-column limit for this? >> >> Deepak, >> >> It was much nicer before. >> >> It can be awkward to break eg a + operation at the 80 character limit. >> But function argument stand by themselves. >> >> julia >> > > Hi Julia and Ian, > I wanted to take advantage of the relaxation of 80 column limit to 100 > columns and hence proposed combining the lines. Are you saying this is > allowed only in certain cases? > > Please confirm and I will handle it accordingly. Hi Deepak, 80 columns is still the preferred limit. I think the relaxation is mostly to avoid the need to split sub-expressions across lines in really ugly ways to keep within the 80 columns at the expense of readability. -- -=( Ian Abbott || MEV Ltd. is a company )=- -=( registered in England & Wales. Regd. number: 02862268. )=- -=( Regd. addr.: S11 & 12 Building 67, Europa Business Park, )=- -=( Bird Hall Lane, STOCKPORT, SK3 0XA, UK. || www.mev.co.uk )=- _______________________________________________ devel mailing list devel@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel