Remove debugging statements for duplicate function entries

This commit is contained in:
Jason Turner 2009-06-20 17:23:23 +00:00
parent 682c572eea
commit c7c6f215b0

View File

@ -31,24 +31,15 @@ namespace dispatchkit
m_scopes.push_back(Scope()); m_scopes.push_back(Scope());
} }
void register_function(const boost::shared_ptr<Proxy_Function> &f, const std::string &name) bool register_function(const boost::shared_ptr<Proxy_Function> &f, const std::string &name)
{ {
if (!add_function(f, name)) return add_function(f, name);
{
std::cout << "Unable to add function: " << name
<< " another function with the exact signature exists." << std::endl;
} }
}
template<typename Function> template<typename Function>
void register_function(const Function &func, const std::string &name) bool register_function(const Function &func, const std::string &name)
{ {
if (!add_function(boost::shared_ptr<Proxy_Function>(new Proxy_Function_Impl<Function>(func)), name)) return add_function(boost::shared_ptr<Proxy_Function>(new Proxy_Function_Impl<Function>(func)), name);
{
std::cout << "Unable to add function: " << name
<< " another function with the exact signature exists." << std::endl;
}
} }