X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHUtils%2FSMESH_TryCatch.cxx;h=b808a791bdcbeda74fe4b1f56a43d109c6ac0c35;hp=6836be3e906836337d067ee2eeb09e3cc858f272;hb=499f29d24922cec66e41b41a0039a954993bc6df;hpb=6d32f944a0a115b6419184c50b57bf7c4eef5786 diff --git a/src/SMESHUtils/SMESH_TryCatch.cxx b/src/SMESHUtils/SMESH_TryCatch.cxx index 6836be3e9..b808a791b 100644 --- a/src/SMESHUtils/SMESH_TryCatch.cxx +++ b/src/SMESHUtils/SMESH_TryCatch.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2019 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2022 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -30,6 +30,7 @@ void SMESH::throwSalomeEx(const char* txt) void SMESH::doNothing(const char* txt) { + (void)txt; // unused in release mode MESSAGE( txt << " " << __FILE__ << ": " << __LINE__ ); } @@ -38,6 +39,15 @@ const char* SMESH::returnError(const char* txt) return txt; } +void SMESH::printErrorInDebugMode(const char* txt) +{ +#ifdef _DEBUG_ + std::cerr << txt << " " << __FILE__ << ": " << __LINE__ << std::endl; +#else + (void)txt; // unused in release mode +#endif +} + // ------------------------------------------------------------------ #include "SMESH_ComputeError.hxx"