lisp/org-element-ast.el (org-element--property-idx): Simplify implementation

Reported-by: Stefan Monnier <monnier@iro.umontreal.ca>
Link: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=68818#11
This commit is contained in:
Ihor Radchenko 2024-01-31 14:01:33 +01:00
parent 03b383df8b
commit fe663b6c80
No known key found for this signature in database
GPG Key ID: 6470762A7DA11D8B
1 changed files with 4 additions and 7 deletions

View File

@ -353,13 +353,10 @@ node types.")
(define-inline org-element--property-idx (property)
"Return standard property index or nil."
(declare (pure t))
(if (inline-const-p property)
(plist-get
org-element--standard-properties-idxs
(inline-const-val property))
(inline-quote (plist-get
org-element--standard-properties-idxs
,property))))
(inline-letevals (property)
(plist-get
org-element--standard-properties-idxs
(inline-const-val property))))
(define-inline org-element--parray (node)
"Return standard property array for NODE."