As an elisp beginner I'm trying to grasp what the "best practice" data structure is. For example, I did the simple adding (C-x a, i, g) of things to my abbrev_defs and when I look I see this:
(define-abbrev-table 'global-abbrev-table '( ("crwdesc" ":PROPERTIES: :SEMANTIC: :DESC: :END:" nil 10) ("propid" ":PROPERTIES: :CUSTOM_ID: :SEMANTIC: :DESC: :END: " nil 0) ))
I also see org-element taking a "lisp representation" and turning it into org-mode output:
#+BEGIN_SRC emacs-lisp :results raw (org-element-interpret-data '(headline (:title "One headline" :level 1) (property-drawer nil ((node-property (:key "property1" :value "value1")) (node-property (:key "property2" :value "value2")))) (#("Some much longer content.")))) #+END_SRC #+RESULTS: * One headline :PROPERTIES: :property1: (org-clock-in (quote (16))) :property2: value2 :END: Some much longer content.
Also, the org-element-parse-buffer seems to produce a very elaborate AST which, again, is nested lists. Is this the main data structure when working with elisp? It would seem so -- almost duh! so since this is a lisp. But are there other data structures that are also used? I ask because other data storage and config files (XML, RDF, etc.) generally don't use nested lists. For example, does elisp ever favor the more typical config text layout of simple lines? Or is the mantra "keep it lists?" And I might as well ask about alists while I'm at it. When are they desirable?
I ask all this because your typical tutorial might show you how to use alists, but they rarely talk about its real-world application, when to use it, when not to, or its importance to the language's eco-system.