From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andreas =?UTF-8?Q?R=C3=B6hler?= Newsgroups: gmane.emacs.bugs Subject: bug#23569: thing-at-point, source of slowness Date: Wed, 18 May 2016 09:59:41 +0200 Message-ID: <573C20ED.4050405@easy-emacs.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="------------010409040107000607070608" X-Trace: ger.gmane.org 1463558248 5215 80.91.229.3 (18 May 2016 07:57:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 18 May 2016 07:57:28 +0000 (UTC) To: 23569@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed May 18 09:57:17 2016 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 1b2wLy-0004UE-Pv for geb-bug-gnu-emacs@m.gmane.org; Wed, 18 May 2016 09:57:15 +0200 Original-Received: from localhost ([::1]:43494 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2wLx-0004bB-S9 for geb-bug-gnu-emacs@m.gmane.org; Wed, 18 May 2016 03:57:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54898) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2wLs-0004b2-Gk for bug-gnu-emacs@gnu.org; Wed, 18 May 2016 03:57:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b2wLm-0004O4-Fq for bug-gnu-emacs@gnu.org; Wed, 18 May 2016 03:57:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:44165) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2wLm-0004O0-CR for bug-gnu-emacs@gnu.org; Wed, 18 May 2016 03:57:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1b2wLm-0007Sj-7S for bug-gnu-emacs@gnu.org; Wed, 18 May 2016 03:57:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Andreas =?UTF-8?Q?R=C3=B6hler?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 18 May 2016 07:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 23569 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.146355819928653 (code B ref -1); Wed, 18 May 2016 07:57:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 18 May 2016 07:56:39 +0000 Original-Received: from localhost ([127.0.0.1]:56502 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1b2wLP-0007S4-1q for submit@debbugs.gnu.org; Wed, 18 May 2016 03:56:39 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:35475) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1b2wLN-0007Rs-Kz for submit@debbugs.gnu.org; Wed, 18 May 2016 03:56:37 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b2wLH-0004Gk-Lh for submit@debbugs.gnu.org; Wed, 18 May 2016 03:56:32 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:35870) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2wLH-0004Fb-Ic for submit@debbugs.gnu.org; Wed, 18 May 2016 03:56:31 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54660) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2wLF-0004XS-6a for bug-gnu-emacs@gnu.org; Wed, 18 May 2016 03:56:30 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b2wLA-0004CY-4v for bug-gnu-emacs@gnu.org; Wed, 18 May 2016 03:56:29 -0400 Original-Received: from mout.kundenserver.de ([212.227.17.24]:63863) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b2wL9-0004CL-Qh for bug-gnu-emacs@gnu.org; Wed, 18 May 2016 03:56:24 -0400 Original-Received: from [192.168.178.35] ([77.3.49.22]) by mrelayeu.kundenserver.de (mreue103) with ESMTPSA (Nemesis) id 0MFzpm-1apBDv1plG-00EtDT for ; Wed, 18 May 2016 09:56:21 +0200 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:38.0) Gecko/20100101 Icedove/38.7.0 X-Provags-ID: V03:K0:MCnigtOs1iggsnI+oLGiuwV6MsIOfok83b7n/8Mev7W2KMU1nhv lmT5mRogGmY6QS7xfusrxtZeWXL21LwUxxQk3qC0eG+uW3vv5NtfJ+5LcxueOH/QIdu2jep Qh4TAYV7UnkC90cH0yz1+1J7I/cBQ390PPt+fsuhJoVjHaAY1ylb5J9QF6Y23AaHEzetUYZ 6MQkQx7LOsZfxxzeGEFRQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:VdABLySfTKg=:m4xY11VMafFUl9wCAoaftp rSOyQw+fgein4QuXVbXtqQruT2rvkmtOTwNTMNa7IcugvpIy66dLiELnZvbLtKW5jd7by2TVm EA19H2+TZKeaiGhpHv6/tA1LPSIAhWHBj/TxAWbklQ/p0hmkH9g1OMl1ApYbiAmize3BDKOEd G2a3p4rndqeb7UqcccLB32w32k2vUsgUQwsarUpoi25OCUe8ML2MjBgMhvjPptGpH9sjrp6qq DrJa8+mzld7roD7QZnE71fQuIZNANYoxmM2tINtRwFg0Xdye8d0GO1D5XOGBHN9wgEPHEzlBf arJEkk8DA57O25HYCl6D7D2ZHcx/HPT50+h6YxVsqwP1GZ5LpVz+L4BVW5yF0c5KRT7KslWe2 fIqcZFi4v0d7CNqPJKbswchgP8CpQNPEohNxQEHIHI2rbFnCRJLbhl+ZaZh/JkaH5Vj4x0PXU vKymtdsgzUZW/U4nGIZdC9AvFD14LaLX3mAnpiAZLKANObQwKtn1tQTTca9bnEBmYMrt0FJL1 mFUaEFABg/z+uKS1IbNvQoUREpHEwWOWmMzT+F5E8c5aZV8pT8nHpI29NdcroPJ4tystIoIU7 EmolNpKjCSqH+bSUrqbXQlyWKClH/KVDqIWuHQVxF8v2QfmgHBiy0Xx5/fMt5UaKIFk+cuPKz og5wZYOHXUmPpqKQJnVXbnQFw+ATJ8vYjN9Sd2AosYWZ1Dr92NXIlYcDBFD1sbFEFZFYcExg8 ALO4wPR5cwnEEk12wSrFq0b3rx+IPjqdipG0nw== X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x 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:118380 Archived-At: This is a multi-part message in MIME format. --------------010409040107000607070608 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit in thingatpt.el: ;; The function bounds-of-thing-at-point finds the beginning and end ;; positions by moving first forward to the end of the "thing", and then ;; backwards to the beginning. ;;;;;;; Also *bounds-of-thing-at-point jumps to-and-fro, doing some sanity check every time. Suggest to jump ***first *at the beginning, as backward move might be slow. Avoid to-and-fro, deliver tests instead, so first try will be reliable or return nil. * --------------010409040107000607070608 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit in thingatpt.el:

;; The function bounds-of-thing-at-point finds the beginning and end
;; positions by moving first forward to the end of the "thing", and then
;; backwards to the beginning.

;;;;;;;

Also bounds-of-thing-at-point jumps to-and-fro, doing some sanity check every time.

Suggest to jump
first at the beginning, as backward move might be slow.

Avoid to-and-fro, deliver tests instead, so first try will be reliable or return nil.
--------------010409040107000607070608--