Changeset 1f1b109 in tol
- Timestamp:
- May 10, 2011, 10:55:08 AM (15 years ago)
- Branches:
- 1941-docker-image-to-test, devel, master
- Children:
- eb88c70
- Parents:
- 10adcbf
- Location:
- tol
- Files:
-
- 4 edited
-
OIS/oiscreator.cpp (modified) (1 diff)
-
OIS/oisloader.cpp (modified) (3 diffs)
-
bbasic/out.cpp (modified) (3 diffs)
-
bbasic/tol_bout.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
tol/OIS/oiscreator.cpp
r10adcbf r1f1b109 1034 1034 { 1035 1035 EWrite(saveTree,timeset_); 1036 #ifdef WARNING_NON_TREE_NOR_BOUNDED1037 1036 Warning(I2("Cannot save virtual definition non bounded TimeSet ", 1038 1037 "No se puede salvar la definición virtual del TimeSet ")+v->Identify()+ 1039 1038 I2(" due to its expression is unknown at this evaluation level.", 1040 1039 " no acotado porque su expresión es desconocida en este nivel de evaluación.")); 1041 #endif1042 1040 } 1041 else 1042 { 1043 int oldLevel = BGrammar::Level(); 1044 BGrammar::PutLevel(0); 1045 bool oldEnabled = BOut::Disable(); 1046 BDat numErr0 = TOLErrorTryNumber(); 1047 BUserTimeSet* aux = (BUserTimeSet*)GraTimeSet()->EvaluateTree(tree); 1048 BDat numErr1 = TOLErrorTryNumber(); 1049 if(oldEnabled) { BOut::Enable(); } 1050 DESTROY(aux); 1051 if(numErr1>numErr0) 1052 { 1053 BText expr = Compact(BParser::Unparse(tree," ","\n")); 1054 if(v->HasName()) { expr = v->Name()+" = "+expr; } 1055 Warning(I2("Expression of non bounded TimeSet ", 1056 "La expresión del TimeSet no acotado ")+ 1057 "\n"+expr+";\n"+ 1058 I2("seems to be dependent on non globally accessible symbols.\n" 1059 "So, just cached data will be available at OIS loading time.\n" 1060 "Current cache interval is ", 1061 "parece depender de símbolos que no son accesibles globalmente.\n" 1062 "Por este motivo, a la hora de cargar el OIS, sólo podrán usarse " 1063 "los datos de la caché, que actualmente abarca el intervalo ")+ 1064 "["+beginCache+","+endCache+"]"); 1065 } 1066 BGrammar::PutLevel(oldLevel); 1067 } 1043 1068 saveTree = true; 1044 1069 EWrite(saveTree,timeset_); -
tol/OIS/oisloader.cpp
r10adcbf r1f1b109 1419 1419 name+"' description='"+description+"')")); 1420 1420 } 1421 BText expr = Compact(BParser::Unparse(tree," ","\n")); 1422 //bool oldEnabled = BOut::Disable(); 1423 BDat numErr0 = TOLErrorNumber(); 1421 bool oldEnabled = BOut::Disable(); 1422 BDat numErr0 = TOLErrorTryNumber(); 1424 1423 x = (BUserTimeSet*)GraTimeSet()->EvaluateTree(tree); 1425 BDat numErr1 = TOLError Number();1424 BDat numErr1 = TOLErrorTryNumber(); 1426 1425 if(numErr0<numErr1) { DESTROY(x); } 1427 //if(oldEnabled) { BOut::Enable(); }1426 if(oldEnabled) { BOut::Enable(); } 1428 1427 if(x) 1429 1428 { … … 1435 1434 x->PutCache(h, beginCache, endCache); 1436 1435 } 1436 x->PutOisTree(tree); 1437 1437 } 1438 x->PutOisTree(tree);1439 1438 tree->Destroy(); 1440 1439 } … … 1442 1441 { 1443 1442 BText expr = Compact(BParser::Unparse(tree," ","\n")); 1444 #ifndef NDEBUG1443 if(name.HasName()) { expr = name+" = "+expr; } 1445 1444 Warning(BText("Cannot rebuild virtual expression of non " 1446 "bounded TimeSet ")+ name+"="+expr+ "\nOnly cached "1445 "bounded TimeSet ")+expr+ "\nOnly cached " 1447 1446 "dates will be accessible between ["+beginCache+","+ 1448 1447 endCache+"]\nTo avoid this problem save just " 1449 "bounded time sets " );1450 #endif1448 "bounded time sets or use expressions that could " 1449 "be evaluated at OIS loading time." ); 1451 1450 if(tree) { tree->Destroy(); } 1452 1451 } -
tol/bbasic/out.cpp
r10adcbf r1f1b109 233 233 }; 234 234 235 //-------------------------------------------------------------------- 236 BDat& TOLErrorTryNumber() 237 //-------------------------------------------------------------------- 238 { 239 static BDat aux_ = 0; 240 return(aux_); 241 }; 242 243 //-------------------------------------------------------------------- 244 BDat& TOLWarningTryNumber() 245 //-------------------------------------------------------------------- 246 { 247 static BDat aux_ = 0; 248 return(aux_); 249 }; 250 235 251 236 252 //-------------------------------------------------------------------- … … 427 443 //-------------------------------------------------------------------- 428 444 { 445 TOLErrorTryNumber()+=1; 429 446 if(!BOut::IsEnabled() || 430 447 (!BOut::errorHci_ && !BOut::errorTerm_ && !BOut::errorLog_)) { return; } … … 448 465 //-------------------------------------------------------------------- 449 466 { 467 TOLWarningTryNumber()+=1; 450 468 if(!BOut::IsEnabled() || 451 469 (!BOut::warningHci_ && !BOut::warningTerm_ && !BOut::warningLog_)) { return; } -
tol/bbasic/tol_bout.h
r10adcbf r1f1b109 36 36 TOL_API BDat& TOLErrorNumber(); 37 37 TOL_API BDat& TOLWarningNumber(); 38 TOL_API BDat& TOLErrorTryNumber(); 39 TOL_API BDat& TOLWarningTryNumber(); 38 40 39 41 //--------------------------------------------------------------------
Note: See TracChangeset
for help on using the changeset viewer.
