Skip to content

Conversation

@grooverdan
Copy link
Member

@grooverdan grooverdan commented Nov 17, 2025

  • The Jira issue number for this PR is: MDEV-20022

Description

Clang(21.5) issues the following warning and suggestion that has been applied:

sql/item_numconvfunc.cc:2447:15: error: moving a temporary object prevents copy elision [-Werror,-Wpessimizing-move]
2447 | std::move(Zeros_or_nines(static_cast<Zeros&&>(rhs))),
| ^
sql/item_numconvfunc.cc:2447:15: note: remove std::move call here
2447 | std::move(Zeros_or_nines(static_cast<Zeros&&>(rhs))),
| ^~~~~~~~~~

Release Notes

nothing on this change.

How can this PR be tested?

amd64-msan-clang-20-debug and amd64-ubasan-clang-20-debug have been failing since b10e209 was pushed.

If the changes are not amenable to automated testing, please explain why not and carefully describe how to test manually.

func_numconv still passes with this change.

Basing the PR against the correct MariaDB version

  • This is a new feature or a refactoring, and the PR is based against the main branch.
  • This is a bug fix, and the PR is based against the earliest maintained branch in which the bug can be reproduced.

PR quality check

  • I checked the CODING_STANDARDS.md file and my PR conforms to this where appropriate.
  • For any trivial modifications to the PR, I am ok with the reviewer making the changes themselves.

Clang(21.5) issues the following warning and suggestion that has been
applied:

sql/item_numconvfunc.cc:2447:15: error: moving a temporary object prevents copy elision [-Werror,-Wpessimizing-move]
 2447 |               std::move(Zeros_or_nines(static_cast<Zeros&&>(rhs))),
      |               ^
sql/item_numconvfunc.cc:2447:15: note: remove std::move call here
 2447 |               std::move(Zeros_or_nines(static_cast<Zeros&&>(rhs))),
      |               ^~~~~~~~~~
@grooverdan grooverdan requested a review from abarkov November 17, 2025 07:03
@grooverdan grooverdan added the MariaDB Foundation Pull requests created by MariaDB Foundation label Nov 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

MariaDB Foundation Pull requests created by MariaDB Foundation

Development

Successfully merging this pull request may close these issues.

1 participant