static class A { int bar; string str; private int dum; } static class B { A foo; int mid; } static class C { B baz; int top; } static class Address { int zipcode; } static class D { Address address; } static struct E { int foo; } static struct F { E bar; } static assert(FlattenedMembers!C == ["baz", "baz.foo", "baz.foo.bar", "baz.foo.str", "baz.mid", "top"]); static assert(FlattenedMembers!D == ["address", "address.zipcode"]); static assert(FlattenedMembers!F == ["bar", "bar.foo"]);
Get a list of flatenned class member.