diff options
author | Carn? Draug <carandraug+dev@gmail.com> | 2013-02-15 05:00:53 +0000 |
---|---|---|
committer | Carn? Draug <carandraug+dev@gmail.com> | 2013-02-15 05:00:53 +0000 |
commit | 7f7db8f6dc2b2ab0c4975426c367b4e08fa6014c (patch) | |
tree | c0e3d7d4371698fe617ed64ae2cdb429adddd55e | |
parent | 15c78eedb1cf05972be69bcdf68da5f34cdf5479 (diff) | |
download | scons-7f7db8f6dc2b2ab0c4975426c367b4e08fa6014c.tar.gz |
Allow NoneType for CheckContext.Result
-rw-r--r-- | src/engine/SCons/SConf.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/engine/SCons/SConf.py b/src/engine/SCons/SConf.py index 0506f806..584c433a 100644 --- a/src/engine/SCons/SConf.py +++ b/src/engine/SCons/SConf.py @@ -35,6 +35,7 @@ import os import re import sys import traceback +import types import SCons.Action import SCons.Builder @@ -776,11 +777,12 @@ class CheckContext(object): self.did_show_result = 0 def Result(self, res): - """Inform about the result of the test. res may be an integer or a - string. In case of an integer, the written text will be 'yes' or 'no'. - The result is only displayed when self.did_show_result is not set. + """Inform about the result of the test. res may be an integer, a + string, or a boolean. In case of an integer, the written text will be + 'yes' or 'no'. The result is only displayed when self.did_show_result + is not set. """ - if isinstance(res, (int, bool)): + if isinstance(res, (int, bool, types.NoneType)): if res: text = "yes" else: |