|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r48586 - trunk/tools/build/v2/build
From: jurko.gospodnetic_at_[hidden]
Date: 2008-09-04 17:35:19
Author: jurko
Date: 2008-09-04 17:35:18 EDT (Thu, 04 Sep 2008)
New Revision: 48586
URL: http://svn.boost.org/trac/boost/changeset/48586
Log:
Optimized Boost Build's generator selection related viable-source-types-for-generator-real() rule. Now it exits more quickly in case it detects that any source type is a viable source type and so there is no need to look for more viable source types.
Text files modified:
trunk/tools/build/v2/build/generators.jam | 19 +++++++++++--------
1 files changed, 11 insertions(+), 8 deletions(-)
Modified: trunk/tools/build/v2/build/generators.jam
==============================================================================
--- trunk/tools/build/v2/build/generators.jam (original)
+++ trunk/tools/build/v2/build/generators.jam 2008-09-04 17:35:18 EDT (Thu, 04 Sep 2008)
@@ -804,15 +804,18 @@
local result ;
for local s in $(source-types)
{
- result += [ type.all-derived $(s) ] [ generators.viable-source-types
- $(s) ] ;
- }
- result = [ sequence.unique $(result) ] ;
- if * in $(result)
- {
- result = * ;
+ local viable-sources = [ generators.viable-source-types $(s) ] ;
+ if $(viable-sources) = *
+ {
+ result = * ;
+ source-types = ; # Terminate the loop.
+ }
+ else
+ {
+ result += [ type.all-derived $(s) ] $(viable-sources) ;
+ }
}
- return $(result) ;
+ return [ sequence.unique $(result) ] ;
}
}
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk