string to function reference

Alex Martelli aleaxit at
Sat Sep 2 15:27:26 CEST 2000

"Michael Hudson" <mwh21 at> wrote in message
news:m33djjyo8p.fsf at
> You're not missing symbol-function, you're missing find-symbol.
> Python would be a lisp-1 if it were a lisp.
> [5]> (symbol-function "REDUCE")
> *** - SYMBOL-FUNCTION: "REDUCE" is not a symbol
> [7]> (symbol-function (find-symbol "REDUCE"))

Otoh, eval('reduce') returns a function-object (which
can be applied directly or through apply).  There is no
special datatype 'symbol': the string is mapped
directly to (a reference to) the object it's bound to.  Is
it all that different, all in all...?



More information about the Python-list mailing list