summaryrefslogtreecommitdiff
path: root/zen/perf.h
diff options
context:
space:
mode:
authorDaniel Wilhelm <shieldwed@outlook.com>2018-06-30 12:43:08 +0200
committerDaniel Wilhelm <shieldwed@outlook.com>2018-06-30 12:43:08 +0200
commita98326eb2954ac1e79f5eac28dbeab3ec15e047f (patch)
treebb16257a1894b488e365851273735ec13a9442ef /zen/perf.h
parent10.0 (diff)
downloadFreeFileSync-a98326eb2954ac1e79f5eac28dbeab3ec15e047f.tar.gz
FreeFileSync-a98326eb2954ac1e79f5eac28dbeab3ec15e047f.tar.bz2
FreeFileSync-a98326eb2954ac1e79f5eac28dbeab3ec15e047f.zip
10.1
Diffstat (limited to 'zen/perf.h')
-rwxr-xr-xzen/perf.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/zen/perf.h b/zen/perf.h
index 2006bdab..40b6533d 100755
--- a/zen/perf.h
+++ b/zen/perf.h
@@ -8,8 +8,8 @@
#define PERF_H_83947184145342652456
#include <chrono>
-#include "deprecate.h"
#include "scope_guard.h"
+#include "string_tools.h"
#include <iostream>
@@ -31,7 +31,7 @@ namespace zen
class PerfTimer
{
public:
- ZEN_DEPRECATE PerfTimer() {}
+ [[deprecated]] PerfTimer() {}
~PerfTimer() { if (!resultShown_) showResult(); }
@@ -75,7 +75,8 @@ public:
if (wasRunning) pause(); //don't include call to MessageBox()!
ZEN_ON_SCOPE_EXIT(if (wasRunning) resume());
- std::clog << "Perf: duration: " << timeMs() << " ms\n";
+ const std::string msg = numberTo<std::string>(timeMs()) + " ms";
+ std::clog << "Perf: duration: " << msg << "\n";
resultShown_ = true;
}
bgstack15