summaryrefslogtreecommitdiff
path: root/module/system/repl/debug.scm
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2010-10-01 18:15:23 +0200
committerAndy Wingo <wingo@pobox.com>2010-10-01 18:15:23 +0200
commite867d563a56a86533f998441dc8c48dfef38d017 (patch)
treef20942408b8c8b647bae13d36996cb6a651ec145 /module/system/repl/debug.scm
parentc005daf9239b6c2b5574d88a0ee46195ac1cb1ec (diff)
downloadguile-e867d563a56a86533f998441dc8c48dfef38d017.tar.gz
add source:line-for-user, returning a 1-indexed line number
* module/system/vm/program.scm (source:line-for-user): New exported procedure, returns a 1-indexed line, suitable for presentation to a user. (write-program): Use source:line-for-user when making fallback names. * module/system/vm/coverage.scm (coverage-data->lcov): * module/language/assembly/disassemble.scm (source->string): * module/system/repl/debug.scm (print-frame): Use source:line-for-user.
Diffstat (limited to 'module/system/repl/debug.scm')
-rw-r--r--module/system/repl/debug.scm2
1 files changed, 1 insertions, 1 deletions
diff --git a/module/system/repl/debug.scm b/module/system/repl/debug.scm
index 28e7e3060..0e491b5db 100644
--- a/module/system/repl/debug.scm
+++ b/module/system/repl/debug.scm
@@ -109,7 +109,7 @@
"unknown file"))
(let* ((source (frame-source frame))
(file (source:pretty-file source))
- (line (and=> source source:line))
+ (line (and=> source source:line-for-user))
(col (and=> source source:column)))
(if (and file (not (equal? file (source:pretty-file last-source))))
(format port "~&In ~a:~&" file))