Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Exception messages for BadAnyCastException are unhelpful #181
The messages returned from BadAnyCastException::what() are unhelpful while debugging failures. The message appears to be just a static string:
any_cast has access both to the actual type contained within the Any as well as the C++ type that was the requested target type. The message should contain both of these in order to help developers troubleshoot failed casts.
As an example, given this code snippet: