by joshuamorton · 7y ago · 0 comments
The other nice thing is you get dead code elimination for free.
The other place this is obvious is with tests. If you have a unit test per source, a change to any source will return all tests, splitting reduces this.
In other words, correctly using bazel gives you access to all the cool magic linkers do without having to do the work to implement it. And it adds value even for the ones that do (like C++, again: you'll run fewer tests).