From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Sun, 7 Aug 2005 02:48:45 +0300 From: Harri Haataja Subject: Re: [9fans] debugging p9p threads question In-reply-to: <20050803072008.GG9518@server4.lensbuddy.com> To: 9fans@cse.psu.edu Message-id: <20050806234844.GC2988@harriha-dsl.oulu.fi> MIME-version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-disposition: inline References: <20050803072008.GG9518@server4.lensbuddy.com> User-Agent: Mutt/1.5.9i Content-Transfer-Encoding: quoted-printable Topicbox-Message-UUID: 740e9f6e-ead0-11e9-9d60-3106f5b1d025 On Wed, Aug 03, 2005 at 08:20:08AM +0100, Uriel wrote: >=20 > The most effective debugging tool is still careful thought, coupled wit= h > judiciously placed print statements. >=20 > -- Brian W. Kernighan, in the paper Unix for Beginners (1979) At http://www.haskell.org/hawiki/QuotesPage: seen on news://comp.lang.functional > By the way seriously: how do you debug Haskell programs? Mostly seriously: I don't. If the programme doesn't work the way I intended it, I rewrite bits in a simpler fashion until I understand it well enough and it works. For the sort of programme you were asking for, breaking things up until they are small enough that one can understand the individual parts completely (as I did in the solution I posted) and then composing them together really is the best approach. If you need to debug a programme that simple, what it's telling you is that you've written it the wrong way! -- J=F3n Fairbairn --=20 For indoor or outdoor use only -- Warning on a Xmas lights set