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

Unified Diff: src/IceTimerTree.h

Issue 1197223002: Subzero: Use C++11 member initializers where practical. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Rebase Created 5 years, 6 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
« no previous file with comments | « src/IceThreading.h ('k') | src/IceTimerTree.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceTimerTree.h
diff --git a/src/IceTimerTree.h b/src/IceTimerTree.h
index c7cfd6e68c00ec0b8b8db3bf5d49fe41678fdcb0..17be99743713a92fdfec35c106d58d165536f2e2 100644
--- a/src/IceTimerTree.h
+++ b/src/IceTimerTree.h
@@ -44,13 +44,13 @@ class TimerStack {
TimerTreeNode &operator=(const TimerTreeNode &) = delete;
public:
- TimerTreeNode() : Parent(0), Interior(0), Time(0), UpdateCount(0) {}
+ TimerTreeNode() = default;
TimerTreeNode(const TimerTreeNode &) = default;
std::vector<TTindex> Children; // indexed by TimerIdT
- TTindex Parent;
- TimerIdT Interior;
- double Time;
- size_t UpdateCount;
+ TTindex Parent = 0;
+ TimerIdT Interior = 0;
+ double Time = 0;
+ size_t UpdateCount = 0;
};
public:
@@ -81,14 +81,14 @@ private:
IceString Name;
double FirstTimestamp;
double LastTimestamp;
- uint64_t StateChangeCount;
+ uint64_t StateChangeCount = 0;
// IDsIndex maps a symbolic timer name to its integer ID.
std::map<IceString, TimerIdT> IDsIndex;
std::vector<IceString> IDs; // indexed by TimerIdT
std::vector<TimerTreeNode> Nodes; // indexed by TTindex
std::vector<double> LeafTimes; // indexed by TimerIdT
std::vector<size_t> LeafCounts; // indexed by TimerIdT
- TTindex StackTop;
+ TTindex StackTop = 0;
};
} // end of namespace Ice
« no previous file with comments | « src/IceThreading.h ('k') | src/IceTimerTree.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698