From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Madhu Newsgroups: gmane.emacs.devel Subject: Re: newline-and-indent vs. electric-indent-mode Date: Mon, 25 Jan 2021 16:15:15 +0530 Message-ID: References: <87wnw5yt58.fsf@hajtower> <01d07f6d-cc4c-2f54-4bae-a611bba7be93@yandex.ru> <66b7932d-4cee-9628-fae0-168ee6ebc041@yandex.ru> <801ef866-4212-5b74-350e-9942953174fe@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="23980"; mail-complaints-to="usenet@ciao.gmane.io" To: emacs-devel@gnu.org Cancel-Lock: sha1:p8VFiaeB6hQt19L3zILAI9y4f0Q= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Jan 25 11:47:15 2021 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 1l3zOs-00068M-P1 for ged-emacs-devel@m.gmane-mx.org; Mon, 25 Jan 2021 11:47:14 +0100 Original-Received: from localhost ([::1]:37510 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l3zOr-0003fr-Qg for ged-emacs-devel@m.gmane-mx.org; Mon, 25 Jan 2021 05:47:13 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:55964) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l3zN6-0002Wg-2r for emacs-devel@gnu.org; Mon, 25 Jan 2021 05:45:24 -0500 Original-Received: from ciao.gmane.io ([116.202.254.214]:37498) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l3zN3-0004UX-Ly for emacs-devel@gnu.org; Mon, 25 Jan 2021 05:45:22 -0500 Original-Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1l3zMx-0003dA-Eo for emacs-devel@gnu.org; Mon, 25 Jan 2021 11:45:15 +0100 X-Injected-Via-Gmane: http://gmane.org/ Received-SPF: pass client-ip=116.202.254.214; envelope-from=ged-emacs-devel@m.gmane-mx.org; helo=ciao.gmane.io X-Spam_score_int: -16 X-Spam_score: -1.7 X-Spam_bar: - X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.249, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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" Xref: news.gmane.io gmane.emacs.devel:263379 Archived-At: * Dmitry Gutov <801ef866-4212-5b74-350e-9942953174fe@yandex.ru> : Wrote on Mon, 25 Jan 2021 04:29:55 +0200: > On 25.01.2021 03:56, Madhu wrote: >> I used to be benefit from emacs indentation by binding RET to >> newline-and-indent and remain in control of indentation. > > How was it different? > newline-and-indent can lead to "spurious whitespace" just the same. This is true now, and I'm not able to say with certainty what the difference was 10 years ago (if it indeed was different) IIRC the way to deal with it was that if the next event after a newline-and-indent is *not* a self-insert-command, then empty whitespace on that line should have be cleaned up.