[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

editing a function definition

    The manual says that doing (ed <symbol>) lets you edit the text for the
    function named <symbol>, but it doesn't say what happens to it once you've
    left the editor.  Is the definition replaced by whatever you did in the
    editor?  If so, are other forms you added while in the editor evaluated

    Also, the manual leaves open the possibility of searching the file system
    for the file containing the original definition of the function.  Does this
    mean that the entire file may be passed to the editor, or should the
    definition of that one function be extracted from the file instead?

All of this is totally up to the implementor of the Lisp environment.
In fact, implementing ED is optional.  The only purpose of including
this function is to provide a standard way of getting over to the editor
to edit the source for a given function, IF that sort of operation makes
sense in your implementation.

My own opinion (none of which is or should be in the Common Lisp spec)
is that an Emacs-like editor ought to zap you over to the right place in
the right file.  I don't much care if it sets up buffer bounds around
the function, but it should be easy to get loose and edit other stuff in
the file.  Facilities must be provided for moving the just-edited
function and any number of other forms back into the Lisp.  I have no
opinions about what an Interlisp-like in-core editor should do.

-- Scott