diff options
author | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2010-09-06 21:13:12 +0200 |
---|---|---|
committer | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2010-09-06 21:13:12 +0200 |
commit | d7805560c066359595e67d7edb60769861e1e2e6 (patch) | |
tree | 739eb0d96a5471b2ce636481637c267c4f1ab7eb | |
parent | c6acac244447cac2b4580658b40f3bde2425b8c4 (diff) | |
download | geiser-chez-d7805560c066359595e67d7edb60769861e1e2e6.tar.gz geiser-chez-d7805560c066359595e67d7edb60769861e1e2e6.tar.bz2 |
Guile: geiser-guile-jump-on-debug-p, geiser-guile-show-debug-help-p
-rw-r--r-- | elisp/geiser-custom.el | 5 | ||||
-rw-r--r-- | elisp/geiser-guile.el | 18 |
2 files changed, 21 insertions, 2 deletions
diff --git a/elisp/geiser-custom.el b/elisp/geiser-custom.el index 789c824..4b69053 100644 --- a/elisp/geiser-custom.el +++ b/elisp/geiser-custom.el @@ -1,6 +1,6 @@ ;;; geiser-custom.el -- customization utilities -;; Copyright (C) 2009 Jose Antonio Ortega Ruiz +;; Copyright (C) 2009, 2010 Jose Antonio Ortega Ruiz ;; This program is free software; you can redistribute it and/or ;; modify it under the terms of the Modified BSD License. You should @@ -59,6 +59,9 @@ (when (boundp name) (push (cons name (symbol-value name)) result))))) + +(put 'geiser-custom--defcustom 'lisp-indent-function 2) + (provide 'geiser-custom) ;;; geiser-custom.el ends here diff --git a/elisp/geiser-guile.el b/elisp/geiser-guile.el index af9d589..8561df7 100644 --- a/elisp/geiser-guile.el +++ b/elisp/geiser-guile.el @@ -52,6 +52,17 @@ If `nil', only the last frame is shown." :type 'boolean :group 'geiser-guile) +(geiser-custom--defcustom geiser-guile-jump-on-debug-p nil + "Whether to autmatically jump to error when entering the debugger. +If `t', Geiser will use `next-error' to jump to the error's location." + :type 'boolean + :group 'geiser-guile) + +(geiser-custom--defcustom geiser-guile-show-debug-help-p t + "Whether to show brief help in the echo area when entering the debugger." + :type 'boolean + :group 'geiser-guile) + ;;; REPL support: @@ -132,7 +143,12 @@ This function uses `geiser-guile-init-file' if it exists." (comint-send-string nil "((@ (geiser emacs) ge:newline))\n") (comint-send-string nil ",error-message\n") (comint-send-string nil bt-cmd) - (message "Debug REPL. Enter ,q to quit, ,h for help."))) + (when geiser-guile-show-debug-help-p + (message "Debug REPL. Enter ,q to quit, ,h for help.")) + (when geiser-guile-jump-on-debug-p + (accept-process-output (get-buffer-process (current-buffer)) + 0.2 nil t) + (ignore-errors (next-error))))) t) |