C++ extern keyword on functions. Why no just include the header file?
- by user199421
If I understand it correctly this means
extern void foo();
that the function foo is declared in another translation unit.
1) Why not just #include the header in which this function is declared?
2) How does the linker know where to look for function at linking time?