From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.devel Subject: Re: Adding refactoring capabilities to Emacs Date: Tue, 5 Sep 2023 02:34:11 +0300 Message-ID: References: <83fs4f36wi.fsf@gnu.org> <61621120-8f6d-5884-e7c8-33581b8e0ca4@gutov.dev> <87edjkuv0s.fsf@gmail.com> <0bba73a6-f9a5-91c8-ef56-a58951706490@gutov.dev> <838r9rg5x3.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27131"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Cc: Yuri Khan , emacs-devel , "Philip K." To: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= , Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Sep 05 01:35:13 2023 Return-path: Envelope-to: ged-emacs-devel@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 1qdJ68-0006oH-Ub for ged-emacs-devel@m.gmane-mx.org; Tue, 05 Sep 2023 01:35:13 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qdJ5L-0001nv-HG; Mon, 04 Sep 2023 19:34:23 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qdJ5K-0001nj-9P for emacs-devel@gnu.org; Mon, 04 Sep 2023 19:34:22 -0400 Original-Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qdJ5H-00015p-BO; Mon, 04 Sep 2023 19:34:22 -0400 Original-Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.west.internal (Postfix) with ESMTP id 4777C3200939; Mon, 4 Sep 2023 19:34:16 -0400 (EDT) Original-Received: from mailfrontend2 ([10.202.2.163]) by compute3.internal (MEProxy); Mon, 04 Sep 2023 19:34:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gutov.dev; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to; s=fm3; t= 1693870455; x=1693956855; bh=J8CaJ0E9ZkDXQ4tOL61yD44CEwmyDpHKQYX 8zIDBuQQ=; b=FeTGDAmry3aWS2g5HwLPQK6gH+bHwXJnCxhV1L+KqE/uYT84HeN 7vEaTknS6GJDMZ+KEIzj9Uq5M1277wjkT/Q6m/q4YBQWTUnuYnLQbYrrWIn+sHIS paG2s0ocHNKKr29zGflGWM4qrT+aIqDpj5gwaMXrTdJQp+L9Jj+yd1dlt9CNBz29 Z35DImeVSqamg7HkIKnX8AulzjoCDWRfmu55VGfG6AkahfxPvrjgOUj8014OnLvV 537UEkg8oNz0cROtoq720iUZwKPs1i0X6r3uakLTipp0jiPVU6wiO73PYDMRND0m nhUPlE7P78rbDFHDzV20TZivG3icSw88jCw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1693870455; x=1693956855; bh=J8CaJ0E9ZkDXQ4tOL61yD44CEwmyDpHKQYX 8zIDBuQQ=; b=17BCa3yV/pXDpy85/Dn+IGc6J9VJpRCTv9K8AEtKLlCPw4Pef99 Exit8fEaelR5QeEtfxEFOm4AH3HQ2Fgz4afLg6nOo+nOmn5E7pX6XHMgXbbum72R 00SErcs4gNBcTRaNKLBFpZcZHHMkwVkrAHrKUpQ9IB5q1cikCJ2hDXUmwkgBzMwS IyyA+lQrUmoRUuGl1+gJUd5NVrtaXpdD+NnoXST45vVCIez09alOSpD4xLijObny YUf3oDkNv8TP7FT6/FgL0kK8Y8MaHJWgH6GjMxLHkjehOLoV6EYcbkCdbNv9xczy RPmyU6PTTyg0ZRmagl+hox8xxKkPsp8/9PA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrudegledgvdefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffhvfevfhgjtgfgsehtjeertddtfeejnecuhfhrohhmpeffmhhi thhrhicuifhuthhovhcuoegumhhithhrhiesghhuthhovhdruggvvheqnecuggftrfgrth htvghrnhepjedtjedvfedvueejteekgeeffefggfelgfffudelgedvgfegtefgueeihedv lefgnecuffhomhgrihhnpehimhhguhhrrdgtohhmnecuvehluhhsthgvrhfuihiivgeptd enucfrrghrrghmpehmrghilhhfrhhomhepughmihhtrhihsehguhhtohhvrdguvghv X-ME-Proxy: Feedback-ID: i0e71465a:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 4 Sep 2023 19:34:13 -0400 (EDT) Content-Language: en-US In-Reply-To: Received-SPF: pass client-ip=64.147.123.21; envelope-from=dmitry@gutov.dev; helo=wout5-smtp.messagingengine.com X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, NICE_REPLY_A=-1.473, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:310100 Archived-At: On 04/09/2023 18:45, Dmitry Gutov wrote: > Maybe wherever "Extract function" works (newer clangd? I have 15.0.7 > installed), it would do the same. Apparently not quite (there is a "Refactor with Preview..." action on the video). I found this gif with "Extract function": https://i.stack.imgur.com/YLFvw.gif I does look similar to an one-line diff, but lines are not truncated on newline (multiple lines are folded into one instead with a special char denoting newline, as long as they fit into the available width). There is also something that implies a difference but is not: the top node is not a file name, but I'm guessing that's only when the tab (buffer?) is not saved to a file yet.