Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754671AbXEAPIs (ORCPT ); Tue, 1 May 2007 11:08:48 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754710AbXEAPIm (ORCPT ); Tue, 1 May 2007 11:08:42 -0400 Received: from rgminet01.oracle.com ([148.87.113.118]:63307 "EHLO rgminet01.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754671AbXEAPIY (ORCPT ); Tue, 1 May 2007 11:08:24 -0400 Date: Tue, 1 May 2007 08:05:44 -0700 From: Randy Dunlap To: David Woodhouse Cc: Geert Uytterhoeven , Satyam Sharma , Andrew Morton , Christoph Hellwig , Roland McGrath , Christoph Hellwig , linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org Subject: Re: condingstyle, was Re: utrace comments Message-Id: <20070501080544.459a6ec9.randy.dunlap@oracle.com> In-Reply-To: <1178028973.2875.78.camel@pmac.infradead.org> References: <20061127165138.GA2991@lst.de> <20070430040213.BF9901801A4@magilla.sf.frob.com> <20070430091121.GC31397@infradead.org> <20070430100917.439ebfc8.akpm@linux-foundation.org> <1178028973.2875.78.camel@pmac.infradead.org> Organization: Oracle Linux Eng. X-Mailer: Sylpheed 2.3.1 (GTK+ 2.8.10; x86_64-unknown-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Whitelist: TRUE X-Whitelist: TRUE X-Brightmail-Tracker: AAAAAQAAAAI= Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1444 Lines: 39 On Tue, 01 May 2007 15:16:13 +0100 David Woodhouse wrote: > On Tue, 2007-05-01 at 11:00 +0200, Geert Uytterhoeven wrote: > > > > if (veryverylengthycondition1 && > > smallcond2 && > > (conditionnumber3a || > > condition3b)) { > > ... > > } > > It's horrid. I'd much rather see > > if (veryverylengthycondition1 && > smallcond2 && > (conditionnumber3a || condition3b)) { > ... > } > > Even if that does take it over 80 columns, the 'failure' mode will be > that it gets wrapped round to the beginning of the screen or truncated > at 80 columns -- and for the _majority_ of the time, it doesn't matter. > > Unless you're paying particular attention to the logic and debugging the > statement, a 'high-level' view of what's going on is perfectly > sufficient; you don't actually read every character anyway. I prefer this format also, but I'm not sure that we can get it into CodingStyle. CodingStyle is about (either) concensus or dictum, but I don't see us close to concensus... --- ~Randy *** Remember to use Documentation/SubmitChecklist when testing your code *** - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/