Skip to content

Commit 3d9cb89

Browse files
Fix unnecessary string copies in verify tests (#622)
Found via clang-tidy (performance-unnecessary-value-param, performance-move-const-arg, modernize-pass-by-value): - Pass Benchmark's name/unit by value and move into members instead of copying, and forward name via std::move in SimpleBenchmark, ParallelIntersectBenchmark and CreateGeometryBenchmark. - Move name into TestGroup's base Test constructor instead of copying. - Change parameters that are only read (never moved) to const references: TestGroup::add, TestGroup::extend_prefix, prefix_test_names, enable_disable_all_tests, enable_disable_some_tests's test param, plot's outFileName/xlabel, regex_match, and command-line option lambdas that don't consume cin. - Forward cin via std::move where it is passed on by value exactly once (plot-over-primitives/plot-over-threads). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 0bdf3c3 commit 3d9cb89

2 files changed

Lines changed: 86 additions & 86 deletions

File tree

0 commit comments

Comments
 (0)