From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#20322: 25.0.50; indent-tabs-mode should default to nil Date: Wed, 15 Apr 2015 01:17:40 +0300 Message-ID: <552D9204.3000604@yandex.ru> References: <861tjn3069.fsf@yandex.ru> <552D20B6.8030005@yandex.ru> <83mw2abul3.fsf@gnu.org> <552D34BC.4090806@yandex.ru> <83h9sibt0q.fsf@gnu.org> <552D7796.2090109@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1429049906 30152 80.91.229.3 (14 Apr 2015 22:18:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 14 Apr 2015 22:18:26 +0000 (UTC) Cc: 20322@debbugs.gnu.org To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Apr 15 00:18:16 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Yi99p-0000Nq-5j for geb-bug-gnu-emacs@m.gmane.org; Wed, 15 Apr 2015 00:18:13 +0200 Original-Received: from localhost ([::1]:58055 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yi99o-0003sI-7P for geb-bug-gnu-emacs@m.gmane.org; Tue, 14 Apr 2015 18:18:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48384) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yi99k-0003ry-QP for bug-gnu-emacs@gnu.org; Tue, 14 Apr 2015 18:18:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yi99e-0006mD-KN for bug-gnu-emacs@gnu.org; Tue, 14 Apr 2015 18:18:08 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:38490) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yi99e-0006lk-Hu for bug-gnu-emacs@gnu.org; Tue, 14 Apr 2015 18:18:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Yi99d-0007dt-VJ for bug-gnu-emacs@gnu.org; Tue, 14 Apr 2015 18:18:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 14 Apr 2015 22:18:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 20322 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 20322-submit@debbugs.gnu.org id=B20322.142904987229356 (code B ref 20322); Tue, 14 Apr 2015 22:18:01 +0000 Original-Received: (at 20322) by debbugs.gnu.org; 14 Apr 2015 22:17:52 +0000 Original-Received: from localhost ([127.0.0.1]:56499 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Yi99T-0007dP-Ug for submit@debbugs.gnu.org; Tue, 14 Apr 2015 18:17:52 -0400 Original-Received: from mail-wi0-f179.google.com ([209.85.212.179]:34901) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Yi99R-0007dB-FL for 20322@debbugs.gnu.org; Tue, 14 Apr 2015 18:17:50 -0400 Original-Received: by widdi4 with SMTP id di4so131709345wid.0 for <20322@debbugs.gnu.org>; Tue, 14 Apr 2015 15:17:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=bfLep0r8CyIRitJWv2xkiQVyp2qgDnf3Oyu+MT6dJuI=; b=QMMCQ3ucIJuN2B4krF5F6iPKd55I7Yt2/AFbWryBcwauhtA501256mvtfyoY7OvZNM JfSpwWY+F6ytZ7PXeC0C5uE9qLbnTmsWEeV1H6Dj8LGE0uqVuVoSOKGbbEHUY/OF7Mwg 2QKYXEN2Gdu5W5qk9DHyndcLQNCX26tN4NK3RhoJXoYAs/IEymiBoiooLX/DmycXxHwQ hYsnnFR0HcSXZmojdQEMqHxtwWHr7UHCMP60BeN+IXcMpTwwgfCHDocb1PT52X4LpKb7 SvnAU9LpuNJFUgwuqLyMpkgB4Xyvuko7awLjTlek7tPviYD6CTAKit7tBL2zl0uLMst0 l9sQ== X-Received: by 10.194.185.68 with SMTP id fa4mr42433999wjc.111.1429049864014; Tue, 14 Apr 2015 15:17:44 -0700 (PDT) Original-Received: from [192.168.1.2] ([82.102.93.54]) by mx.google.com with ESMTPSA id uo6sm3300573wjc.49.2015.04.14.15.17.43 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 14 Apr 2015 15:17:43 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:36.0) Gecko/20100101 Thunderbird/36.0 In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.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.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:101538 Archived-At: On 04/15/2015 12:43 AM, Stefan Monnier wrote: > This doesn't seem to talk about the same thing as what indent-tabs-mode does. > I haven't looked at the code they use, but at least the example they > give is: > function foo() { > return "bar"; > } > > vs > > function foo() { > // use tab for indentation > return "bar"; > } > > whereas indent-tabs-mode does not influence which column is used, only > which chars are used to get there. The examples are admittedly bad (not sure why; maybe because the author found it non-trivial to insert a tab in the middle of a string literal, in their editor). Also see the Ruby one, where both sides of the comparison use 2-space offset. However, the implementation seems to do the right thing: https://github.com/outsideris/popularconvention/blob/master/src/parser/js-parser.coffee#L99-L100 https://github.com/outsideris/popularconvention/blob/master/src/parser/java-parser.coffee#L51-L52 https://github.com/outsideris/popularconvention/blob/master/src/parser/php-parser.coffee#L59-L60 Anyway, the results seem to coincide with what's I've seen in practice. If they can actually change someone's position, we can double-check them, run the analysis ourselves, look for other statistics, etc.