backing out of debugger

2021-09-14 Thread Mortimer Cladwell
Hi,
Let's say I made a lot of mistakes. I look at my repl and see:
scheme@(guile-user) [10]>

Any way to back out to scheme@(guile-user)> without typing ,q ten times?
Thanks
Mortimer


Re: backing out of debugger

2021-09-14 Thread Luis Felipe
Hi, Mortimer,

On Tuesday, September 14th, 2021 at 12:50 PM, Mortimer Cladwell 
 wrote:

> Hi,
>
> Let's say I made a lot of mistakes. I look at my repl and see:
>
> scheme@(guile-user) [10]>
>
> Any way to back out to scheme@(guile-user)> without typing ,q ten times?

I don't know if there is a command for that, but maybe pressing Ctrl+D several 
times is easier than typing ,q several times?



Re: backing out of debugger

2021-09-14 Thread Mortimer Cladwell
Thanks Luis. What about in emacs/geiser where Ctrl-D won't work?

On Tue, Sep 14, 2021 at 9:11 AM Luis Felipe 
wrote:

> Hi, Mortimer,
>
> On Tuesday, September 14th, 2021 at 12:50 PM, Mortimer Cladwell <
> mbcladw...@gmail.com> wrote:
>
> > Hi,
> >
> > Let's say I made a lot of mistakes. I look at my repl and see:
> >
> > scheme@(guile-user) [10]>
> >
> > Any way to back out to scheme@(guile-user)> without typing ,q ten times?
>
> I don't know if there is a command for that, but maybe pressing Ctrl+D
> several times is easier than typing ,q several times?
>


Re: backing out of debugger

2021-09-14 Thread tomas
On Tue, Sep 14, 2021 at 08:50:03AM -0400, Mortimer Cladwell wrote:
> Hi,
> Let's say I made a lot of mistakes. I look at my repl and see:
> scheme@(guile-user) [10]>
> 
> Any way to back out to scheme@(guile-user)> without typing ,q ten times?

Guile tells you :)

  scheme@(guile-user)> foo
  ;;; :7:0: warning: possibly unbound variable `foo'
  ice-9/boot-9.scm:1685:16: In procedure raise-exception:
  Unbound variable: foo
  
  Entering a new prompt.  Type `,bt' for a backtrace or `,q' to continue.

This [1] thingy coming next is the new prompt. So typing ,q gets me out
of it:

  scheme@(guile-user) [1]> ,q
  scheme@(guile-user)>

I'm not deep into that, but as far as I understand, the job of this
prompt is to keep information around about what went wrong, so you
can inspect it (e.g. with ,bt).

Cheers
 - t


signature.asc
Description: Digital signature


Re: backing out of debugger

2021-09-14 Thread Luis Felipe
On Tuesday, September 14th, 2021 at 1:27 PM, Mortimer Cladwell 
 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 :)



Re: backing out of debugger

2021-09-14 Thread Olivier Dion via General Guile related discussions
On Tue, 14 Sep 2021, Luis Felipe  wrote:
> On Tuesday, September 14th, 2021 at 1:27 PM, Mortimer Cladwell 
>  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