refactor : switch to emplace_back to avoid extra object (#5291)

This commit is contained in:
Michael Klimenko 2024-02-03 12:23:37 +01:00 committed by GitHub
parent 1ec3332ade
commit 52bb63c708
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 36 additions and 36 deletions

View file

@ -105,7 +105,7 @@ int main()
for (auto rule : expected_rules)
{
parsed_grammar.rules.push_back({});
parsed_grammar.rules.emplace_back();
for (auto element : rule)
{
parsed_grammar.rules.back().push_back(element);