From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dave Abrahams Newsgroups: gmane.emacs.bugs Subject: bug#15767: closed (Re: bug#15767: 24.3; [patch] electric-indent-mode bug) Date: Tue, 5 Nov 2013 07:54:35 -0800 Message-ID: <2C2AC8FE-5322-4A31-BD6B-404472991EF0@boostpro.com> References: <04CD2009-757D-471D-8338-325882009851@boostpro.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (1.0) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1383666920 4679 80.91.229.3 (5 Nov 2013 15:55:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 5 Nov 2013 15:55:20 +0000 (UTC) Cc: "15767@debbugs.gnu.org" <15767@debbugs.gnu.org> To: Stefan Monnier Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Nov 05 16:55:23 2013 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 1VdiyO-0000wR-Qg for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 Nov 2013 16:55:20 +0100 Original-Received: from localhost ([::1]:56878 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdiyO-0005W4-CV for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 Nov 2013 10:55:20 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58375) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VdiyE-0005OC-1j for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:55:15 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vdiy8-0007oe-79 for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:55:09 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:50150) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vdiy8-0007oJ-4d for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:55:04 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Vdiy6-0004bD-00 for bug-gnu-emacs@gnu.org; Tue, 05 Nov 2013 10:55:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dave Abrahams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 05 Nov 2013 15:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15767 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 15767-submit@debbugs.gnu.org id=B15767.138366689017661 (code B ref 15767); Tue, 05 Nov 2013 15:55:01 +0000 Original-Received: (at 15767) by debbugs.gnu.org; 5 Nov 2013 15:54:50 +0000 Original-Received: from localhost ([127.0.0.1]:35936 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vdixs-0004ak-Nc for submit@debbugs.gnu.org; Tue, 05 Nov 2013 10:54:49 -0500 Original-Received: from mail-pd0-f174.google.com ([209.85.192.174]:36015) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vdixp-0004aU-U6 for 15767@debbugs.gnu.org; Tue, 05 Nov 2013 10:54:46 -0500 Original-Received: by mail-pd0-f174.google.com with SMTP id z10so8618002pdj.5 for <15767@debbugs.gnu.org>; Tue, 05 Nov 2013 07:54:39 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:references:mime-version:in-reply-to:content-type :content-transfer-encoding:message-id:cc:from:subject:date:to; bh=DlO4luWZOpV5kAsAARM07ix84Dlk+oGqpMdWgYZ+Ksc=; b=nKrSOWcKrPbY4ptY8aJApgj91mqEBu2uQ0oEEfGPFgJOuiEWU4Ndqc78EMPLAUHGQS HpTcEX36JdP2oQNLSYbYe0GiEBsXYNqNvtgw7aYZ+5i3VgTufuzMT0LFAJbOFM91dduz UIpqPDfyzBHZ7Wqc1N7L8BhPrsYbAkNrBKpcnDHBwdfZb1Eyd+othtmIHQOzffa4Y1+e Tg9dKtJtDv939/aJ7O1EOvSqNtnsm7jMI8KolAKbEogq49bhbnM/0GtAqkNC2Hek/HJ4 I4P+2dBh6nmD3KyJGQ8cC1mlAy/zzG6rpHRYoN6x1tg/OPXjwV95w8Vim1uTQhVWkqGd N2MQ== X-Gm-Message-State: ALoCoQkgX621BSB5ZAhRh7jKWfPu7u/Lod1LXrW3TQ0UIbam0jc/dRT+wJCdT6N7htoqYQ1ItOVp X-Received: by 10.68.244.2 with SMTP id xc2mr23625830pbc.58.1383666879378; Tue, 05 Nov 2013 07:54:39 -0800 (PST) Original-Received: from [10.55.104.97] (mobile-166-137-187-098.mycingular.net. [166.137.187.98]) by mx.google.com with ESMTPSA id ka3sm35371137pbc.32.2013.11.05.07.54.37 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 05 Nov 2013 07:54:37 -0800 (PST) In-Reply-To: X-Mailer: iPhone Mail (11B511) 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:80023 Archived-At: Ok thanks for making it right then! Sent from my moss-covered three-handled family gradunza On Nov 5, 2013, at 7:44 AM, Stefan Monnier wrote:= >> Well, the problem I see is that you left the call to line-beginning-posit= ion >> where it was in the original call. At that point, point may be >> on a different line than it started on, so it=E2=80=99s actually getting i= nformation >> about the wrong line. It=E2=80=99s possible that your patch somehow make= s >> everything work out, but leaving the call to line-beginning-position wher= e >> it is seems at best fragile to me. >=20 > On the contrary, moving the call like you did was wrong, IMO. The test > against line-beginning-position is meant to check if pos is on > a previous line, in which case we also need to reindent that previous > line, whereas with your patch it reduces to just check if pos is at > (bolp) which is not as interesting (tho it will often work as well for > the newline case). >=20 >=20 > Stefan