[MOAB-dev] r5512 - in MOAB/trunk: src tools/mbcoupler
tautges at mcs.anl.gov
tautges at mcs.anl.gov
Sun Apr 29 18:34:51 CDT 2012
Author: tautges
Date: 2012-04-29 18:34:51 -0500 (Sun, 29 Apr 2012)
New Revision: 5512
Modified:
MOAB/trunk/src/DenseTag.cpp
MOAB/trunk/src/MeshTag.cpp
MOAB/trunk/src/SparseTag.cpp
MOAB/trunk/src/VarLenDenseTag.cpp
MOAB/trunk/src/VarLenSparseTag.cpp
MOAB/trunk/tools/mbcoupler/Coupler.cpp
Log:
1. Adding tag name to the diagnostics when a tag isn't found.
2. Fixing an error I'd introduced when I added tolerances to Coupler calls. Turns out Iulian
called me on that one too, again a few days ago. Sigh.
Modified: MOAB/trunk/src/DenseTag.cpp
===================================================================
--- MOAB/trunk/src/DenseTag.cpp 2012-04-29 14:58:14 UTC (rev 5511)
+++ MOAB/trunk/src/DenseTag.cpp 2012-04-29 23:34:51 UTC (rev 5512)
@@ -15,23 +15,25 @@
namespace moab {
-static ErrorCode not_found( Error* error, EntityHandle h )
+ static ErrorCode not_found( Error* error, std::string name, EntityHandle h )
{
if (h)
- error->set_last_error( "No tag value for %s %ld",
- CN::EntityTypeName(TYPE_FROM_HANDLE(h)),
- (unsigned long)ID_FROM_HANDLE(h));
+ error->set_last_error( "No dense tag %s value for %s %ld",
+ name.c_str(),
+ CN::EntityTypeName(TYPE_FROM_HANDLE(h)),
+ (unsigned long)ID_FROM_HANDLE(h));
else
error->set_last_error( "No tag value for root set" );
return MB_TAG_NOT_FOUND;
}
-static ErrorCode ent_not_found( Error* error, EntityHandle h )
+ static ErrorCode ent_not_found( Error* error, std::string name, EntityHandle h )
{
- error->set_last_error( "Invalid entity handle: %s %ld",
- CN::EntityTypeName(TYPE_FROM_HANDLE(h)),
- (unsigned long)ID_FROM_HANDLE(h));
+ error->set_last_error( "Invalid entity handle setting tag %s: %s %ld",
+ name.c_str(),
+ CN::EntityTypeName(TYPE_FROM_HANDLE(h)),
+ (unsigned long)ID_FROM_HANDLE(h));
return MB_ENTITY_NOT_FOUND;
}
@@ -109,7 +111,7 @@
else { // not root set
ptr = 0;
count = 0;
- return ent_not_found( error, h );
+ return ent_not_found( error, get_name(), h );
}
}
@@ -158,7 +160,7 @@
else { // not root set
ptr = 0;
count = 0;
More information about the moab-dev
mailing list