void ClassLattice::derivedClasses( WVList & symlist ) //--------------------------------------------------- { loadDeriveds(); for( int i = 0; i < _deriveds.count(); i += 1 ) { symlist.add( _deriveds[ i ]->_class ); } }
void ClassLattice::baseClasses( WVList & symlist ) //------------------------------------------------ { loadBases(); for( int i = 0; i < _bases.count(); i += 1 ) { symlist.add( _bases[ i ]->_class ); } }
void MComponent::addWorkFiles( WVList& workFiles, SwMode mode, MComponent* comp ) { for( int i=0; i<_items.count(); i++ ) { MItem* m = (MItem*)_items[i]; WFileName f; m->absName( f ); MWorkFile* w = new MWorkFile( f, mode, m, comp ); workFiles.add( w ); } }
void MComponent::getMaskItems( WVList& list ) { int icount = _items.count(); for( int i=0; i<icount; i++ ) { MItem* m = (MItem*)_items[i]; if( m->isMask() ) { list.add( m ); } } }
void MConfig::addRules( WFileName& srcMask, WFileName& tgtMask, WVList& list, WString& tagMask ) { int icount = _rules.count(); for( int i=0; i<icount; i++ ) { MRule* rule = (MRule*)_rules[i]; if( rule->match( tagMask, srcMask, tgtMask ) ) { list.add( rule ); } } }
void MItem::addStates( WVList& list, SwMode mode ) { int icount = _states.count(); for( int i=0; i<icount; i++ ) { MState* st = (MState*)_states[i]; if( st->mode() == mode ) { list.add( _states[i] ); } } }
int MConfig::findMatchingRules( WFileName& fn, WString& mask, WVList& list ) { int icount = _rules.count(); for( int i=0; i<icount; i++ ) { MRule* rule = (MRule*)_rules[i]; if( rule->match( mask, fn ) ) { list.add( rule ); } } return( list.count() ); }
void MTool::addFamilies( WVList& list ) { int icount = _families.count(); for( int i = 0; i < icount; i++ ) { list.add( _families[i] ); } icount = _incTools.count(); for( int i = 0; i < icount; i++ ) { MTool* tool = (MTool*)_incTools[i]; tool->addFamilies( list ); } }
void MItem::addActions( WFileName& fn, WVList& list ) { WVList rules; if( _config->findMatchingRules( fn, _component->mask(), rules ) ) { for( int i=0; i<rules.count(); i++ ) { MRule* r = (MRule*)rules[i]; for( int j=0; j<r->actions().count(); j++ ) { list.add( r->actions()[j] ); } } } }
static bool referenceHook( drmem_hdl, dr_ref_info * refinfo, char * name, void * info ) //----------------------------------------------------------------------- { Reference * ref; WVList * list = (WVList *) info; for( int i = 0; i < list->count(); i++ ) { ref = (Reference *) (*list)[i]; if( ref->line() == refinfo->line && ref->column() == refinfo->column && strcmp( ref->sourceFile(), refinfo->file ) == 0 ) { WBRFree( name ); return true; } } list->add( new Reference( refinfo, name ) ); return true; // keep going }
int MItem::addActions( WVList& list ) { if( !_isTarget ) { //add actions for Source addActions( *this, list ); } //add actions for result int ocount = list.count(); int icount = _rule->actions().count(); for( int i=0; i<icount; i++ ) { list.add( _rule->actions()[i] ); } WFileName fn; if( result( fn ) ) { addActions( fn, list ); } return( ocount ); }
void MWorkFile::addStates( WVList& states ) { for( int i=0; i<_states.count(); i++ ) { states.add( _states[i] ); } }