From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: org-element-context doesn't parse consistently link with spaces Date: Wed, 05 Mar 2014 14:22:56 +0100 Message-ID: <87ha7clqz3.fsf@gmail.com> References: <87wqgabb08.fsf@tanger.home> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:41521) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLBmS-0000E8-Na for emacs-orgmode@gnu.org; Wed, 05 Mar 2014 08:22:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WLBmK-0007Tg-Ak for emacs-orgmode@gnu.org; Wed, 05 Mar 2014 08:22:40 -0500 Received: from mail-wg0-x232.google.com ([2a00:1450:400c:c00::232]:64118) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLBmK-0007TS-42 for emacs-orgmode@gnu.org; Wed, 05 Mar 2014 08:22:32 -0500 Received: by mail-wg0-f50.google.com with SMTP id x13so1205897wgg.9 for ; Wed, 05 Mar 2014 05:22:31 -0800 (PST) In-Reply-To: <87wqgabb08.fsf@tanger.home> (daimrod@gmail.com's message of "Tue, 04 Mar 2014 17:53:27 +0900") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Daimrod Cc: emacs-orgmode@gnu.org Hello, Daimrod writes: > I think that there is a bug in `org-element-context' because it doesn't > seem to parse link with spaces consistently. > > For example: > > #+BEGIN_EXAMPLE > v > [[file:test 1 2 3]] > ^ > #+END_EXAMPLE > > If the cursor is before the '1', then `org-element-context' will return: > > #+BEGIN_EXAMPLE > (link (:type "file" :path "test" :raw-link "file:test" :application nil :search-option nil :begin 26 ...)) > #+END_EXAMPLE > > if the cursor is one or after the '1', then `org-element-context' will return: > > #+BEGIN_EXAMPLE > (link (:type "file" :path "test%201%202%203" :raw-link "file:test%201%202%203" :application nil :search-option nil :begin 1 ...)) > #+END_EXAMPLE I cannot reproduce it. What Org version do you use? Did you try to disable `org-element-use-cache'? Regards, -- Nicolas Goaziou