diff options
-rw-r--r-- | module/system/repl/debug.scm | 5 | ||||
-rw-r--r-- | module/system/vm/frame.scm | 5 |
2 files changed, 7 insertions, 3 deletions
diff --git a/module/system/repl/debug.scm b/module/system/repl/debug.scm index 300145d16..6fff660e5 100644 --- a/module/system/repl/debug.scm +++ b/module/system/repl/debug.scm @@ -1,6 +1,6 @@ ;;; Guile VM debugging facilities -;;; Copyright (C) 2001, 2009, 2010, 2011, 2013, 2014 Free Software Foundation, Inc. +;;; Copyright (C) 2001, 2009, 2010, 2011, 2013, 2014, 2015 Free Software Foundation, Inc. ;;; ;;; This library is free software; you can redistribute it and/or ;;; modify it under the terms of the GNU Lesser General Public @@ -134,7 +134,8 @@ (format port "~&In ~a:~&" file)) (format port "~9@a~:[~*~3_~;~3d~] ~v:@y~%" (if line (format #f "~a:~a" line col) "") - index index width (frame-call-representation frame)) + index index width + (frame-call-representation frame #:top-frame? (zero? index))) (if full? (print-locals frame #:width width #:per-line-prefix " ")))) diff --git a/module/system/vm/frame.scm b/module/system/vm/frame.scm index ac5fbf6f5..b84f6683e 100644 --- a/module/system/vm/frame.scm +++ b/module/system/vm/frame.scm @@ -206,7 +206,10 @@ (when (< offset 0) (error "ip did not correspond to an instruction boundary?")) (if (zero? offset) - (let ((live (if top-frame? + ;; It shouldn't be the case that both OFFSET and N are zero + ;; but TOP-FRAME? is false. Still, it could happen, as is + ;; currently the case in frame-arguments. + (let ((live (if (or top-frame? (zero? n)) (vector-ref inv n) ;; If we're not at a top frame, the IP points ;; to the continuation -- but we haven't |