Removed KDevelop3 project files, CMake can generate them just fine!

Fixed function literals in static initializers.
Changed alignment of delegates from 2*PTRSIZE to just PTRSIZE.
Changed errors to go to stderr instead of stdout.
Fairly major rewriting of struct/union/class handling, STILL A BIT BUGGY !!!
This commit is contained in:
Tomas Lindquist Olsen 2008-11-29 21:25:43 +01:00
parent 049e24cef8
commit f46f865375
47 changed files with 2103 additions and 2398 deletions

View file

@ -452,14 +452,19 @@ static LLGlobalVariable* dwarfCompositeType(Type* type, llvm::GlobalVariable* co
definedCU = DtoDwarfCompileUnit(sd->getModule());
std::vector<LLConstant*> elems;
elems.reserve(ir->offsets.size());
for (IrStruct::OffsetMap::iterator i=ir->offsets.begin(); i!=ir->offsets.end(); ++i)
if (!ir->aggrdecl->isInterfaceDeclaration()) // plain interfaces don't have one
{
unsigned offset = i->first;
IrStruct::Offset& o = i->second;
std::vector<VarDeclaration*>& arr = ir->varDecls;
size_t narr = arr.size();
elems.reserve(narr);
for (int k=0; k<narr; k++)
{
VarDeclaration* vd = arr[k];
assert(vd);
LLGlobalVariable* ptr = dwarfMemberType(o.var->loc.linnum, o.var->type, compileUnit, definedCU, o.var->toChars(), offset);
elems.push_back(DBG_CAST(ptr));
LLGlobalVariable* ptr = dwarfMemberType(vd->loc.linnum, vd->type, compileUnit, definedCU, vd->toChars(), vd->offset);
elems.push_back(DBG_CAST(ptr));
}
}
const LLArrayType* at = LLArrayType::get(DBG_TYPE, elems.size());