1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 02:52:53 +02:00

Just pass the DIComposite type by value instead of by pointer.

llvm-svn: 194398
This commit is contained in:
Eric Christopher 2013-11-11 18:52:31 +00:00
parent 4848250116
commit 97c343d817
2 changed files with 6 additions and 6 deletions

View File

@ -1133,7 +1133,7 @@ void CompileUnit::constructTypeDIE(DIE &Buffer, DICompositeType CTy) {
switch (Tag) {
case dwarf::DW_TAG_array_type:
constructArrayTypeDIE(Buffer, &CTy);
constructArrayTypeDIE(Buffer, CTy);
break;
case dwarf::DW_TAG_enumeration_type: {
DIArray Elements = CTy.getTypeArray();
@ -1687,12 +1687,12 @@ void CompileUnit::constructSubrangeDIE(DIE &Buffer, DISubrange SR,
}
/// constructArrayTypeDIE - Construct array type DIE from DICompositeType.
void CompileUnit::constructArrayTypeDIE(DIE &Buffer, DICompositeType *CTy) {
if (CTy->isVector())
void CompileUnit::constructArrayTypeDIE(DIE &Buffer, DICompositeType CTy) {
if (CTy.isVector())
addFlag(&Buffer, dwarf::DW_AT_GNU_vector);
// Emit the element type.
addType(&Buffer, resolve(CTy->getTypeDerivedFrom()));
addType(&Buffer, resolve(CTy.getTypeDerivedFrom()));
// Get an anonymous type for index type.
// FIXME: This type should be passed down from the front end
@ -1709,7 +1709,7 @@ void CompileUnit::constructArrayTypeDIE(DIE &Buffer, DICompositeType *CTy) {
}
// Add subranges to array type.
DIArray Elements = CTy->getTypeArray();
DIArray Elements = CTy.getTypeArray();
for (unsigned i = 0, N = Elements.getNumElements(); i < N; ++i) {
DIDescriptor Element = Elements.getElement(i);
if (Element.getTag() == dwarf::DW_TAG_subrange_type)

View File

@ -348,7 +348,7 @@ private:
void constructSubrangeDIE(DIE &Buffer, DISubrange SR, DIE *IndexTy);
/// constructArrayTypeDIE - Construct array type DIE from DICompositeType.
void constructArrayTypeDIE(DIE &Buffer, DICompositeType *CTy);
void constructArrayTypeDIE(DIE &Buffer, DICompositeType CTy);
/// constructEnumTypeDIE - Construct enum type DIE from DIEnumerator.
void constructEnumTypeDIE(DIE &Buffer, DIEnumerator ETy);