all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: martin rudalics <rudalics@gmx.at>
To: Yuan Fu <casouri@gmail.com>
Cc: 40268@debbugs.gnu.org
Subject: bug#40268: 27.0.60; [PATCH] Unify and improve gdb-mi source window display
Date: Tue, 31 Mar 2020 11:15:37 +0200	[thread overview]
Message-ID: <115885b9-ddfd-2752-0c8c-aa4f98aacaaf@gmx.at> (raw)
In-Reply-To: <FC089A49-C41F-44F2-9C08-B1EB021CE355@gmail.com>

 > This one should be ok.

Thanks.  A few remarks.  Please try to ident as

         (setq gdb-source-window-list
               (cl-remove-duplicates
                (cl-remove-if-not
		(lambda (win)
		  (and (window-live-p win)
                        (equal (window-frame win)
                               (selected-frame))))
                 gdb-source-window-list)
                :test #'equal))

so we can safely change this later and easily stay within our line
length limits.  Also, tests like

                        (equal (window-frame win)
                               (selected-frame))))

should use "eq" instead of "equal" and ones like

                      ((member (selected-window) gdb-source-window-list) 'source)))

"memq" instead of "member".

Similarly to the above, writing

	 (window
	  (when buffer
	    (if (eq gud-minor-mode 'gdbmi)
                 (gdb-display-source-buffer buffer)
               ;; Gud still has the old behavior.
               (or (get-buffer-window buffer)
                   (display-buffer buffer '(nil (inhibit-same-window . t)))))))

permits us to stay within the 80 columns limit.

Finally, instead of "Also, we simply the logic ..." I'd write "Also,
simplify the logic ...".  And please provide a NEWS entry.

Thanks again for the work, martin





  reply	other threads:[~2020-03-31  9:15 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <310914cd-1822-3fe9-19ae-6e47f8e72072@gmx.at>
2020-03-28  4:03 ` bug#40268: 27.0.60; [PATCH] Unify and improve gdb-mi source window display Yuan Fu
2020-03-29  9:01   ` martin rudalics
2020-03-29 17:27     ` Yuan Fu
2020-03-31  9:15       ` martin rudalics [this message]
2020-04-04 20:29         ` Yuan Fu
2020-04-06  9:04           ` martin rudalics
2020-04-06 14:21             ` Yuan Fu
2020-04-14  1:09   ` bug#40268: Fwd: " Yuan Fu

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=115885b9-ddfd-2752-0c8c-aa4f98aacaaf@gmx.at \
    --to=rudalics@gmx.at \
    --cc=40268@debbugs.gnu.org \
    --cc=casouri@gmail.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.