It could be better behavior, but it is rather tricky to accomplish in a clean way: Eelco Dolstra once said that builder must not perform any direct store operations. As Nix will kill any non-valid store entry with the same name, as the one being built, before build, and registering in the builder is forbidden..