branch: externals/sly commit 791f7b7eb89793f663d37a6664bd1bb9d276e0e4 Author: Chris Schafmeister <meis...@temple.edu> Commit: João Távora <joaotav...@gmail.com>
Calculate condition-location properly for clasp * slynk/backend/clasp.lisp (condition-location): Rework. Co-authored-by: João Távora <joaotav...@gmail.com> Cherry-picked-from: SLIME commit 8cb0980160efd63286849eebc5743da8f0ef8a68 --- slynk/backend/clasp.lisp | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/slynk/backend/clasp.lisp b/slynk/backend/clasp.lisp index ce27a5f..8c515be 100644 --- a/slynk/backend/clasp.lisp +++ b/slynk/backend/clasp.lisp @@ -227,15 +227,14 @@ (defun condition-location (origin) (if (null origin) (make-error-location "No error location available") - (let ((location (core:source-pos-info-filepos origin))) - (if *buffer-name* - (make-buffer-location *buffer-name* - *buffer-start-position* - location) - (make-file-location - (core:file-scope-pathname - (core:file-scope origin)) - location))))) + ;; NOTE: If we're compiling in a buffer, the origin + ;; will already be set up with the offset correctly + ;; due to the :source-debug parameters from + ;; slynk-compile-string (below). + (make-file-location + (core:file-scope-pathname + (core:file-scope origin)) + (core:source-pos-info-filepos origin)))) (defun signal-compiler-condition (condition origin) (signal 'compiler-condition