summaryrefslogtreecommitdiff
path: root/src/engine/SCons/Builder.py
diff options
context:
space:
mode:
authorLuca Falavigna <dktrkranz@debian.org>2010-03-10 14:14:26 +0100
committerLuca Falavigna <dktrkranz@debian.org>2010-03-10 14:14:26 +0100
commit68e4fe5ac49effe8959bc8532584edf04553c931 (patch)
tree1cd0c82c13789d61dc62758f326ae4dce1dd6f37 /src/engine/SCons/Builder.py
parent48f19e9e5ecc069f379ad433fdaf280ac9b54e16 (diff)
Imported Upstream version 1.2.0.d20100306upstream/1.2.0.d20100306
Diffstat (limited to 'src/engine/SCons/Builder.py')
-rw-r--r--src/engine/SCons/Builder.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/engine/SCons/Builder.py b/src/engine/SCons/Builder.py
index fb41ae4..bf35b1e 100644
--- a/src/engine/SCons/Builder.py
+++ b/src/engine/SCons/Builder.py
@@ -98,7 +98,7 @@ There are the following methods for internal use within this module:
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
-__revision__ = "src/engine/SCons/Builder.py 4629 2010/01/17 22:23:21 scons"
+__revision__ = "src/engine/SCons/Builder.py 4691 2010/03/06 16:22:36 bdbaddog"
import UserDict
import UserList
@@ -861,6 +861,16 @@ class CompositeBuilder(SCons.Util.Proxy):
self.cmdgen.add_action(suffix, action)
self.set_src_suffix(self.cmdgen.src_suffixes())
+def is_a_Builder(obj):
+ """"Returns True iff the specified obj is one of our Builder classes.
+
+ The test is complicated a bit by the fact that CompositeBuilder
+ is a proxy, not a subclass of BuilderBase.
+ """
+ return (isinstance(obj, BuilderBase)
+ or isinstance(obj, CompositeBuilder)
+ or callable(obj))
+
# Local Variables:
# tab-width:4
# indent-tabs-mode:nil