Use std::as_const (C++17 feature)

This commit is contained in:
Mat Sutcliffe
2021-04-17 22:21:18 +01:00
parent 6d617f40a4
commit 33209fa1eb
42 changed files with 92 additions and 103 deletions

View File

@@ -139,7 +139,7 @@ namespace BlackMisc
void CSimpleCommandParser::registerCommand(const CSimpleCommandParser::CommandHtmlHelp &command)
{
for (const CommandHtmlHelp &help : as_const(s_commands))
for (const CommandHtmlHelp &help : std::as_const(s_commands))
{
// avoid duplicates
if (help.command == command.command) { return; }