More informative error message in Hurricane::Net constructor.
This commit is contained in:
parent
f9cd0e2565
commit
afa5fcd4c7
|
@ -269,14 +269,11 @@ Net::Net(Cell* cell, const Name& name)
|
|||
_nextOfCellNetMap(NULL),
|
||||
_mainName(this)
|
||||
{
|
||||
if (!_cell)
|
||||
throw Error("Can't create " + _TName("Net") + " : null cell");
|
||||
|
||||
if (name.isEmpty())
|
||||
throw Error("Can't create " + _TName("Net") + " : empty name");
|
||||
|
||||
if (not _cell) throw Error( "Net::Net(): Can't create Hurricane::Net, NULL cell" );
|
||||
if (name.isEmpty()) throw Error( "Net::Net(): Can't create Hurricane::Net, empty name" );
|
||||
if (_cell->getNet(_name))
|
||||
throw Error("Can't create " + _TName("Net ") + getString(_name) + " : already exists");
|
||||
throw Error( "Net::Net(): Can't create Hurricane::Net named \""+getString(_name)+"\""
|
||||
+ " in Cell \""+getString(_cell->getName())+"\", already exists");
|
||||
}
|
||||
|
||||
Net* Net::create(Cell* cell, const Name& name)
|
||||
|
|
Loading…
Reference in New Issue