I am a Nix user, but one advantage that Bazel has is that it can do more fine-grained incremental rebuilding (nix as commonly used can only do per-project rebuilds). Also while there is some overlap, Nix usually relies on language-specific package managers to perform the actual building, whereas bazel handles that itself. Nix is more of a packaging tool, whereas bazel is a build tool.
When suggesting that rust do the same, I learned that nix doesn't work on Windows.
Can Nix build incrementally? One random collection of notes I just dug up says that it rebuilds packages from scratch on minor changes. It seems like Nix is addressing a different problem.
I thought that Bazel's notion of "incremental building" was at the project level of granularity too. Is that incorrect?
Bazel recompiles at the source file level, and it's very good at only recompiling only what's necessary; for example, it caches object files for C++, and will only rebuild the object files of changed source files, and then relink.