Path: utzoo!attcan!uunet!mcsun!ukc!edcastle!cs.ed.ac.uk!cs.edinburgh.ac.uk!nick From: nick@cs.edinburgh.ac.uk (Nick Rothwell) Newsgroups: comp.lang.misc Subject: Re: Need reference for "firewall" modularization Message-ID: <1087@skye.cs.ed.ac.uk> Date: 29 Oct 90 12:35:17 GMT References: <26865@megaron.cs.arizona.edu> Sender: nnews@cs.ed.ac.uk Reply-To: nick@lfcs.ed.ac.uk Organization: Wavetables 'R' Us Lines: 43 In article <26865@megaron.cs.arizona.edu>, gudeman@cs.arizona.edu (David Gudeman) writes: > In article <961@skye.cs.ed.ac.uk> nick@cs.edinburgh.ac.uk (Nick Rothwell) writes: > ]In article <1990Oct25.193935.375@arnor.uucp>, strom@arnor.uucp writes: > ]> many program bugs are the result of issuing otherwise correct operations > ]> *in the wrong order* > > ]Just a minor point here - that's a fault with conventional procedural > ]languages with assignable variables, and nothing to do with typechecking. > ]Functional and logic languages don't have this problem at all. > > First, some functional languages and the only well-known logic > language (Prolog) certainly _do_ have this problem. If you do things > in the wrong order, you may get peculiar results like non-termination. Ok, I stand corrected. The way I read the original article is that there are problems with referring to variables which are unassigned or which go out of scope (dangling pointers and the like). Higher-level languages don't have these problems. But, yes, you still have to "do things in the right order" in the sense you mean. > Basically someone screwed-up somewhere, and changing the paradigm > just changes the nature of the screw-ups, not the quantity or the > quality. This is not to say that changing the language itself can't > reduce errors, just that there is no reason to assume that functional > or logic languages by the fact of being function-based or predicate > logic-based reduce errors. True, but I think the fact that assignment is non-existent (or kept to a minimum), the fact that the languages are garbage-collected and heap-safe, make them "better" in this sense. That isn't an argument about which paradigm to use (and that wasn't really the impression I wanted to give). > David Gudeman Nick. -- Nick Rothwell, Laboratory for Foundations of Computer Science, Edinburgh. nick@lfcs.ed.ac.uk !mcsun!ukc!lfcs!nick ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ "Now remember - and this is most important - you must think in Russian."