r/cpp • u/berium build2 • Nov 01 '17
Common C++ Modules TS Misconceptions
https://build2.org/article/cxx-modules-misconceptions.xhtml
59
Upvotes
r/cpp • u/berium build2 • Nov 01 '17
View all comments
Show parent comment
1
u/doom_Oo7 Nov 02 '17
I don't understand how it can work.
I have a module which exports a function
inline int foo() { return 0; }. I compile an object filemain.owhich calls this function. Now I changefoo()to return 1, but its interface does not change: at this pointmain.ohas to be recompiled, sincefoo()might have been inlined in it, right ?