-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pass vectors of raw pointers to OptionProcessor helpers instead of ve…
…ctors of unique_ptrs. Passing a vector<unique_ptr<T>>& is bad for two reasons: 1) Conceptual - unique_ptr is meant to be a clear signal of ownership transfer. But this is a *reference* to a vector of unique_ptrs so ownership isn't transferred. 2) Practical - this interface is impossible to work with unless you happen to already have a vector of unique_ptrs, because they're move-only so you can't create this on the fly. RELNOTES: None. PiperOrigin-RevId: 329760925
- Loading branch information
1 parent
80bfa26
commit 9483392
Showing
2 changed files
with
14 additions
and
11 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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