Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mailrus!utah-gr!utah-cs!sandra From: sandra@utah-cs.UUCP (Sandra J Loosemore) Newsgroups: comp.lang.lisp Subject: Re: nested function definitions Message-ID: <5570@utah-cs.UUCP> Date: 22 Jun 88 14:07:39 GMT References: <5862@spool.cs.wisc.edu> <5568@utah-cs.UUCP> <3257@ubc-cs.UUCP> <22427@think.UUCP> Organization: University of Utah CS Dept Lines: 19 In article <22427@think.UUCP>, barmar@think.COM (Barry Margolin) writes: > I think the analogy that the compiler subcommittee is > using is DEFUN is to FLET as (SETF SYMBOL-VALUE) is to FLET, i.e. > (DEFUN name ...) macroexpands into (SETF (SYMBOL-FUNCTION 'name) > #'(LAMBDA ...)) plus some unspecified implementation-specific stuff. Yes, that is essentially correct, except I think you really meant to say LET instead of FLET at the end of the second line. If you wanted a DEFUN inside an FLET or LABELS to be able to redefine a local function, you'd either have to make it a special form or define a new special form for it to expand into. The problem is that Common Lisp doesn't provide anything analagous to SETQ that can magically modify either a lexical function binding or a global function binding, depending on the context in which it appears. Personally, I think Common Lisp has quite enough special forms already, and I'm not convinced that such a "feature" would be particularly useful anyway. -Sandra