all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Noam Postavsky <npostavs@users.sourceforge.net>
To: Claus Fischer <claus.fischer@clausfischer.com>
Cc: 30044@debbugs.gnu.org
Subject: bug#30044: Emacs: Gud-mode: Debugging with gud: Window switching problem
Date: Thu, 11 Jan 2018 20:24:42 -0500	[thread overview]
Message-ID: <87bmhzq36t.fsf@users.sourceforge.net> (raw)
In-Reply-To: <20180111132401.l22y75dudoefxp5l@clausfischer.com> (Claus Fischer's message of "Thu, 11 Jan 2018 14:24:02 +0100")

Claus Fischer <claus.fischer@clausfischer.com> writes:

> Is it possible to take a gud.el, sprinkle it liberally with some debug
> output, e.g. into Emacs' message buffer or on the terminal, and let me
> load it and wait for the problem to re-occur?

> Does Emacs have some debugging or recording mode for such situations?

This should do it, hopefully it catches all the relevant info.  It will
be printed into a buffer named *trace-output*.

(dolist (fun '(gud-filter gud-display-frame gud-display-line display-buffer))
  (trace-function-background fun))

(defun bug-30044-trace-window-list (&rest _)
  (when (> trace-level 0)
    (trace-values (window-list)
                  (mapcar #'window-prev-buffers (window-list))
                  (mapcar #'window-next-buffers (window-list)))))
(advice-add 'gud-filter :before #'bug-30044-trace-window-list)

(defun bug-30044-trace-current-window (&rest _)
  (when (> trace-level 0)
    (trace-values (selected-window))))
(advice-add 'gud-display-line :before #'bug-30044-trace-current-window)






  reply	other threads:[~2018-01-12  1:24 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-09 12:33 bug#30044: Emacs: Gud-mode: Debugging with gud: Window switching problem Claus Fischer
2018-01-09 18:44 ` Eli Zaretskii
2018-01-09 20:58   ` Claus Fischer
2018-01-10  3:28     ` Eli Zaretskii
2018-01-10  3:39 ` Noam Postavsky
2018-01-10 11:19   ` Claus Fischer
2018-01-11  1:58     ` Noam Postavsky
2018-01-11 13:24       ` Claus Fischer
2018-01-12  1:24         ` Noam Postavsky [this message]
2018-05-20 23:52 ` Noam Postavsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87bmhzq36t.fsf@users.sourceforge.net \
    --to=npostavs@users.sourceforge.net \
    --cc=30044@debbugs.gnu.org \
    --cc=claus.fischer@clausfischer.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.