Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!zaphod.mps.ohio-state.edu!sdd.hp.com!news.cs.indiana.edu!maytag!watstat.waterloo.edu!dmurdoch From: dmurdoch@watstat.waterloo.edu (Duncan Murdoch) Newsgroups: comp.lang.pascal Subject: Re: Gotos are ok (Was Re: IMPLEMENT GOTO ACROSS MODULES IN TURBO PASCAL??) Message-ID: <1991Jan18.141406.3865@maytag.waterloo.edu> Date: 18 Jan 91 14:14:06 GMT References: <11656@j.cc.purdue.edu> <7147@tekgen.BV.TEK.COM> <11661@j.cc.purdue.edu> <1991Jan10.031015.15282@cs.mcgill.ca> <1991Jan10.122222.1013@uwasa.fi> <1991Jan16.005523.28337@syacus.acus.oz> <1991Jan17.205508.16059@massey.ac.nz> Sender: daemon@maytag.waterloo.edu (Admin) Organization: University of Waterloo Lines: 14 In article <1991Jan17.205508.16059@massey.ac.nz> T.Moore@massey.ac.nz (T. Moore) writes: > >I don't think you are as far apart as you think. The operative word is >underlined above. If possible, a program should be tree structured which >essentially means not using spaghetti code. I don't think a program should be tree structured. Perhaps a routine should be, but certainly not a whole program. Programs should be onion-shaped: a few routines at the top for general control, widening out into specialized fairly high level routines for specific tasks, and then narrowing in again to a common library of low-level routines, to maintain a constant interface to the user and the data. Duncan Murdoch