diff options
author | Tim King <taking@cs.nyu.edu> | 2010-06-29 20:58:44 +0000 |
---|---|---|
committer | Tim King <taking@cs.nyu.edu> | 2010-06-29 20:58:44 +0000 |
commit | 200a0b748085004595a948fdea7c73a5ab45bdcf (patch) | |
tree | 692f9457c6e5d4dd7e489be6ba5be65c3ecf7728 /src/util/stats.h | |
parent | e792bb8628ea7010fa9c452bf1aa7ba1b60291a3 (diff) |
Update to stats.h is now back into the trunk. The code should compile once again.
Diffstat (limited to 'src/util/stats.h')
-rw-r--r-- | src/util/stats.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/util/stats.h b/src/util/stats.h index 43f84fee6..8d3d4cfda 100644 --- a/src/util/stats.h +++ b/src/util/stats.h @@ -49,6 +49,7 @@ public: static void flushStatistics(std::ostream& out); static inline void registerStat(Stat* s) throw (AssertionException); + static inline void unregisterStat(Stat* s) throw (AssertionException); }; /* class StatisticsRegistry */ @@ -95,6 +96,12 @@ inline void StatisticsRegistry::registerStat(Stat* s) throw (AssertionException) d_registeredStats.insert(s); } } +inline void StatisticsRegistry::unregisterStat(Stat* s) throw (AssertionException){ + if(USE_STATISTICS){ + AlwaysAssert(d_registeredStats.find(s) != d_registeredStats.end()); + d_registeredStats.erase(s); + } +} |