branch: externals/sly
commit 1dbf87665b7b968981838c077967918b04d3ac89
Author: Daniel Kochmanski <[email protected]>
Commit: João Távora <[email protected]>
ecl: frame-source-location: return error if frame source not found
* slynk/backend/ecl.lisp (frame-source-location): Rework.
Co-authored-by: João Távora <[email protected]>
Cherry-pick-from: SLIME commit 9cdbf5e0d9ca70de869e9f8aeb5835a7e92ff9f8
---
slynk/backend/ecl.lisp | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/slynk/backend/ecl.lisp b/slynk/backend/ecl.lisp
index f8f5174..ecb0869 100644
--- a/slynk/backend/ecl.lisp
+++ b/slynk/backend/ecl.lisp
@@ -587,7 +587,9 @@
;;; frame-restartable-p (frame)
(defimplementation frame-source-location (frame-number)
- (nth-value 1 (frame-function (elt *backtrace* frame-number))))
+ (let ((frame (elt *backtrace* frame-number)))
+ (or (nth-value 1 (frame-function frame))
+ (make-error-location "Unknown source location for ~A." (car frame)))))
(defimplementation frame-catch-tags (frame-number)
(third (elt *backtrace* frame-number)))