| PLEX86 | ||
Was FORTRAN buggy 4315On Tue, 12 Sep 2006 03:24:39 +0100 in alt.folklore.computers, Andrew Speaking as a Structured Programming zealot (analprogrammatus zealoti), they're a totally different genus: malaprogrammatus ignorami. But if it takes five pages of code to perform a function, I'm not going to split it into five or more pieces to conform to some misguided fool's ideas of modularity or structure. Some stuff is just complex, or requires a lot of code to do in a given language, and has no functional structure or pattern. Hiding code without gains in other -alities just makes it harder to see the function of a function. If I come across code like: this(p); that(p); other(p); then it should probably all be wrapped into: higher(p); and the boundaries between this(p), that(p), and other(p) looked at carefully to see if that's the most functional split; or if there's some nasty skulduggery being hidden, when it should be hoist into a more prominent position, to prevent it becoming someone's petard. What's more, the code may be totally conditional: containing an immediate return or a big *if* around *all* of the code, so you don't know if routinedosomethingdid *anything*! A rule I picked up along the way is that a routine should normally do what it says, except under exceptional conditions. A function whose main purpose is making a decision is a predicate and that should be kept separate from doing stuff; but not necessarily as a separate predicate function, unless that improves the overall scheme of things: useful abstraction, modularity, or is a parameter. Was FORTRAN buggy 4316 one of the reasons a lot of locations liked cp67 (and vm370) was full source distribution (and in fact, even monthly PLC maintenance was full... -- Thanks. Take care, Brian Inglis Calgary, Alberta, Canada fake address use address above to reply
|
||||
Alt Folklore Computers from Newsgroups The #1 Usenet Provider on the Internet
|
||||