std::string description;
creator_base(const std::string& descr): description(descr) { }
creator_base(const char* descr): description(descr) { }
+ virtual ~creator_base() { }
virtual Base* operator()() const = 0;
};
if (it != assoc.end())
return (*it->second)();
else
- return NULL;
+ return nullptr;
}
const std::string& get_name(iterator& it) const { return it->first; }
std::string description;
creator_base(const std::string& descr): description(descr) { }
creator_base(const char* descr): description(descr) { }
+ virtual ~creator_base() { }
virtual Base* operator()(Arg1, Arg2) const = 0;
};
if (it != assoc.end())
return (*it->second)(arg1, arg2);
else
- return NULL;
+ return nullptr;
}
const std::string& get_name(iterator& it) const { return it->first; }