From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Mark Oteiza Newsgroups: gmane.emacs.bugs Subject: bug#25105: bug#25400: M-p in diff-mode jumps too far Date: Wed, 11 Jan 2017 18:27:55 -0500 Message-ID: <20170111232755.GA22069@holos.localdomain> References: <87a8aydxe4.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: blaine.gmane.org 1484177371 11741 195.159.176.226 (11 Jan 2017 23:29:31 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 11 Jan 2017 23:29:31 +0000 (UTC) User-Agent: Mutt/1.7.2+14 (4f0a84b954ef) (2016-11-26) Cc: 25400@debbugs.gnu.org, npostavs@users.sourceforge.net, Dima Kogan , Stefan Monnier , Dmitry Gutov , 25105@debbugs.gnu.org To: Tino Calancha Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Jan 12 00:29:25 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cRSKN-0001DR-KS for geb-bug-gnu-emacs@m.gmane.org; Thu, 12 Jan 2017 00:29:11 +0100 Original-Received: from localhost ([::1]:57930 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cRSKQ-0002HY-8q for geb-bug-gnu-emacs@m.gmane.org; Wed, 11 Jan 2017 18:29:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40585) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cRSKH-0002HA-Mw for bug-gnu-emacs@gnu.org; Wed, 11 Jan 2017 18:29:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cRSKE-0008Bh-H8 for bug-gnu-emacs@gnu.org; Wed, 11 Jan 2017 18:29:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:35073) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cRSKE-0008BM-DU for bug-gnu-emacs@gnu.org; Wed, 11 Jan 2017 18:29:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cRSKE-0004AZ-5j for bug-gnu-emacs@gnu.org; Wed, 11 Jan 2017 18:29:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Mark Oteiza Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 11 Jan 2017 23:29:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25105 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 25105-submit@debbugs.gnu.org id=B25105.148417728615954 (code B ref 25105); Wed, 11 Jan 2017 23:29:02 +0000 Original-Received: (at 25105) by debbugs.gnu.org; 11 Jan 2017 23:28:06 +0000 Original-Received: from localhost ([127.0.0.1]:50472 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cRSJJ-00049B-Nx for submit@debbugs.gnu.org; Wed, 11 Jan 2017 18:28:05 -0500 Original-Received: from mail-qt0-f195.google.com ([209.85.216.195]:35316) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cRSJH-00048Y-83 for 25105@debbugs.gnu.org; Wed, 11 Jan 2017 18:28:03 -0500 Original-Received: by mail-qt0-f195.google.com with SMTP id f4so398106qte.2 for <25105@debbugs.gnu.org>; Wed, 11 Jan 2017 15:28:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=udel-edu.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=KmK2LAVrHcpsLrbl0UMj10Peu6k60251YiY2WAKD5mI=; b=YM3fb9vTk6JvgFE0ajdeDAY/Jg4mY+izx6BiVk7qsdbSf3pOTPSRrKe9zgihuDMQJb SnM9YqsmwzEU3F723AgsE7OuW4BN315wHkVtH+KGp3QVZglk9htw24UuHf+29JGTIpab cHM7BL98sK4hOgGuuhne6gBu9taLLTzoczcU6j8qDX7+gY5BRGLVfAtZxnxx/j8Y7Tep iXEksJe3u5M9EMmdS2weGXBHGea0PLR/JF3Tj4eKqrwxAkY1HuoMoFQs8jye4HiiKUUr Ykz82exQSGly49mm7kZ9hh3EB8d0N8jhVTovfWN/y9KcBw6d19Pt+QTd1IIFWd/uR3cO d16w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=KmK2LAVrHcpsLrbl0UMj10Peu6k60251YiY2WAKD5mI=; b=WkAwLWZPgBNdwaNv5EWJAXbj/+8qIWQ96eh/1Gqko9Mh5yytGn4J04YLwkBmt2lf7O 7xEcZOuCF5u4HtjTME+26cdMkf/H1Ut9bfKpeqj4qqtLV2WqScQSp0UlRqAKQ41jI2tO JtTkZ1VywIsKLs2iMrxcyfnmVlB3E5f1YGWc8PqnXJvhBQV2Km0b3S7U46VpkJazCt2D SopX835bwNHcH6m/VAUNSYajeFb+NzmijU8VXa+kGsmA5SLndESlLoAfkDUe5HCPuSpb /G+eilhT9NvBsDY9YbOPeC2+oPE8pZNashiE97mJzJAYWPpjtIugAEg0Cm8RN/f3yaf7 zPIQ== X-Gm-Message-State: AIkVDXKrIxQ40H+2HVSzUu5D1lGZXIcIhsS+DnBk4PD1yVBTICacnqASof/njFtyzcQx0zVx X-Received: by 10.200.52.170 with SMTP id w39mr11047945qtb.123.1484177277788; Wed, 11 Jan 2017 15:27:57 -0800 (PST) Original-Received: from holos.localdomain (pool-173-67-40-97.bltmmd.fios.verizon.net. [173.67.40.97]) by smtp.gmail.com with ESMTPSA id j126sm3752759qkf.3.2017.01.11.15.27.56 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 11 Jan 2017 15:27:56 -0800 (PST) Original-Received: by holos.localdomain (Postfix, from userid 1000) id BFDE960D5B; Wed, 11 Jan 2017 18:27:55 -0500 (EST) Content-Disposition: inline In-Reply-To: <87a8aydxe4.fsf@gmail.com> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:128023 Archived-At: On 11/01/17 at 01:38pm, Tino Calancha wrote: > Stefan Monnier writes: > > > In a buffer with more than one hunk, if I'm in the middle of hunk number > > N, diff-hunk-prev (usually bound to M-p) jumps to the header of hunk > > number N-1 rather than to the header of hunk N. > > > > This is contrary to the usual behavior of Emacs's navigation commands. > >As pointed out elsewhere, it's particularly obnoxious from EOB (in which > >case, you're not really "within N" but you're virtually on "the header > >of the non-existent hunk N+1", so going to the header of N-1 is really > >wrong). > > > >I also dislike the fact that M-n doesn't let me get to EOB. > > Following patch reverts commit 2c8a7e5. Then it fixes dots 1. and 2. > described in the commit message of 2c8a7e5, i.e., Bug#17544. > This patch preserves the original definitions for 'diff-hunk-prev' > and 'diff-hunk-next'. > > After applying locally this patch, you might want to do: > git diff 2c8a7e5^ HEAD lisp/vc/diff-mode.el > to see more clearly how it solves Bug#17544. Works for me AFAICT. Thanks for working on it.