Skip to content

Commit 3c0c1be

Browse files
committed
Fixed problem with CHECK_TIME macro being optimized out in release and not callnig the function that needs timing.
1 parent e0f5b8f commit 3c0c1be

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/TestMacros.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ TEST_OVERRIDE_LOG(MyFunctor, new MyFunctor());
384384
}
385385

386386
#ifndef CHECK_TIME
387-
#define CHECK_TIME(func) for (; !CheckTime(); ) func
387+
#define CHECK_TIME(func) while (true) { func; if (CheckTime()) break; }
388388
#endif
389389

390390
#ifndef CHECK_PERFORMANCE

0 commit comments

Comments
 (0)