GNU bug report logs -
#17675
24.4.50; *gud* buffer keeps on getting buried
Previous Next
Reported by: Michael Welsh Duggan <mwd <at> md5i.com>
Date: Tue, 3 Jun 2014 15:18:02 UTC
Severity: normal
Found in version 24.4.50
Done: Dima Kogan <dima <at> secretsauce.net>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
> When gud-gdb is started, it uses `switch-to-buffer', which places
> *gud-foo* in the window previously occupied by foo.c.
Then this is the culprit. It doesn't make sense to keep the *scratch*
window around when debugging foo.c because sooner or later gdb will have
to display foo.c again. Instead of `switch-to-buffer' we should use
`display-buffer' here. Where is this `switch-to-buffer' call issued?
BTW, this is an issue that bothers me as well because usually I want to
immediately set a breakpoint at the current position of `window-point'
in the source buffer. Hence I start displaying the source file in one
window, split it, and then invoke gdb from the lower window.
> When gdb gets
> "start", foo.c replaces *gud-foo* instead of *scratch* because foo.c has
> been in the window that *gud-foo* occupies, and not in the window that
> *scratch* occupies. This is what `display-buffer-in-previous-window'
> does, no?
Correct. IIRC I wrote `display-buffer-in-previous-window' because
someone using edebug complained about the source code always being
displayed alternately in one of two windows. So if you want an
instantaneous solution for this you will have to customize
`display-buffer-alist' to avoid `display-buffer-in-previous-window'.
martin
This bug report was last modified 6 years and 362 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.