Changeset 7efd6dd in tol
- Timestamp:
- Dec 27, 2010, 8:50:49 AM (16 years ago)
- Branches:
- 1941-docker-image-to-test, devel, master
- Children:
- f4cc2f5
- Parents:
- 137d85f
- Location:
- tol
- Files:
-
- 3 edited
-
btol/bgrammar/nameblock.cpp (modified) (3 diffs)
-
btol/bgrammar/tol_bnameblock.h (modified) (1 diff)
-
lang/language.cpp (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
tol/btol/bgrammar/nameblock.cpp
r137d85f r7efd6dd 103 103 nonPrivateMembers_(0), 104 104 requiredPackages_(NULL), 105 doingRebuildFullNameDeep(false) 105 doingRebuildFullNameDeep(false), 106 startedPackage(false) 106 107 { 107 108 SetEmptyKey(public_ ,NULL); … … 126 127 nonPrivateMembers_(0), 127 128 requiredPackages_(NULL), 128 doingRebuildFullNameDeep(false) 129 doingRebuildFullNameDeep(false), 130 startedPackage(false) 129 131 { 130 132 SetEmptyKey(public_ ,NULL); … … 149 151 nonPrivateMembers_(0), 150 152 requiredPackages_(NULL), 151 doingRebuildFullNameDeep(false) 153 doingRebuildFullNameDeep(false), 154 startedPackage(false) 152 155 { 153 156 short isAssigned = BFSMEM_Hndlr->IsAssigned(this,this->_bfsm_PageNum__); -
tol/btol/bgrammar/tol_bnameblock.h
r137d85f r7efd6dd 88 88 bool doingRebuildFullNameDeep; 89 89 public: 90 bool startedPackage; 90 91 static bool Initialize(); 91 92 static BNameBlock& Unknown() { return(*unknown_); } -
tol/lang/language.cpp
r137d85f r7efd6dd 1331 1331 BOis::SetRunningUseModule(oldRunningUseModule); 1332 1332 if(!fai) { return(false); } 1333 bool ok = (bool) Real(fai);1333 bool ok = (bool)(Real(fai)!=0); 1334 1334 DESTROY(fai); 1335 1335 return(ok); 1336 } 1337 1338 //-------------------------------------------------------------------- 1339 static void PkgStartActions(const BText& package, const BText path) 1340 //-------------------------------------------------------------------- 1341 { 1342 BText startActionsExpr = package+"::StartActions(0)"; 1343 bool oldRunningUseModule = BOis::SetRunningUseModule(false); 1344 BText oldDir = BDir::GetCurrent(); 1345 BDir::ChangeCurrent( GetFilePath(path) ); 1346 BSyntaxObject* startActions = GraReal()->EvaluateExpr(startActionsExpr); 1347 BDir::ChangeCurrent(oldDir); 1348 BOis::SetRunningUseModule(oldRunningUseModule); 1349 //Std(BText("\nTRACE startActionsExpr =")+startActionsExpr+" "+((startActions)?"OK":"FAIL")+"\n"); 1350 DESTROY(startActions); 1336 1351 } 1337 1352 … … 1366 1381 } 1367 1382 BSyntaxObject* pkg = GraNameBlock()->FindOperand(package,false); 1368 bool ok = pkg!=NULL;1369 if(ok) { return(pkg); }1370 1383 BText path = LocalPath(package_version); 1371 1384 //Std(BText("\nTRACE BPackage::Load 3 path='")+path+"'"); 1372 1385 BDir dirPath = path; 1386 1387 bool ok = pkg!=NULL; 1388 if(ok) { 1389 BNameBlock& nb = NameBlock(pkg); 1390 if(!nb.startedPackage) 1391 { 1392 PkgStartActions(package, path); 1393 nb.startedPackage = true; 1394 } 1395 return(pkg); 1396 } 1373 1397 //Std(BText("\nTRACE BPackage::Load 3 dirPath='")+dirPath.Name()+"'"); 1374 1398 if(!ok) 1375 1399 { 1376 ok=dirPath.Exist() ;1400 ok=dirPath.Exist()!=0; 1377 1401 if(!ok) 1378 1402 { … … 1385 1409 zip.Close(); 1386 1410 } 1387 ok=dirPath.Exist() ;1411 ok=dirPath.Exist()!=0; 1388 1412 } 1389 1413 //Std(BText("\nTRACE BPackage::Load 4 ok=")+ok); … … 1412 1436 required_ = Cons(pkg, required_); 1413 1437 BNameBlock::AddGlobalRequiredPackage(package); 1414 BText startActionsExpr = package+"::StartActions(0)"; 1415 bool oldRunningUseModule = BOis::SetRunningUseModule(false); 1416 BText oldDir = BDir::GetCurrent(); 1417 BDir::ChangeCurrent( GetFilePath(path) ); 1418 BSyntaxObject* startActions = GraReal()->EvaluateExpr(startActionsExpr); 1419 BDir::ChangeCurrent(oldDir); 1420 BOis::SetRunningUseModule(oldRunningUseModule); 1421 //Std(BText("\nTRACE startActionsExpr =")+startActionsExpr+" "+((startActions)?"OK":"FAIL")+"\n"); 1422 DESTROY(startActions); 1438 PkgStartActions(package, path); 1423 1439 } 1424 1440 }
Note: See TracChangeset
for help on using the changeset viewer.
