Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed more COPY_INSTEAD_OF_MOVE Coverity warnings #5949

Merged
merged 1 commit into from
Feb 7, 2024

Conversation

firewave
Copy link
Collaborator

@firewave firewave commented Feb 6, 2024

No description provided.

@@ -8033,7 +8033,9 @@ std::string ValueType::str() const
ret += " &";
else if (reference == Reference::RValue)
ret += " &&";
return ret.empty() ? ret : ret.substr(1);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Variables in ternaries are not moved on return so I split the statement instead of introducing an explicit move.

@chrchr-github chrchr-github merged commit d449ee6 into danmar:main Feb 7, 2024
64 checks passed
@firewave firewave deleted the cov-move branch February 7, 2024 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants