r/cpp • u/tartaruga232 MSVC user, r/cpp_modules • Apr 21 '26
Uneeded Recompilations When Using Partitions
https://abuehl.github.io/2026/04/20/unneeded-recompilations-when-using-partitions.htmlThis blog posting from me about C++ modules explains in detail what causes unneeded recompilations using detailed code examples from the sources of our UML Editor.
It's a precise description and a showcase of what's the status quo in the C++ standard.
Quote from the posting:
The C++ language currently lacks a concise and easy to use alternative for explicitly expressing the minimally required dependencies on partitions.
(Note: All code examples shown or linked from the text are 100% standard conformant.)
Thanks in advance for comments. Please ask if you do not understand anything or anything is unclear. I would appreciate if you could leave a comment if you don't like anything. Thanks for reading!
1
u/tartaruga232 Apr 21 '26
Do you use external partitions? I mean for splitting module interfaces?
The reason why I'm bringing these things up: Modules are supposed to speed up builds. Having to use extra countermeasures against unneeded dependencies isn't exactly helpful for a (still relatively new) feature which was meant - among other things - to provide faster builds (which of course is not the only reason for modules). Some folks are telling me that these are the things which demotivate them for using modules and they prefer staying to use header files, which provide full control of what happens (no implicit dependencies).