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

Unified Diff: base/tuple.h

Issue 791883003: tuple: leave fields uninitialized in default constructors (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix silly syntax error Created 6 years 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/tuple.h
diff --git a/base/tuple.h b/base/tuple.h
index 885413f7570e980dbc4c4a2caa4108b2594b8f1a..a0d22454abde023b5fe298d52ac78127c6cd2d2b 100644
--- a/base/tuple.h
+++ b/base/tuple.h
@@ -115,7 +115,7 @@ struct TupleBaseImpl<IndexSequence<Ns...>, Ts...> : TupleLeaf<Ns, Ts>... {
template <size_t N, typename T>
struct TupleLeaf {
- TupleLeaf() : x() {}
+ TupleLeaf() {}
explicit TupleLeaf(typename TupleTraits<T>::ParamType x) : x(x) {}
T& get() { return x; }
@@ -130,7 +130,7 @@ struct TupleLeaf {
#define DEFINE_TUPLE_LEAF(N, x) \
template <typename T> \
struct TupleLeaf<N, T> { \
- TupleLeaf() : x() {} \
+ TupleLeaf() {} \
explicit TupleLeaf(typename TupleTraits<T>::ParamType x) : x(x) {} \
\
T& get() { return x; } \
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698