Adjust all places where RPC::IteratorType is created to use std::vector#372
Merged
VeithMetro merged 5 commits intomasterfrom Mar 30, 2026
Merged
Adjust all places where RPC::IteratorType is created to use std::vector#372VeithMetro merged 5 commits intomasterfrom
VeithMetro merged 5 commits intomasterfrom
Conversation
sebaszm
requested changes
Dec 14, 2025
Contributor
sebaszm
left a comment
There was a problem hiding this comment.
In some cases we have an idea how much elements will be pushed to the vector, so I suppose reserve() would be beneficial?
sebaszm
approved these changes
Dec 17, 2025
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates several plugin implementations to construct RPC::IteratorType instances backed by std::vector instead of list-based containers, aligning iterator creation with vector storage and enabling more efficient moves/reserving in some call sites.
Changes:
- Replaced multiple
std::listusage sites withstd::vectorand addedreserve()where sizes are known. - Updated
RPC::IteratorType<...>aliases to explicitly specifystd::vector<...>as the backing container and usedstd::movewhen passing temporary containers. - Adjusted container-filling code paths (e.g.,
std::transforminserters) to matchstd::vector.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| WebKitBrowser/WebKitBrowser.cpp | Switch language iterator backing store to std::vector with reserve() and move into iterator. |
| PlayerInfo/GStreamer/PlatformImplementation.cpp | Change codec storage members to std::vector, reserve based on caps map size, and update iterator typedefs accordingly. |
| PlayerInfo/DeviceSettings/PlatformImplementation.cpp | Same codec container migration to std::vector + reserve(), and iterator typedef updates. |
| MessageControl/MessageControl.h | Use std::vector for module/control lists and move into vector-backed iterators. |
| DisplayInfo/DeviceSettings/PlatformImplementation.cpp | Use std::vector for HDR/colorimetry capability lists and move into iterators; add small fixed reserve(). |
| DeviceInfo/DeviceInfoImplementation.h | Change output list aliases to std::vector and update iterator typedefs to vector-backed iterators. |
| DeviceInfo/DeviceInfoImplementation.cpp | Use std::vector for output iterator snapshots (reserve + back_inserter + move) and update several iterator typedefs to vector-backed iterators. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
sebaszm
approved these changes
Mar 30, 2026
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.
No description provided.