diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2017-09-28 12:18:58 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2017-09-28 12:18:58 +0200 |
commit | baee03c569c91b745a1e025660b19a718db16e7d (patch) | |
tree | 1aaa25835bd24c5c95649cd8ab34d97bafded599 /src/engine/SCons/Executor.py | |
parent | 4c7fed99e5554ba71d62987c0ec5f1302011b122 (diff) |
New upstream version 3.0.0upstream/3.0.0
Diffstat (limited to 'src/engine/SCons/Executor.py')
-rw-r--r-- | src/engine/SCons/Executor.py | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/src/engine/SCons/Executor.py b/src/engine/SCons/Executor.py index 3078bfa..9fabf70 100644 --- a/src/engine/SCons/Executor.py +++ b/src/engine/SCons/Executor.py @@ -6,7 +6,7 @@ Nodes. """ # -# Copyright (c) 2001 - 2016 The SCons Foundation +# Copyright (c) 2001 - 2017 The SCons Foundation # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentation files (the @@ -26,8 +26,9 @@ Nodes. # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +from __future__ import print_function -__revision__ = "src/engine/SCons/Executor.py rel_2.5.1:3735:9dc6cee5c168 2016/11/03 14:02:02 bdbaddog" +__revision__ = "src/engine/SCons/Executor.py rel_3.0.0:4395:8972f6a2f699 2017/09/18 12:59:24 bdbaddog" import collections @@ -35,7 +36,7 @@ import SCons.Debug from SCons.Debug import logInstanceCreation import SCons.Errors import SCons.Memoize - +from SCons.compat import with_metaclass, NoSlotsPyPy class Batch(object): """Remembers exact association between targets @@ -154,7 +155,7 @@ _execute_str_map = {0 : execute_null_str, 1 : execute_actions_str} -class Executor(object): +class Executor(object, with_metaclass(NoSlotsPyPy)): """A class for controlling instances of executing an action. This largely exists to hold a single association of an action, @@ -455,10 +456,16 @@ class Executor(object): except KeyError: pass env = self.get_build_env() - result = "".join([action.get_contents(self.get_all_targets(), - self.get_all_sources(), - env) - for action in self.get_action_list()]) + + action_list = self.get_action_list() + all_targets = self.get_all_targets() + all_sources = self.get_all_sources() + + result = bytearray("",'utf-8').join([action.get_contents(all_targets, + all_sources, + env) + for action in action_list]) + self._memo['get_contents'] = result return result @@ -580,7 +587,7 @@ def get_NullEnvironment(): nullenv = NullEnvironment() return nullenv -class Null(object): +class Null(object, with_metaclass(NoSlotsPyPy)): """A null Executor, with a null build Environment, that does nothing when the rest of the methods call it. |