Hi Ludo',

Ludovic Courtès <l...@gnu.org> writes:

> Problem is that the key must remain “small” so that computing its hash
> is fast.  It cannot grow further than its current size, I’m afraid.

What if the hash is calculated in `compile-parameterized' instead (as
that is the only supported way to set the parameters) and passed to
`lower-object'?

> Ideally the key would contain only parameters known to be influential,
> but we cannot tell which are influential and which are not among those
> in the current dynamic state.

Yes that's true, I think the parameters affecting the key should only be
the ones passed to `with-parameters', other parameters would then be
assumed to be constant.

> The solution was to do the same as ‘mparameterize’ to ensure that the
> extent during which parameters are set is the correct one given this is
> in a monadic context.

I think that's a good idea, but I'm not so convinced it makes sense for
a general monad [1]. An alternative solution [2] using `with-fluids*'
has a different problem however, as it doesn't seem to be compatible
with prompts.

Thanks,
David

[1] https://issues.guix.gnu.org/76485#2
[2] https://issues.guix.gnu.org/76485#3



Reply via email to