Skip to content

Commit ff6a8cc

Browse files
committed
use cppcheck::unreachable()
1 parent d85f2a7 commit ff6a8cc

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

lib/errortypes.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ std::string severityToString(Severity severity)
6969
case Severity::internal:
7070
return "internal";
7171
}
72-
throw InternalError(nullptr, "Unknown severity");
72+
cppcheck::unreachable();
7373
}
7474

7575
// TODO: bail out on invalid severity

lib/vfvalue.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ namespace ValueFlow {
129129
return result;
130130
}
131131
}
132-
throw InternalError(nullptr, "Invalid ValueFlow Value type");
132+
cppcheck::unreachable();
133133
}
134134

135135
const char *Value::toString(MoveKind moveKind) {

0 commit comments

Comments
 (0)