From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eike Subject: Re: org-elements-parse-buffer and weird property drawers Date: Sat, 30 Aug 2014 21:02:41 +0200 Message-ID: <87oav1zto3.fsf@ithaka.home> References: <87r3zxzwgz.fsf@ithaka.home> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38466) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XNnxT-0003m6-Se for emacs-orgmode@gnu.org; Sat, 30 Aug 2014 15:05:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XNnxN-0005El-5v for emacs-orgmode@gnu.org; Sat, 30 Aug 2014 15:05:07 -0400 Received: from ns.km31707.keymachine.de ([87.118.120.70]:41571 helo=eknet.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XNnxM-0005Cd-Vj for emacs-orgmode@gnu.org; Sat, 30 Aug 2014 15:05:01 -0400 Received: from 84-73-222-131.dclient.hispeed.ch (EHLO ithaka.home.eknet.org) ([84.73.222.131]) by km31707 (JAMES SMTP Server ) with ESMTPA ID 850996813 for ; Sat, 30 Aug 2014 21:04:59 +0200 (CEST) In-reply-to: <87r3zxzwgz.fsf@ithaka.home> 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: org-mode forgot to mention org version: Org-mode version 8.3beta (release_8.3beta-296-g851b77 @ /home/eike/.emacs.d/src/org-mode/lisp/) Kind regards, Eike Eike writes: > Hello all, > > I'm playing with the functions in org-elements.el and the following > effect seems strange to me: > > I have a few propery drawers with empty propertys, like > > #+BEGIN_EXAMPLE > :PROPERTIES: > :date: [2014-08-29 Fr] > :chf: 21.76 > :eur: > :END: > #+END_EXAMPLE > > If I do org-elements-parse-buffer, the empty one is not there, but the > first one is duplicated. At least, there are two node-property > elements in the tree like that: > > #+BEGIN_EXAMPLE > (node-property (:key "chf" :value "21.76" :begin 38 :end 58 :post-blank 0 :post-affiliated 38 :parent #4)) > (node-property (:key "chf" :value "21.76" :begin 58 :end 67 :post-blank 0 :post-affiliated 58 :parent #4)) > #+END_EXAMPLE > > The function call was this: > > #+begin_src emacs-lisp > (with-current-buffer "test-exp.org" > (org-element-parse-buffer)) > #+end_src > > And here is the "test-exp.org" org file: > > #+BEGIN_EXAMPLE > * Sonstiges > ** Pizza > :PROPERTIES: > :chf: 21.76 > :eur: > :END: > #+END_EXAMPLE > > Am I missing something, or are empty properties not supported? > > Kind regards, > Eike -- gpg: AD7AC35E finger print: 137F BB0B 1639 D25F DC5D E59C B412 C5F5 AD7A C35E