tags:

views:

109

answers:

2

Hi, in common lisp, the names labels and flet are somewhat peculiar to me.

flet could be described as a sort of let for functions. So it named as such. What about labels?

And where does the "f" of getf, setf, remf come from?

Thanks.

+2  A: 

Get form, set form, remove form.

Adrian
"form" I think, but, yeah.
Vatine
Gosh, you're totally right. fix'd.
Adrian
+5  A: 

LABEL (without the s) is a very old (from the early Lisp dialect) construct that allows to give a name to a function so that it can call itself using that name:

Something like (this is not valid Common Lisp):

(label 'ff (lambda (x) (if (foo) (bar) (ff (baz)))))

It labels a function with a name.

For Common Lisp this name has been recycled. LABELS now allows to define local functions that can call themselves by name.

Rainer Joswig