I\'m getting an error from the following code using C++.
Main.cpp
#include \"file.h\"
int main()
{
int k = GetInteger();
retu
Because in this case, static
means that the name of the function has
internal linkage; that GetInteger
in one translation unit is unrelated
to GetInteger
in any other translation unit. The keyword static
is
overloaded: in some cases, it affects lifetime, and in others, binding.
It's particularly confusing here, because "static" is also the name of a
lifetime. Functions, and data declared at namespace scope, always
have static lifetime; when static
appears in their declaration, it
causes internal binding, instead of external.