emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Upstreaming org-element-ast (was: Improving Emacs' iCalendar support


From: Richard Lawrence
Subject: Re: Upstreaming org-element-ast (was: Improving Emacs' iCalendar support)
Date: Sat, 11 Jan 2025 18:44:27 +0100

Ihor Radchenko <yantar92@posteo.net> writes:

> Richard Lawrence <rwl@recursewithless.net> writes:
>
>> Another idea: could one use aliasing or symbol properties somehow to
>> allow library users to "rename" standard properties they don't need? All
>> that really needs to happen dynamically is mapping a keyword to an array
>> index, right?
>
> The whole idea behind standard properties is that they are resolved
> statically, at compile time. Adding any kind of dynamic resolution will
> defeat their purpose (speed).

Sorry, maybe "dynamically" was a poor word choice...I guess I meant
something more like "statically, but outside org-element-ast.el, in the
calling program".

I looked briefly at the definition of org-element--property-idx and at
its disassembly, which makes it look like one can actually do something
like what I was suggesting by modifying the property list
org-element--standard-properties-idxs, like:

(let ((org-element--standard-properties-idxs
       (plist-put org-element--standard-properties-idxs
                  :value 5))) ;; use the :post-blank slot for :value instead
   ...)

but maybe I'm not understanding something. Would modifying this plist
from the calling code work as a strategy for "renaming" the standard
properties slots?






reply via email to

[Prev in Thread] Current Thread [Next in Thread]