Path: utzoo!mnetor!uunet!husc6!mit-eddie!uw-beaver!ubc-vision!alberta!calgary!jameson From: jameson@calgary.UUCP (Kevin Jameson) Newsgroups: comp.lang.lisp Subject: Re: lisp environments summary Message-ID: <1254@vaxb.calgary.UUCP> Date: 8 Dec 87 20:59:44 GMT Organization: U. of Calgary, Calgary, Ab. Lines: 40 Summary: Writing a file and loading it into the lisp environment is ok too. That way you don't risk losing your code through forgetfulness or environment crashes. References: <613@umbc3.UMD.EDU> <325@siemens.UUCP> The Interlisp method of editing functions in the lisp environment and saving them at the discretion of the user is not the only approach. Editing Lisp functions as text and then loading them into the environment is also a method with many advantages. This method has been sucessfully used by a long line of MIT editors and Lisp environments (MacLisp, Lisp Machine, Eine, Zwei, Multics Emacs, and probably others which I don't know about). Stallman addresses this exact issue in Interactive Programming Environments (Barstow/Shrobe/Sandewall, McGraw Hill 1984). He points out that the two real issues are 'whether to edit text or list structure, and whether to edit the program in the same environment in which it is tested'. He makes several good points in favor of the text-based editing approach: 1. It allows user-specified indentation 2. Comments are easily stored and formatted as the user likes them. 3. Code need not be properly structured (ie, syntactically correct) at all times. (This issues is an old one, and is one of the problems with structured editors such as the CMU ALOE and Cornell Synthesizers) 4. Balanced editing functions (eg. balance-parens-backward) can operate on all manner of balanced objects, not just lisp expressions. Other non-lisp-structure-oriented functions are also available. 5. It supports extended syntax mechanisms (eg, the quote facility) which normally destroy the one-to-one mapping between internal and printed (eg. "(quote foo)") forms. In the text-based editing approach, the user always deals with his original representation (eg. 'foo). 6. It allows the editor to be used for other languages, not just Lisp. (The generality of the Emacs approach is unmatched in any other programming environment, to the best of my knowledge) 7. It allows smooth changes to operational parts of the Lisp system itself. "One cannot introduce a bug one moment and fix it the next without risking a crash." In contrast, changes are not picked up in a text-based system until the user loads the modified function.