Path: utzoo!attcan!uunet!midway!linac!pacific.mps.ohio-state.edu!zaphod.mps.ohio-state.edu!wuarchive!mailrus!accuvax.nwu.edu!mmdf From: lynch@aristotle.ils.nwu.edu (Richard Lynch) Newsgroups: comp.lang.lisp Subject: Re: Matching Parens (was Virtues of LISP Syntax?) Message-ID: <12676@accuvax.nwu.edu> Date: 27 Sep 90 18:44:43 GMT Sender: mmdf@accuvax.nwu.edu Lines: 52 >>I sez: >> I like to make closing parens be on the same line or straight below the >> opening paren. >straz@media-lab.MEDIA.MIT.EDU (Steve Strassmann) sez >Nothing personal, but I hope you're all alone. If people paid half as >much attention to their user interface as they did to their compilers, >we wouldn't have to deal with silliness like this. > >Perhaps you should be using an editor like emacs that comes with some >smarts about traditional lisp formatting. For me at least, the >indentation of the immediately following line tells me all I need to >know about any close-parens. > >For example, in lisp-mode in many versions of emacs, indents a >given line, and indents a given s-expression. Typing a close >parenthesis blinks the corresponding open parenthesis. and > take you back and forth over a given s-expression so you can >see its beginning and end. Just for the record, I *AM* using an EMACS-like editor (FRED: Fred Resembles Emacs Deliberately) as described in another follow-up. It goes emacs one better by flashing the matching paren on and off AUTOMATICALLY when the cursor is at a paren. This means you don't have to ALTER code to INSPECT it which seems barbaric (though admittedly trivial) to me. Nor do you have to memorize arcane keyboard commands to see a whole expression. A double click on a closing paren will hightlight the entire form. As far as interface goes, *I'M* using a Mac where more thought has gone into the interface than went into the whole compiler of most other systems. What precisely is silly about having clear, concise, simple, FOOLPROOF rules about where a matching paren can be found? Can you look at a print-out of your code (that is NOT debugged and MAY contain parenthesis errors) and immediately tell me where any given form is closed? I can for mine. Of course you have to indent as well, but a lot of times in writing code that is long, tedious, and too dissimilar to turn into a function or macro (such as code that draws a lot of slightly different objects in a program that pays plenty of "attention to [my] user interface"), the forms that are being lined up may well be several screenfuls away from each other. [A *LONG* time ago I was using SPF on an IBM mainframe. It allowed you to HIDE as many lines as you wanted (without deleting them, mind you) so that you could ignore the sections that you "knew" were right, and line up and concentrate on the rest. The hidden lines would be replaced by a single line with the text "XXXXX lines hidden" in its place. Would love to see this feature on my FRED editor in MACL. Anybody write this yet?] "TANSTAAFL" Rich lynch@aristotle.ils.nwu.edu