I am using Guile in conjunction with Geiser under Emacs while learning how to program in Scheme. I find it actually a hindrance that Guile drops into a debugger each time I make a typo or enter a wrong piece of code. How can I make Guile more tolerant of my typos/errors and skip the debugger, while using it through Geiser under Emacs?
As I get more advanced in Scheme programming, how would I restore the default behavior or else how can I toggle between having the debugger always start vs start only on demand?
You can set the on-error
option to report
, and it will simply report the error without dropping you in the debugger (that's the default value, debug
); e.g.
scheme@(guile-user)> ,option on-error 'report
scheme@(guile-user)> (/ 1 0)
ERROR: Throw to key `numerical-overflow' with args `("/" "Numerical overflow" #f #f)'.
scheme@(guile-user)>
See: https://www.gnu.org/software/guile/manual/html_node/System-Commands.html
I don't really write a lot of Scheme, but it seems that you can just ignore the debugger.
If you're using lispy to do the eval with e, you don't even see the REPL window, you just get messages in the echo area with the result.
If you set (setq geiser-impl--implementation 'guile)
, and press
e in lispy-mode
, it will start a Geiser REPL
automatically (if there isn't a live one) and eval the expression.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With