Some of the code before https://github.com/NixOS/nix/pull/11351 did not have the problem. What remains wasn't all that problematic, but is good to have anyway.
ln