apolyakov added a comment.
With such overloads we'll get compile time error. If we have overload:
bool HandleSBError(SBError error, std::function<bool()> successHandler = []
{some func}, std::function<void()> errorHandler = [] {some func});
bool HandleSBError(SBError error, std::function<void()> errorHandler);
and call it like:
auto successCase = [] {
...
return MIstatus::failure;
}
bool status = HandleSBError(error, successCase);
we get compile error: call of HandleSBError is ambiguous.
https://reviews.llvm.org/D48295
_______________________________________________
lldb-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits