Added a check for an empty initializor
This commit is contained in:
parent
45f61a0e0b
commit
49434ecc03
1 changed files with 10 additions and 5 deletions
|
|
@ -89,7 +89,12 @@ class eoGpDepthInitializer : public eoInit< eoParseTree<FType, Node> >
|
|||
max_depth(_max_depth),
|
||||
initializor(_initializor),
|
||||
grow(_grow)
|
||||
{}
|
||||
{
|
||||
if(initializor.empty())
|
||||
{
|
||||
throw logic_error("eoGpDepthInitializer: uhm, wouldn't you rather give a non-empty set of Nodes?");
|
||||
}
|
||||
}
|
||||
|
||||
virtual string className() const { return "eoDepthInitializer"; };
|
||||
|
||||
|
|
|
|||
Reference in a new issue