Add default case for unhandled target_type values

This commit is contained in:
sephiroth99
2015-12-30 11:29:16 -05:00
parent da71bc26a2
commit 3f49aa3cef

View File

@@ -206,6 +206,9 @@ void Value::Convert(TypeName target_type, RoundMode round_mode) {
type = target_type;
constant.f64 = constant.f32;
return;
default:
assert_unhandled_case(target_type);
return;
}
case FLOAT64_TYPE:
switch (target_type) {
@@ -213,6 +216,9 @@ void Value::Convert(TypeName target_type, RoundMode round_mode) {
type = target_type;
constant.f32 = (float)constant.f64;
return;
default:
assert_unhandled_case(target_type);
return;
}
default:
assert_unhandled_case(type);