From owner-freebsd-questions@FreeBSD.ORG Tue Apr 6 20:44:19 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E0D8D106566B for ; Tue, 6 Apr 2010 20:44:19 +0000 (UTC) (envelope-from cswiger@mac.com) Received: from asmtpout028.mac.com (asmtpout028.mac.com [17.148.16.103]) by mx1.freebsd.org (Postfix) with ESMTP id C21798FC0A for ; Tue, 6 Apr 2010 20:44:19 +0000 (UTC) MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; charset=us-ascii Received: from cswiger1.apple.com ([17.209.4.71]) by asmtp028.mac.com (Sun Java(tm) System Messaging Server 6.3-8.01 (built Dec 16 2008; 32bit)) with ESMTPSA id <0L0H00D572XSRQ30@asmtp028.mac.com> for freebsd-questions@freebsd.org; Tue, 06 Apr 2010 13:44:18 -0700 (PDT) X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 ipscore=0 phishscore=0 bulkscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx engine=5.0.0-0908210000 definitions=main-1004060219 From: Chuck Swiger In-reply-to: <86d3yc2zib.fsf@red.stonehenge.com> Date: Tue, 06 Apr 2010 13:44:16 -0700 Message-id: <86A6FD8C-EF54-4B61-957E-A88A7272F7C0@mac.com> References: <4BB8108A.9080104@FreeBSD.org> <1270371713.5861.98.camel@tao.thought.org> <86aatjnsts.fsf@red.stonehenge.com> <861vevnsow.fsf@red.stonehenge.com> <20100404163353.GA15198@guilt.hydra> <20100404201442.b456044e.freebsd@edvax.de> <4BB9A5ED.3040309@infracaninophile.co.uk> <20100405173632.739a0c42@gumby.homeunix.com> <20100406015544.GA21119@guilt.hydra> <20100406132049.641b9edf@gumby.homeunix.com> <86wrwkiunp.fsf@red.stonehenge.com> <2EE33758-C39C-41DC-B6A8-B34CF6B3B25A@mac.com> <86k4sk1mle.fsf@red.stonehenge.com> <66F97B7C-9D27-452B-BCC8-30C960599AE0@mac.com> <86d3yc2zib.fsf@red.stonehenge.com> To: "Randal L. Schwartz" X-Mailer: Apple Mail (2.1078) Cc: FreeBSD - Subject: Re: perl qstn... X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Apr 2010 20:44:20 -0000 On Apr 6, 2010, at 11:43 AM, Randal L. Schwartz wrote: > "Chuck" == Chuck Swiger writes: >> Then you wouldn't have used this construct. > > Chuck> If the construct isn't a good idea considering the most obvious > Chuck> change one might make to the code, > > Objection: presumes facts not in evidence, your honor. This isn't a court-room. I don't mind rhetorical flourishes, but if you are unwilling to consider how a statement might be changed over time as the circumstances require, even for the sake of discussion, well, in doing so you've chosen to not consider code maintainability. > Seriously, I've written thousands of lines that look like: > > print "....." if $flag; > > over the years (decades), and only *once* or *twice* do I ever recall > saying "oh, I actually wanted a two-way switch", and had to rewrite it. > > So "most obvious" to you is clearly not what is actually most likely. Very well; I would like to hear you propose another type of change that might be made to this sort of postfix test syntax which you consider to be "most likely". I find it remarkable, and nearly unbelievable, that one would only need to add an else clause to such a statement less often than 0.1% of the time. Frankly, I wouldn't mind taking a look through a few revisions of something you'd written (perhaps via CVSweb or similar) to see what kind of changes you do make to code over time. > Chuck> Surely Perl source code shouldn't be considered as write-once, > Chuck> modify-never? > > Yes, and that's also presumes facts not in evidence. See above. I'd be happy to take a look at your evidence. In fact, I'd already asked a similar question: >> Perl has *many* options that are all clear and readable, and some >> that aren't. Python has a *few* options that are all clear and >> readable, and some that aren't. > > ...and an example or two would be? ...and yet I do not see a response. Regards, -- -Chuck