3 ms·
why use modules if PCH on your diagram is not much worse in compile times?
by feelamee 9mo ago
why use modules if PCH on your diagram is not much worse in compile times?
- nickelpro 9mo agoMacro hygiene, static initialization ordering, control over symbol export (no more detail namespaces), slightly higher ceiling for compile-time and optimization performance. If these aren't compelling, there's no real reason.
- feelamee 8mo agoWe live with that for *decades*. For me this is not a daily problem. So yes, this is not compelling, unfortunately.
- bluGill 9mo agomodules are the future and the rules for are well thought out. Ever compiler has their own version of PCH and they all work different in annoying ways.
- WalterBright 9mo agoHaving implemented PCH for C and C++, it is an uuugly hack, which is why D has modules instead.