From 1ec26f360406dad0f0b065ebcc8359bed3c78963 Mon Sep 17 00:00:00 2001 From: Matthias Andreas Benkard Date: Thu, 18 Jul 2013 15:29:56 +0200 Subject: Optimize PREPARE-FUNCTION-REF. --- sb-eval2.lisp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/sb-eval2.lisp b/sb-eval2.lisp index 7ee46c5..ffaf0bd 100644 --- a/sb-eval2.lisp +++ b/sb-eval2.lisp @@ -233,9 +233,11 @@ (offset (lexical-offset lexical))) (lambda (env) (environment-value env nesting offset))) - (lambda (env) - (declare (ignore env)) - (fdefinition function-name)))) + (let ((f* (sb-c::fdefinition-object function-name t))) + (lambda (env) + (declare (ignore env)) + (or (sb-c::fdefn-fun f*) + (error 'undefined-function :name function-name)))))) -- cgit v1.2.3