From owner-freebsd-chat Sat Feb 24 5:34:10 2001 Delivered-To: freebsd-chat@freebsd.org Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by hub.freebsd.org (Postfix) with ESMTP id A2DDD37B401 for ; Sat, 24 Feb 2001 05:34:07 -0800 (PST) (envelope-from des@ofug.org) Received: (from des@localhost) by flood.ping.uio.no (8.9.3/8.9.3) id OAA55646; Sat, 24 Feb 2001 14:26:27 +0100 (CET) (envelope-from des@ofug.org) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Rahul Siddharthan Cc: "Michael C . Wu" , j mckitrick , freebsd-chat@FreeBSD.ORG Subject: Re: bad programming practice? References: <20010223180321.A33329@dogma.freebsd-uk.eu.org> <20010223143019.E32113@peorth.iteration.net> <20010224084058.A50136@lpt.ens.fr> From: Dag-Erling Smorgrav Date: 24 Feb 2001 14:26:26 +0100 In-Reply-To: Rahul Siddharthan's message of "Sat, 24 Feb 2001 08:40:58 +0100" Message-ID: Lines: 12 User-Agent: Gnus/5.0802 (Gnus v5.8.2) Emacs/20.4 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-chat@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Rahul Siddharthan writes: > Think of it this way: any normal person would tend to write "if > (n==1)". Now, to get around using = accidentally for ==, you either > have to train yourself to write "if (1==n)" consistently every time, > or you train yourself to check that == every time you write such an > expression. Why not just train yourself to check the ==? Why not just train yourself to always compile with -Wall -pedantic? DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-chat" in the body of the message