From owner-freebsd-chat@FreeBSD.ORG Wed Apr 15 01:02:03 2009 Return-Path: Delivered-To: freebsd-chat@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8274C10656CA for ; Wed, 15 Apr 2009 01:02:03 +0000 (UTC) (envelope-from dkelly@hiwaay.net) Received: from bee.hiwaay.net (bee.hiwaay.net [216.180.54.11]) by mx1.freebsd.org (Postfix) with ESMTP id 4A0288FC1F for ; Wed, 15 Apr 2009 01:02:03 +0000 (UTC) (envelope-from dkelly@hiwaay.net) Received: from [10.0.0.183] (dynamic-75-76-211-79.knology.net [75.76.211.79] (may be forged)) (authenticated bits=0) by bee.hiwaay.net (8.13.8/8.13.8) with ESMTP id n3F0nCBH1177715 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NO); Tue, 14 Apr 2009 19:49:13 -0500 (CDT) From: David Kelly To: deeptech71@gmail.com In-Reply-To: <49E51B42.2060405@gmail.com> References: <49E2FBE2.8020305@gmail.com> <20090413140912.GC29833@Grumpy.DynDNS.org> <49E51B42.2060405@gmail.com> Message-Id: <320BA0A7-C5E0-40E5-97F9-F19BF1C61B29@hiwaay.net> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v930.3) Date: Tue, 14 Apr 2009 19:49:11 -0500 X-Mailer: Apple Mail (2.930.3) Cc: freebsd-chat@freebsd.org Subject: Re: My whitespace style X-BeenThere: freebsd-chat@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-chat@freebsd.org List-Id: Non technical items related to the community List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Apr 2009 01:02:04 -0000 On Apr 14, 2009, at 6:24 PM, deeptech71@gmail.com wrote: > David Kelly wrote: >> On Mon, Apr 13, 2009 at 10:46:26AM +0200, deeptech71@gmail.com wrote: >>> Tabs are better, because they allow the programmer to specify the >>> desired width, and is dynamically changable at any time. >> Spaces are better because they let the author specify the >> formatting and >> not left to some other re-interpretation. > > And indeed they should used where formatting is important. However, > C/C++ indentation is not of this nature. It is if you want your comments to stay lined up, and code remain readable. There are many sections of code I write C in *columns*, especially when making repetitive calls to the same function with different arguments. I make the arguments line up in a column. printf() is a common example, that I want the arguments to line up no matter it has no effect on the output. I indent for readability and the result almost never survives variable tab interpretation. If I write the code and indent 3 or 4 or 8 spaces then by golly thats the way it should remain. If there is a project format spec then it should be written in .indent.pro and I will use it and make sure my code is readable after a pass through indent(1). This notion of tabs as a flexible indent is flawed. -- David Kelly N4HHE, dkelly@HiWAAY.net ======================================================================== Whom computers would destroy, they must first drive mad.