From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thorsten Jolitz Subject: Circular lists/shared structures in org-element parse-tree Date: Fri, 28 Jun 2013 21:50:17 +0200 Message-ID: <87a9ma9fra.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:59327) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Usegp-00008v-QQ for emacs-orgmode@gnu.org; Fri, 28 Jun 2013 15:50:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Usego-0005mj-Qn for emacs-orgmode@gnu.org; Fri, 28 Jun 2013 15:50:39 -0400 Received: from plane.gmane.org ([80.91.229.3]:55351) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Usego-0005mV-Kn for emacs-orgmode@gnu.org; Fri, 28 Jun 2013 15:50:38 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1Usegn-0002po-EJ for emacs-orgmode@gnu.org; Fri, 28 Jun 2013 21:50:37 +0200 Received: from e178117198.adsl.alicedsl.de ([85.178.117.198]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 28 Jun 2013 21:50:37 +0200 Received: from tjolitz by e178117198.adsl.alicedsl.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 28 Jun 2013 21:50:37 +0200 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: emacs-orgmode@gnu.org Hi List, I wonder how I can find out in a (elisp) program the points in the parse tree (returned by org-element-parse-buffer) where shared structures are used. In the read-syntax, its easy to see (especially with `print-circle' set to non-nil): #+begin_src emacs-lisp #2=(org-data nil #1=(headline (:raw-value "header 1" [...] :parent #2#) [...] #+end_src but when processing the parse tree as a list in elisp, how can I detect the fact that ,------------ | :parent #2# `------------ refers to ,----------------- | #2=(org-data nil `----------------- i.e. points back to an already existing structure? -- cheers, Thorsten