Why did C++ make any distinction between static globals (internal linkage) and symbols in an unnamed namespace (external linkage, but no way to refer to it from outside anyway), when introducing the latter?
Are any of those reasons still valid, or are there new ones?
Are there any places left where they are still different but the arbitrary rule that anonymous global (or namespace-scope) unions must be
static
, and what are they?For bonus-points, if there are no good reasons left for them to be different, is there a request to make them equivalent?
When C++ introduced namespaces (C++98), and specifically unnamed namespaces, static globals were deprecated as obsolete and inferior to the new thing in a bout of enthusiasm, though that was reverted with C++11:
Deprecation of the static keyword… no more?
Before C++11, symbols with internal linkage could not be used as template-arguments: Why did C++03 require template parameters to have external linkage?