l...@gnu.org (Ludovic Courtès) writes: > Hey, > > Andy Wingo <wi...@pobox.com> writes: > > [...] > >> You can't just write functions that return values, you have to contort >> code to store temporaries and then release and then return. You have >> to write paired statements. If you call a user function, you really >> should set up a dynwind, which conses, and contorts your code even >> further. > > Right, that one has to set up a dynwind for nothing sucks. > >> Array_handle_release is a bad idea. > > Fair enough.
FWIW, I agree (I think with both of you) that `we might need it in future' is not a good argument, but that API compatibility is. > The doc would need to be revised (again). > > (It would have helped in this discussion if we knew the rationale for > this API. I couldn't find any trace of discussions around it.) I'm pretty sure it was about allowing C code to efficiently access and modify uniform vector contents, but at the same time supporting operations which might require the underlying storage to be reallocated. The latter operations could include enlarging an existing vector, or copy-on-write. But AFAICT we never implemented either of those ideas, and the existing code never changes the underlying storage of a vector. Regards, Neil