-- BEGIN CODE -- struct A(T) { static struct B {} } pragma(msg,__traits(parent,__traits(parent,__traits(parent,A!int.B)))); -- END CODE -- The resulting output is `A!int`. If this is the intended behavior of the compiler, then it is problematic for the implementation of `std.traits.fullyQualifiedName`, as the code there (line 340 of std/traits.d) ends up forward referencing itself into oblivion (and therefore making fullyQualifiedName broken for instances of the above pattern). I have a feeling it isn't intended, though.
I can reproduce this with DMD 2.065 so it's a frontend bug common to all D compilers. Please report this bug to https://issues.dlang.org/