Revert "[clang-tidy] Reserve memory for vector loop"
This reverts commit 7f86b29aa9.
This commit is contained in:
@@ -196,7 +196,6 @@ void Hooks::onExit () const
|
|||||||
|
|
||||||
// Convert to a vector of strings.
|
// Convert to a vector of strings.
|
||||||
std::vector <std::string> input;
|
std::vector <std::string> input;
|
||||||
input.reserve(tasks.size());
|
|
||||||
for (auto& t : tasks)
|
for (auto& t : tasks)
|
||||||
input.push_back (t.composeJSON ());
|
input.push_back (t.composeJSON ());
|
||||||
|
|
||||||
|
|||||||
@@ -47,7 +47,6 @@ static void countTasks (const std::vector <Task>&, const std::string&, int&, int
|
|||||||
std::string taskIdentifiers (const std::vector <Task>& tasks)
|
std::string taskIdentifiers (const std::vector <Task>& tasks)
|
||||||
{
|
{
|
||||||
std::vector <std::string> identifiers;
|
std::vector <std::string> identifiers;
|
||||||
identifiers.reserve(tasks.size());
|
|
||||||
for (const auto& task: tasks)
|
for (const auto& task: tasks)
|
||||||
identifiers.push_back (task.identifier (true));
|
identifiers.push_back (task.identifier (true));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user