Since {cpp}11, declaring a variable, class, or function in an unnamed ``++namespace++`` gives it internal linkage. Similarly, marking a declaration ``++static++`` also gives it internal linkage. Because both mechanisms have the same effect (although ``++static++`` has a narrower application) using them together is clearly redundant.


== Noncompliant Code Example

----
namespace {
  static int i = 3;  // Noncompliant
}
----


== Compliant Solution

----
namespace {
  int i = 3;
}
----


== See

* ISO/IEC 14882:2011 §3.5 paragraph 4

