Fix cppcheck warnings. No functional change intended.

This commit is contained in:
Wilson Snyder
2020-02-03 23:21:56 -05:00
parent 0aabe6ce00
commit 609a5dc26d
33 changed files with 96 additions and 98 deletions
+1
View File
@@ -120,6 +120,7 @@ void VFileContent::pushText(const string& text) {
string VFileContent::getLine(int lineno) const {
// Return error text rather than asserting so the user isn't left without a message
// cppcheck-suppress negativeContainerIndex
if (VL_UNCOVERABLE(lineno < 0 || lineno >= (int)m_lines.size())) {
if (debug() || v3Global.opt.debugCheck()) {
return ("%Error-internal-contents-bad-ct"+cvtToStr(m_id)