Skip to content

Avoid unnecessary copies in TrigSteerMonitor, DecisionHandling, TrigCompositeUtils, TrigOutputHandling

Fix the following clang-tidy warnings about unnecessary copy:

  • warning: loop variable is copied but only used as const reference; consider making it a const reference [performance-for-range-copy]
  • warning: the loop variable's type is not a reference type; this creates a copy in each iteration; consider making this a reference [performance-for-range-copy]
  • warning: the parameter ... is copied for each invocation but only used as a const reference; consider making it a const reference [performance-unnecessary-value-param]
  • warning: parameter ... is passed by value and only copied once; consider moving it to avoid unnecessary copies [performance-unnecessary-value-param]
  • warning: passing result of std::move() as a const reference argument; no move will actually happen [performance-move-const-arg]
  • warning: the const qualified variable ... is copy-constructed from a const reference; consider making it a const reference [performance-unnecessary-copy-initialization]

cc @tamartin

Merge request reports

Loading