[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: PropertySet with unbound value
From: |
David Kastrup |
Subject: |
Re: PropertySet with unbound value |
Date: |
Fri, 31 Jan 2020 01:28:24 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Dan Eble <address@hidden> writes:
> Does anyone have an idea of input I could provide to reach the block with the
> TODO below? I've tried
>
> #(make-music 'PropertySet 'symbol 'fingeringOrientations)
>
> (note that no value is defined), but it wasn't enough. TIA.
>
> void
> Context::set_property_from_event (SCM sev)
> {
> Stream_event *ev = unsmob<Stream_event> (sev);
>
> SCM sym = ev->get_property ("symbol");
> if (scm_is_symbol (sym))
> {
> SCM val = ev->get_property ("value");
>
> if (SCM_UNBNDP (val)) {
> // TODO: It looks like this ignores \once.
> // Should this be unset_property_from event (sev)?
> unset_property (sym);
> return;
> }
> ...
> —
> Dan
The TODO was added by yourself. I think that unset_property here was
called when \once \set ... was used on a previously unset property and
the implementation used a finalization-hook for unsetting at the point
the event got generated instead of passing the 'once property in the
Stream_event . This mechanism was incompatible with the stream event
recorder and was ultimately replaced by me with
commit 314743a9769d8094d23cd45eb307b1485b41cb44
Author: David Kastrup <address@hidden>
Date: Tue Sep 15 20:50:13 2015 +0200
Issue 4609/4: Move \once action from iterators to listeners
This ends the dependency of the events generated for \once\unset and
\once\set on the current context (bad for recording and replaying events
like with the part combiner and quoted music). It also implements
\once\revert and makes every \once\override and \once\revert impervious
to any other overrides and reverts that may happen at the same time.
It's conceivable that the code was dead afterwards. I am not sure.
--
David Kastrup