From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#40268: 27.0.60; [PATCH] Unify and improve gdb-mi source window display Date: Tue, 31 Mar 2020 11:15:37 +0200 Message-ID: <115885b9-ddfd-2752-0c8c-aa4f98aacaaf@gmx.at> References: <63AC5BC7-CFFC-42DF-AD76-3414B631A6DE@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="58863"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 40268@debbugs.gnu.org To: Yuan Fu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Mar 31 11:16:40 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jJD0i-000FC0-50 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 31 Mar 2020 11:16:40 +0200 Original-Received: from localhost ([::1]:34440 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jJD0g-00046F-JZ for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 31 Mar 2020 05:16:38 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35394) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jJD07-00045x-8r for bug-gnu-emacs@gnu.org; Tue, 31 Mar 2020 05:16:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jJD06-0006TH-6Y for bug-gnu-emacs@gnu.org; Tue, 31 Mar 2020 05:16:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:52201) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1jJD05-0006Sz-T1 for bug-gnu-emacs@gnu.org; Tue, 31 Mar 2020 05:16:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jJD05-0005vv-P8 for bug-gnu-emacs@gnu.org; Tue, 31 Mar 2020 05:16:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 31 Mar 2020 09:16:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 40268 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 40268-submit@debbugs.gnu.org id=B40268.158564614722777 (code B ref 40268); Tue, 31 Mar 2020 09:16:01 +0000 Original-Received: (at 40268) by debbugs.gnu.org; 31 Mar 2020 09:15:47 +0000 Original-Received: from localhost ([127.0.0.1]:35514 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jJCzr-0005vJ-8W for submit@debbugs.gnu.org; Tue, 31 Mar 2020 05:15:47 -0400 Original-Received: from mout.gmx.net ([212.227.17.21]:42013) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jJCzp-0005uv-7y for 40268@debbugs.gnu.org; Tue, 31 Mar 2020 05:15:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1585646138; bh=6gU+ZnVDfEkFngPKIZ+rMDK6PDhCyGM62O684xax/T4=; h=X-UI-Sender-Class:Subject:To:Cc:References:From:Date:In-Reply-To; b=gnTPGKSobq6CUcW0nhpQFrhfcKLJSiyKFCjvj1e89UH1/oZhUKV0g33CYNLCb4MDH oHkGRCAjIkNWJTFc7km4HmOTPRgeSFUpNfDqsIvYtl2Cxh6mFsNE0REsCsk4rA8g2F T66E3sub0OrsNCXdawwPe0MPIoA+RTuUy+HQJt/o= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [192.168.1.101] ([212.95.5.250]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MBDj4-1jUmlo1PSA-00Cguy; Tue, 31 Mar 2020 11:15:38 +0200 In-Reply-To: Content-Language: en-US X-Provags-ID: V03:K1:fj0flrTvI5d8yktjgFUcqew+4xOLyHBVbcesGaiP4TdtrYDpGjc aknh9ww19BHHZyIUWv23xw+EZQPV2LcIi8/uwc6q1Qf5wVqHSVnPdc01jFp1WhKLGIEJLpI Dksvo/buSpZfWfwb8efHdsgL5dkYFuxM7CYR/mIfEtSfkwTgMs1MawJeSQxZmRj3LuVEX2p EP61U8A0Rt+0RTE04ZKWQ== X-UI-Out-Filterresults: notjunk:1;V03:K0:y1kNkF/NXrU=:SxUZz5PKBi4aC0o+wZeJ0j bxeqGSRiTo4DWgBVS6hkSdNcDcxlTEFwVomcxE93/TQyuUCt2cQAoENAM5Sf/EOI1KLlduko/ EEfINu0Mr8nM8bpD5ennF5C1eyfO2qQXAKzYLlp01ITSNLE2Lr/zr3dAXmZfiyMCOdEF0Wevn GZbXEGRXjEltSZ9o6W6foPE7Myih6JTxwlAAoEgPfB3+Y8qMOOBkaRZ68ttoL4/6dLm9SvX1y I7eSZYeMgl5RUIhPgpHxhvVBtFj40VfwFkS56dhL+UNpwhSHIZeZVtagqfI45miKwjSMCUoXz 4mcxvHGU7ihShGRih3yodpl4OZ03qHf5yrBsDt6qec/4khcVxd0VSRWU/2zYhtRw6iPPQ09et QZd4wsPrMWDqKCfD3nzA9NErf+MGNOqn4l2pKos3uTs0VA6519edXgInv5puAhy5Uup7OC8oM Lo4FzjQQeagSgfiZlpPjcSuSpmGguSEon9yCF0HlrqrehtAVMEEYcGeVqGlrMR+A1iXnB8fmF d3tgRHJ9R0qKZu2zyYaaYyt5TKyf1os1gtBc08DFKjOOagynzhwfrdRRSe/uRN7CKJp1xKYlh sqGxstC9nEOlcbZTVSl2R+ezEHzFq4HSm3pJJk5SwJRBRW2y7sP/TkQja0v+iRobMk1ArbpiS 4mUtnK14fuO1kZL2RB17TUUwDAWKzL85HK7052rL1mAjeww/TNXUJD3GFCKPhwNbcYPRJNTsv 2uotCOtPBeRU01A6qL3cUocFEpUkr2If957rQKTLmiUODeqdmcduOrSv10bDQox8wDpenSpg X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:177906 Archived-At: > 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