Mercurial > projects > ldc
view ir/irtype.cpp @ 174:16e676ae5ab4 trunk
[svn r190] Fixed array concatenation for some broken cases.
Added a sanity check for the Dsymbol state set.
author | lindquist |
---|---|
date | Tue, 06 May 2008 18:36:46 +0200 |
parents | db9890b3fb64 |
children | aca17e55b7a5 |
line wrap: on
line source
#include "gen/llvm.h" #include "ir/ir.h" #include "ir/irtype.h" std::set<IrType*> IrType::list; void IrType::resetAll() { std::set<IrType*>::iterator it; for(it = list.begin(); it != list.end(); ++it) (*it)->reset(); } IrType::IrType() { assert(list.insert(this).second); reset(); } IrType::IrType(const IrType& s) { assert(list.insert(this).second); type = s.type; vtblType = s.type; } IrType::~IrType() { list.erase(this); } void IrType::reset() { type = NULL; vtblType = NULL; }