Author: matz Date: Mon Nov 26 02:03:14 2007 New Revision: 7919 URL: http://svn.opensuse.org/viewcvs/zypp?rev=7919&view=rev Log: Rewrite some uses of for_each + boost::bind, which are going to not work anymore with the new CapSet (the forwarding problem). Modified: branches/use-solv/libzypp/zypp/ui/PatternExpander.cc Modified: branches/use-solv/libzypp/zypp/ui/PatternExpander.cc URL: http://svn.opensuse.org/viewcvs/zypp/branches/use-solv/libzypp/zypp/ui/PatternExpander.cc?rev=7919&r1=7918&r2=7919&view=diff ============================================================================== --- branches/use-solv/libzypp/zypp/ui/PatternExpander.cc (original) +++ branches/use-solv/libzypp/zypp/ui/PatternExpander.cc Mon Nov 26 02:03:14 2007 @@ -82,9 +82,9 @@ { if ( ! pat_r->includes().empty() ) { - for_each( pat_r->includes().begin(), - pat_r->includes().end(), - bind( &Impl::expandInclude, this, _1 ) ); + CapSet::const_iterator i = pat_r->includes().begin(); + for (; i != pat_r->includes().end(); ++i) + expandInclude (*i); } } @@ -117,18 +117,15 @@ { Pattern::constPtr extending( asKind<Pattern>(extending_r) ); - if ( ! extending->extends().empty() ) - { - if ( find_if( extending->extends().begin(), - extending->extends().end(), - bind( &Impl::providedBy, this, pat_r, _1 ) ) - != extending->extends().end() ) - { - // an extends matches the Pattern - _patternMap[extending]; - //DBG << mapEntry(*_patternMap.find(extending)) << endl; - } - } + CapSet::const_iterator i = extending->extends().begin(); + for (; i != extending->extends().end(); ++i) + if (providedBy (pat_r, *i)) + { + // an extends matches the Pattern + _patternMap[extending]; + //DBG << mapEntry(*_patternMap.find(extending)) << endl; + break; + } } /** Return true if Capability \c extends_r is provided by Pattern. */ -- To unsubscribe, e-mail: zypp-commit+unsubscribe@opensuse.org For additional commands, e-mail: zypp-commit+help@opensuse.org