- Both of these constructs are used to represent structs, classes, and unions; Clang uses the collective term "record" for these.
- The term "aggregate" in AggregateStorageLocation implies that, at some point, the intention may have been to use it also for arrays, but it don't think it's possible to use it for arrays. Records and arrays are very different and therefore need to be modeled differently. Records have a fixed set of named fields, which can have different type; arrays have a variable number of elements, but they all have the same type.
- Futhermore, "aggregate" has a very specific meaning in C++ (https://en.cppreference.com/w/cpp/language/aggregate_initialization). Aggregates of class type may not have any user-declared or inherited constructors, no private or protected non-static data members, no virtual member functions, and so on, but we use AggregateStorageLocations to model all objects of class type.
In addition, for consistency, we also rename the following:
- getAggregateLoc() (in RecordValue, formerly known as StructValue) to simply getLoc().
- refreshStructValue() to refreshRecordValue()
We keep the old names around as deprecated synonyms to enable clients to be migrated to the new names.