mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-04-29 14:40:40 +03:00
[cleanup] Remove unused IrTypeAggr::default_fields and accessors.
This commit is contained in:
parent
e7838a30a6
commit
de742a06e2
3 changed files with 0 additions and 26 deletions
|
@ -37,16 +37,6 @@ public:
|
|||
///
|
||||
IrTypeAggr* isAggr() { return this; }
|
||||
|
||||
///
|
||||
typedef std::vector<VarDeclaration*>::iterator iterator;
|
||||
|
||||
///
|
||||
iterator def_begin() { return default_fields.begin(); }
|
||||
|
||||
///
|
||||
iterator def_end() { return default_fields.end(); }
|
||||
|
||||
|
||||
/// Composite type debug description. This is not only to cache, but also
|
||||
/// used for resolving forward references.
|
||||
llvm::DIType diCompositeType;
|
||||
|
@ -57,13 +47,6 @@ protected:
|
|||
|
||||
/// AggregateDeclaration this type represents.
|
||||
AggregateDeclaration* aggr;
|
||||
|
||||
/// Sorted list of all default fields.
|
||||
/// A default field is a field that contributes to the default initializer
|
||||
/// and the default type, and thus it has it's own unique GEP index into
|
||||
/// the aggregate.
|
||||
/// For classes, field of any super classes are not included.
|
||||
std::vector<VarDeclaration*> default_fields;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
@ -65,7 +65,6 @@ void IrTypeClass::addBaseClassData(
|
|||
// mirror the sd->fields array but only fill in contributors
|
||||
const size_t n = base->fields.dim;
|
||||
LLSmallVector<VarDeclaration*, 16> data(n, NULL);
|
||||
default_fields.reserve(n);
|
||||
|
||||
// first fill in the fields with explicit initializers
|
||||
for (size_t index = 0; index < n; ++index)
|
||||
|
@ -158,10 +157,6 @@ void IrTypeClass::addBaseClassData(
|
|||
|
||||
assert(vd->offset >= offset && "it's a bug... most likely DMD bug 2481");
|
||||
|
||||
// add to default field list
|
||||
if (cd == base)
|
||||
default_fields.push_back(vd);
|
||||
|
||||
// get next aligned offset for this type
|
||||
size_t alignedoffset = realignOffset(offset, vd->type);
|
||||
|
||||
|
|
|
@ -112,7 +112,6 @@ IrTypeStruct* IrTypeStruct::get(StructDeclaration* sd)
|
|||
// mirror the sd->fields array but only fill in contributors
|
||||
const size_t n = sd->fields.dim;
|
||||
LLSmallVector<VarDeclaration*, 16> data(n, NULL);
|
||||
t->default_fields.reserve(n);
|
||||
|
||||
// first fill in the fields with explicit initializers
|
||||
for (size_t index = 0; index < n; ++index)
|
||||
|
@ -218,9 +217,6 @@ IrTypeStruct* IrTypeStruct::get(StructDeclaration* sd)
|
|||
|
||||
assert(vd->offset >= offset);
|
||||
|
||||
// add to default field list
|
||||
t->default_fields.push_back(vd);
|
||||
|
||||
// get next aligned offset for this type
|
||||
size_t alignedoffset = offset;
|
||||
if (!packed)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue