diff --git a/code/debug-int.lisp b/code/debug-int.lisp
index 8f3abe8038ff7b2d09fe3cbbf123ffb0ffbe1737..92a18efdf1a6e10472c369eca1834997a9f684d1 100644
--- a/code/debug-int.lisp
+++ b/code/debug-int.lisp
@@ -5,7 +5,7 @@
 ;;; Carnegie Mellon University, and has been placed in the public domain.
 ;;;
 (ext:file-comment
-  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/debug-int.lisp,v 1.128 2007/07/06 08:04:39 cshapiro Exp $")
+  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/debug-int.lisp,v 1.129 2007/10/02 15:21:26 rtoy Exp $")
 ;;;
 ;;; **********************************************************************
 ;;;
@@ -1976,7 +1976,11 @@ The result is a symbol or nil if the routine cannot be found."
        (if res
 	   (make-compiled-debug-function res
 					 (kernel:function-code-header external))
-	   (error "No such function ~A~%" fun))))))
+	   (if (and (listp fun)
+		    (member (car fun) '(flet labels)))
+	       (error "No such function ~A.  ~
+                       Perhaps it has been inlined?~%" fun)
+	       (error "No such function ~A.~%" fun)))))))
 
 
 ;;; DEBUG-FUNCTION-KIND -- Public.
diff --git a/compiler/locall.lisp b/compiler/locall.lisp
index d4a1005b58969ae2fd2f7783fd5650136ff4e968..eb7f26cd5bc10f07bd42d2846bb655022b9b8d94 100644
--- a/compiler/locall.lisp
+++ b/compiler/locall.lisp
@@ -5,7 +5,7 @@
 ;;; Carnegie Mellon University, and has been placed in the public domain.
 ;;;
 (ext:file-comment
-  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/locall.lisp,v 1.58 2005/10/25 21:14:14 rtoy Exp $")
+  "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/locall.lisp,v 1.59 2007/10/02 15:21:26 rtoy Exp $")
 ;;;
 ;;; **********************************************************************
 ;;;
@@ -1049,6 +1049,8 @@
 ;;; -- There is a change in the cleanup between the call in the return, so we
 ;;;    might need to introduce cleanup code.
 ;;;
+;;;    If the the function is declared notinline, we don't convert the tail
+;;; call either, so that we can trace the local call, if desired.
 (defun maybe-convert-tail-local-call (call)
   (declare (type combination call))
   (let ((return (continuation-dest (node-cont call))))
@@ -1057,6 +1059,7 @@
 	       (immediately-used-p (return-result return) call)
 	       (not (eq (functional-kind (node-home-lambda call))
 			:external))
+	       (not (functional-inlinep (node-home-lambda call)))
 	       (only-harmless-cleanups (node-block call)
 				       (node-block return)))
       (node-ends-block call)