msvcp90: Add support for throwing bad cast exception to avoid unused variable warning.

This commit is contained in:
Alexandre Julliard 2015-03-04 13:42:13 +09:00
parent 1097384377
commit e1cf7f5a2e
2 changed files with 6 additions and 0 deletions

View File

@ -303,6 +303,7 @@ typedef enum __exception_type {
EXCEPTION_RERAISE,
EXCEPTION,
EXCEPTION_BAD_ALLOC,
EXCEPTION_BAD_CAST,
EXCEPTION_LOGIC_ERROR,
EXCEPTION_LENGTH_ERROR,
EXCEPTION_OUT_OF_RANGE,

View File

@ -623,6 +623,11 @@ void throw_exception(exception_type et, const char *str)
MSVCP_bad_alloc_ctor(&e, &addr);
_CxxThrowException(&e, &bad_alloc_cxx_type);
}
case EXCEPTION_BAD_CAST: {
bad_cast e;
MSVCP_bad_cast_ctor(&e, str);
_CxxThrowException(&e, &bad_cast_cxx_type);
}
case EXCEPTION_LOGIC_ERROR: {
logic_error e;
MSVCP_logic_error_ctor(&e, &addr);