diff --git a/compiler/eval-comp.lisp b/compiler/eval-comp.lisp
index 877ab300f466470c473a150db5d8ff73aaafd4d8..fb1d3bcb8f7c0645c15b24bf1ed42cf7f5b9f337 100644
--- a/compiler/eval-comp.lisp
+++ b/compiler/eval-comp.lisp
@@ -141,6 +141,10 @@
     %unwind-protect %catch-breakup %unwind-protect-breakup %lexical-exit-breakup
     %continue-unwind %nlx-entry))
 
+;;; Some kinds of functions are only passed as arguments to funny functions,
+;;; and are never actually evaluated at run time.
+;;;
+(defconstant non-closed-function-kinds '(:cleanup :escape))
 
 ;;; ANNOTATE-COMPONENT-FOR-EVAL -- Internal.
 ;;;
@@ -195,6 +199,10 @@
 			  (member (c::global-var-name leaf) undefined-funny-funs
 				  :test #'eq))
 		     :unused)
+		    ((and leaf (typep leaf 'clambda)
+			  (member (functional-kind leaf)
+				  non-closed-function-kinds))
+		     :unused)
 		    (t
 		     (typecase dest
 		       ;; Change locations in eval.lisp that think :return could