The issue is in 3.3.7/1 [basic.scope.class]:
2) A name N used in a class S shall refer to the same declaration in its context and when re-evaluated in the completed scope of S. No diagnostic is required for a violation of this rule.
You use the name type_t
in Inner
, but before the declaration of Inner::type_t
. So the name refers to two different declarations, violating the rule.
No diagnostic is required so clang isn't technically nonconforming, but an error would be nice here.