Minor optimization.

This commit is contained in:
Nicolás Ortega Froysa 2017-09-20 10:54:13 +02:00
parent 4dd6b1ba06
commit 5ab7a7bb5b
No known key found for this signature in database
GPG Key ID: FEC70E3BAE2E69BF
2 changed files with 2 additions and 2 deletions

View File

@ -23,7 +23,7 @@
static std::vector<std::string> errors; static std::vector<std::string> errors;
void add_error(std::string error) { void add_error(const std::string &error) {
if(not errors.empty()) if(not errors.empty())
errors.push_back(error); errors.push_back(error);
} }

View File

@ -20,4 +20,4 @@
#include <string> #include <string>
void add_error(std::string error); void add_error(const std::string &error);