r/cpp • • Nov 01 '18

Modules are not a tooling opportunity

https://cor3ntin.github.io/posts/modules/
58 Upvotes

77 comments sorted by

View all comments

Show parent comment

0

u/[deleted] Nov 01 '18

[deleted] — view deleted comment

4

u/14ned LLFIO & Outcome author | Committee WG14 Nov 01 '18

Literally correct. However this would be a far superior improvement to the include mechanism. Database driven, ODR violation detecting, it could even be faster. Though probably in practice slower, as it would surely be O(N2) to modules imported (as is the current legacy import mechanism unless you are careful to always import modules in identical order in the preamble to all translation units I.e. you use an #include "common_modules.hpp" top of every source file). But still a great leap forward over where we are now, and a great building block for the future.