Alex Rivera | Logout

Common lisp: Redefine an existing function within a scope?

Asked 2010-06-19T07:55:33.160
12

In Common Lisp, is it possible to redefine an already defined function within a certain scope? For example, given a function A that calls a function B. Can I temporarily redefine B during a call to A?

I'm looking for something along the lines of a let block, but that can redefine functions.

Edit
Report

1 Answer

7

Local functions can be introduced with FLET and LABELS.

answered 2010-06-19T08:25:18.783

Your Answer