External linkage

From cppreference.com
< c‎ | language

In the set of translation units and libraries that constitutes an entire program, each declaration of a particular identifier with external linkage denotes the same object or function.

If the declaration of an identifier for a function has no storage-class specifier, its linkage is determined exactly as if it were declared with the storage-class specifier extern. So, by default, all functions have external linkage.

If the declaration of an identifier for an object has file scope and no storage-class specifier, its linkage is external. So, by default, all file scoped objects have external linkage.

Code in other translation units can access objects and functions with external linkage.

[edit] Example

Identifiers a and f have external linkage. Other translation units may access them.

#include <stdio.h>
 
int a = 1;
 
void f (void) {printf("from function f()\n");}
 
int main(void)
{
    f();
 
    return 0;
}
/* end of this translation unit */

Possible output:

from function f()