Coverity analysis defect 178019: Variable copied when it could be moved

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Trivial - P5
    • None
    • Affects Version/s: None
    • Component/s: None
    • Storage Engines - Foundations
    • SE Foundations - Q4+ Backlog
    • None

      Variable copied when it could be moved

      Unnecessary object copies can affect performance. Creating a copy of a variable that is no longer used instead of using std::move().
      /test/cppsuite/tests/bounded_cursor_prefix_indices.cpp:219: COPY_INSTEAD_OF_MOVE 178019 "prefixes" is copied and then passed-by-reference as parameter to STL insertion function "push_back", when it could be moved instead.

            Assignee:
            Unassigned
            Reporter:
            Coverity Collector User
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: