diff UnitTestsSources/GenericToolboxTests.cpp @ 1680:03afa09cfcf1

running the tests of the Orthanc Framework in WebAssembly
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 24 Nov 2020 16:39:54 +0100
parents 5b8b88e5bfd6
children 9ac2a65d4172
line wrap: on
line diff
--- a/UnitTestsSources/GenericToolboxTests.cpp	Tue Nov 24 12:59:10 2020 +0100
+++ b/UnitTestsSources/GenericToolboxTests.cpp	Tue Nov 24 16:39:54 2020 +0100
@@ -26,9 +26,14 @@
 
 #include <gtest/gtest.h>
 #include <stdint.h>
-#include <inttypes.h>  // For PRId64
 #include <cmath>
 
+#if __cplusplus >= 201103L   // Is C++11?
+#  include <cinttypes>  // For PRId64
+#else
+#  define PRId64 "%lld"
+#endif
+
 TEST(GenericToolbox, TestLegitDoubleString)
 {
   using OrthancStone::GenericToolbox::LegitDoubleString;