From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.help Subject: Re: indentation Date: Thu, 29 Apr 2021 09:43:23 -0400 Message-ID: References: <20210427090348.67C9B5D0@centrum.cz> <20210427202932.DFDEF50D@centrum.cz> <20210428083227.FCFDA7C0@centrum.cz> <20210429091455.3C8C08A9@centrum.cz> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22713"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: help-gnu-emacs@gnu.org To: Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Thu Apr 29 15:50:38 2021 Return-path: Envelope-to: geh-help-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 1lc73u-0005nK-79 for geh-help-gnu-emacs@m.gmane-mx.org; Thu, 29 Apr 2021 15:50:38 +0200 Original-Received: from localhost ([::1]:41866 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lc73t-0006N1-8u for geh-help-gnu-emacs@m.gmane-mx.org; Thu, 29 Apr 2021 09:50:37 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:36118) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lc6wz-000746-9h for help-gnu-emacs@gnu.org; Thu, 29 Apr 2021 09:43:29 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:41492) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lc6wx-0003ay-8g for help-gnu-emacs@gnu.org; Thu, 29 Apr 2021 09:43:28 -0400 Original-Received: from pmg2.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id DD12380533; Thu, 29 Apr 2021 09:43:25 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg2.iro.umontreal.ca (Proxmox) with ESMTP id 9708B80385; Thu, 29 Apr 2021 09:43:24 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1619703804; bh=iNuE6zT90GlraKp8jH9P/6lreqvOJnePjVzGu6TaCig=; h=From:To:Cc:Subject:References:Date:In-Reply-To:From; b=IJ8OurJeQmzShTsbHP0Ojw7jPF0t3+DEIn63DGtIZE0ggN5WBrydCCK8clObi52IR gDAbqTQWrWOqS+pqK6XcFTdEzQJJJlvfSm7mo7i32t9WltEwDeg0/dYgIA+NhWbDGK Y9fVZWucm09/srlwE4RQ+JkG5eKFy78z0uyEB1kajp3bsLpNhYxZcGAcIxCbzZPkAV 5xL+yma22Cb4Nql5i5z/ocUrKXexF1JkUoY336tfSmUEtlZv5abV06cZpgcxptnogI VTi3DsvJToY/oSRZsNY7wVl7a5WvbVvd/tGGA39wcepP6YrBxV5BjeB9cy3RrXgorR rv3HQTyW79p7A== Original-Received: from alfajor (unknown [157.52.10.47]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 612B41208EC; Thu, 29 Apr 2021 09:43:24 -0400 (EDT) In-Reply-To: <20210429091455.3C8C08A9@centrum.cz> (ptlo@centrum.cz's message of "Thu, 29 Apr 2021 09:14:55 +0200") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca 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, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:129192 Archived-At: > I admit I'm not a fan of gimmicks that are smarter than me... I think you'll like (electric-indent-mode -1), then ;-) More seriously, this does not necessarily require "smarts": in some (many?) projects, the coding conventions says precisely how indentation should be done, so there is no "smartness" involved and if you don't like what the auto-indentation does, either it's because of a bug in the code, or it's because you disagree with the conventions (and overriding the conventions should be rare). In those cases, typically the coders end up controlling the indentation only indirectly, e.g. by carefully choosing where they cut the lines, or by swapping arguments to commutative operations, or by other such means. Stefan