Repository navigation
refactor: fix modernize-return-braced-init-list warnings - #44838
Merged
Merged
Conversation
… braced initializer list instead [modernize-return-braced-init-list]
… braced initializer list instead [modernize-return-braced-init-list] NB: using the braced-initializer list uncovered an error here: the float returned by std::floor() can't be implicitly cast to an int. This is solved by using base::ClampFloor<int>() instead. std::floor()
ckerr
commented
Nov 26, 2024
codebytere
approved these changes
Nov 26, 2024
3 tasks done
dsanders11
approved these changes
Nov 26, 2024
deepak1556
approved these changes
Nov 27, 2024
|
No Release Notes |
Contributor
|
I was unable to backport this PR to "32-x-y" cleanly; |
This was referenced Nov 27, 2024
Contributor
|
I have automatically backported this PR to "34-x-y", please check out #44856 |
Contributor
|
I have automatically backported this PR to "33-x-y", please check out #44857 |
3 tasks done
ckerr
added a commit
that referenced
this pull request
Feb 13, 2025
* refactor: avoid repeating the return type from the declaration; use a braced initializer list instead [modernize-return-braced-init-list] * refactor: avoid repeating the return type from the declaration; use a braced initializer list instead [modernize-return-braced-init-list] NB: using the braced-initializer list uncovered an error here: the float returned by std::floor() can't be implicitly cast to an int. This is solved by using base::ClampFloor<int>() instead. std::floor()
Contributor
jkleinsc
pushed a commit
that referenced
this pull request
Feb 13, 2025
…5608) refactor: fix modernize-return-braced-init-list warnings (#44838) * refactor: avoid repeating the return type from the declaration; use a braced initializer list instead [modernize-return-braced-init-list] * refactor: avoid repeating the return type from the declaration; use a braced initializer list instead [modernize-return-braced-init-list] NB: using the braced-initializer list uncovered an error here: the float returned by std::floor() can't be implicitly cast to an int. This is solved by using base::ClampFloor<int>() instead. std::floor()
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of Change
Fix a handful of modernize-return-braced-init-list warnings. This avoids duplicating the return type in the function definition.
Checklist
npm testpassesRelease Notes
Notes: none.