1. Enclosing function (nested struct and clsass)
2. Enclosing class (nested class only)
3. If its enclosing aggregate is templated, its `isnested`.
See `AggregateDeclaraton::makeNested` for the details.