guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: backing out of debugger


From: Mortimer Cladwell
Subject: Re: backing out of debugger
Date: Wed, 15 Sep 2021 11:40:17 -0400

Thanks Matt.
I wrote a Guile utility function and attached to a button using e-lisp:

----Guile-----------------------------------------------------------
(define (back-out repl-stack )
  (if (null? (cdr repl-stack))
      (throw 'quit)
      (begin
(throw 'quit)
(back-out (cdr repl-stack)))))
----end guile-------------------------------------------------------

----Emacs Lisp---------------------------------------------------
(defun insert-back-out()
  (interactive)
  (insert "(back-out (fluid-ref *repl-stack*))"))

(global-set-key (kbd "<f4>") 'insert-back-out)
---end-elisp------------------------------------------------------

If I am at scheme@(guile-user) [3]> I must press the button three times.
So doesn't quite work as expected. Seems like only one (throw 'quit) can be
executed per prompt? Not sure what the problem is.
Mortimer

On Tue, Sep 14, 2021 at 10:35 AM Olivier Dion <olivier.dion@polymtl.ca>
wrote:

> On Tue, 14 Sep 2021, Luis Felipe <luis.felipe.la@protonmail.com> wrote:
> > On Tuesday, September 14th, 2021 at 1:27 PM, Mortimer Cladwell <
> mbcladwell@gmail.com> wrote:
> >
> >> Thanks Luis. What about in emacs/geiser where Ctrl-D won't work?
> >
> > The equivalent in Geiser would be C-c C-q, I think. But I don't know
> > if that's any better than typing ,q plus Enter :)
>
> You could define a procedure that calls geiser-repl-exit N time with the
> prefix argument.
>
> Note that geiser-repl-exit already takes a prefix argument, but will
> simply kill the process instead of exiting N repl.
>
> --
> Olivier Dion
> Polymtl
>


reply via email to

[Prev in Thread] Current Thread [Next in Thread]