From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: phs Newsgroups: gmane.emacs.bugs Subject: bug#21167: 24.5; tags-search should ignore buffer restriction Date: Fri, 31 Jul 2015 11:43:39 +0200 Message-ID: <55BB434B.7020004@lsv.ens-cachan.fr> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1438356337 8362 80.91.229.3 (31 Jul 2015 15:25:37 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 31 Jul 2015 15:25:37 +0000 (UTC) To: 21167@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Jul 31 17:25:22 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 1ZLCBT-0007Ww-VB for geb-bug-gnu-emacs@m.gmane.org; Fri, 31 Jul 2015 17:25:20 +0200 Original-Received: from localhost ([::1]:44753 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZLCBT-0003Gp-Bf for geb-bug-gnu-emacs@m.gmane.org; Fri, 31 Jul 2015 11:25:19 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55958) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZLCBK-0003B2-L6 for bug-gnu-emacs@gnu.org; Fri, 31 Jul 2015 11:25:16 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZLCBC-0007CQ-Um for bug-gnu-emacs@gnu.org; Fri, 31 Jul 2015 11:25:10 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:34499) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZLCBC-0007C5-SY for bug-gnu-emacs@gnu.org; Fri, 31 Jul 2015 11:25:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1ZLCBC-0006J9-MD for bug-gnu-emacs@gnu.org; Fri, 31 Jul 2015 11:25:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: phs Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 31 Jul 2015 15:25:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 21167 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.143835626524192 (code B ref -1); Fri, 31 Jul 2015 15:25:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 31 Jul 2015 15:24:25 +0000 Original-Received: from localhost ([127.0.0.1]:35945 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZLCAb-0006I7-0K for submit@debbugs.gnu.org; Fri, 31 Jul 2015 11:24:25 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:50534) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZL7Dk-0005nt-Cj for submit@debbugs.gnu.org; Fri, 31 Jul 2015 06:07:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZL7De-0001WK-VQ for submit@debbugs.gnu.org; Fri, 31 Jul 2015 06:07:20 -0400 Original-Received: from lists.gnu.org ([208.118.235.17]:51559) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZL7De-0001WG-SW for submit@debbugs.gnu.org; Fri, 31 Jul 2015 06:07:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35777) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZL7DZ-0004id-OQ for bug-gnu-emacs@gnu.org; Fri, 31 Jul 2015 06:07:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZL7DU-0001Tb-La for bug-gnu-emacs@gnu.org; Fri, 31 Jul 2015 06:07:09 -0400 Original-Received: from olive.lsv.fr ([138.231.81.248]:47817 helo=olive.lsv.ens-cachan.fr) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZL7DU-0001Gc-Fk for bug-gnu-emacs@gnu.org; Fri, 31 Jul 2015 06:07:04 -0400 Original-Received: from phs-air-2.local (gwvisitors.lsv.fr [138.231.81.8]) by olive.lsv.ens-cachan.fr (Postfix) with ESMTP id 6F1004C01A4 for ; Fri, 31 Jul 2015 11:43:39 +0200 (CEST) User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Mailman-Approved-At: Fri, 31 Jul 2015 11:24:24 -0400 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:105242 Archived-At: Description: tags-search when going through all files listed in the current tags table, tags-search searches inside existing buffers for files that are currently visited (this is where the latest version can be found). But when the visiting buffer has been restricted by a narrow-to-region, tags-search will not look outside the narrowed-to scope. I call this a bug. E.g., it can cause a global renaming of variables miss some occurrences. It seems that a minimal fix is for tags-search to warn the user that the buffer has been narrowed and offer to widen for the search (and maybe reinstall the restriction after the search???). I looked at the source code. It appears that the problem is located within function next-file (in progmodes/etags.el). When it is found that there already is a buffer visiting the file to be searched for tags, next-file just uses it without checking for restrictions. BTW, I don't understand why next-file passes the novisit flag to find-file? -- Philippe SCHNOEBELEN, www.lsv.ens-cachan.fr/~phs LSV, CNRS UMR 8643 & ENS de Cachan Tel: (+33/0) 147 407 530 "Algebraic symbols are used when you do not know what you are talking about"