DeclContext class represents all declarations that can act as declaration contexts. As I understand, all declarations which can contain another declaration inside it should be inherited from DeclContext like NamespaceDecl, RecordDecl etc. Typedefs can also contain a struct declaration like
typedef struct abc{
int a;
}def;
inside it. Then why is TyepdefDecl not inherited directly or indirectly from DeclContext class?