Skip to content
Snippets Groups Projects
Commit 8d481c49 authored by Florent Lamiraux's avatar Florent Lamiraux
Browse files

Make exception message more explicit

     * src/signal/signal-caster.cpp: when type is not registered.
parent 301de89d
No related branches found
No related tags found
No related merge requests found
......@@ -70,7 +70,10 @@ any SignalCaster::cast(const type_info& type, istringstream& iss) {
map<string, cast_functions_type>::iterator it = functions_.find(type_name);
if ( it == functions_.end() )
throw ExceptionSignal(ExceptionSignal::BAD_CAST, "bad cast");
{
throw ExceptionSignal(ExceptionSignal::BAD_CAST,
"caster not in functions_ map.");
}
//TODO: throw "cast not registered" exception
return (*it).second.get<1>()(iss); // call cast function (tuple index 1)
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment