Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(143)

Unified Diff: extensions/common/features/complex_feature.h

Issue 2193693003: Further reduction of feature_compiler.py generated code (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@test-with-leiz
Patch Set: tests Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: extensions/common/features/complex_feature.h
diff --git a/extensions/common/features/complex_feature.h b/extensions/common/features/complex_feature.h
index 7b63ae6f957b08809537c9ac8891ddc51dc9db66..b302a1ae90146ef83382fd1d1278e28c95d6da27 100644
--- a/extensions/common/features/complex_feature.h
+++ b/extensions/common/features/complex_feature.h
@@ -23,9 +23,8 @@ namespace extensions {
// available, but not if only some combination of Features is available.
class ComplexFeature : public Feature {
public:
- using FeatureList = std::vector<std::unique_ptr<Feature>>;
-
- explicit ComplexFeature(std::unique_ptr<FeatureList> features);
+ // Takes ownership of Feature*s contained in |features|.
+ explicit ComplexFeature(const std::vector<Feature*>& features);
Devlin 2016/07/29 21:15:02 nit: I think it's misleading to take ownership of
scottmg 2016/07/29 21:28:45 Shrug, sure. Done.
~ComplexFeature() override;
// extensions::Feature:
@@ -50,6 +49,7 @@ class ComplexFeature : public Feature {
private:
FRIEND_TEST_ALL_PREFIXES(FeaturesGenerationTest, FeaturesTest);
+ using FeatureList = std::vector<std::unique_ptr<Feature>>;
FeatureList features_;
DISALLOW_COPY_AND_ASSIGN(ComplexFeature);

Powered by Google App Engine
This is Rietveld 408576698