Salome HOME
[EDF25906] : redirect output of the wget into MESSAGE macro
[modules/smesh.git] / src / SMDS / chrono.hxx
index 38ebff8a50f2dfb77ed7e7700dc8997f5c247ac7..6ab049b3904ada958633cae30d8322eb820b1d16 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2006-2016  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2006-2022  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -27,6 +27,8 @@
 #include <iostream>
 #include <ctime>
 
+namespace SMDS
+{
 typedef struct acnt
 {
   char*  _ctrNames;
@@ -57,9 +59,11 @@ protected:
   int _ctr;
   clock_t _start, _end;
 };
-
+}
 #ifdef CHRONODEF
-#define CHRONO(i) counters::_ctrs[i]._ctrNames = (char *)__FILE__; \
+#define CHRONO(i)
+  using namespace SMDS; \
+  counters::_ctrs[i]._ctrNames = (char *)__FILE__;  \
   counters::_ctrs[i]._ctrLines = __LINE__; \
   salome_chrono aChrono##i(i);
 
@@ -67,7 +71,7 @@ protected:
 
 #else  // CHRONODEF
 
-#define CHRONO(i)
+#define CHRONO(i) using namespace SMDS;
 #define CHRONOSTOP(i)
 
 #endif // CHRONODEF