Use C++17 [[fallthrough]] attribute, and drop -Wno-implicit-fallthrough

This commit is contained in:
Hennadii Stepanov
2021-03-13 21:23:17 +02:00
parent 7a49fdc581
commit 014110c47d
7 changed files with 13 additions and 7 deletions

View File

@@ -287,6 +287,7 @@ bool RPCConsole::RPCParseCommandLine(interfaces::Node* node, std::string &strRes
}
if (breakParsing)
break;
[[fallthrough]];
}
case STATE_ARGUMENT: // In or after argument
case STATE_EATING_SPACES_IN_ARG:
@@ -400,6 +401,7 @@ bool RPCConsole::RPCParseCommandLine(interfaces::Node* node, std::string &strRes
strResult = lastResult.get_str();
else
strResult = lastResult.write(2);
[[fallthrough]];
case STATE_ARGUMENT:
case STATE_EATING_SPACES:
return true;