summaryrefslogtreecommitdiff
path: root/src/engine/SCons/Node
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2019-12-29 15:50:38 +0100
committerJörg Frings-Fürst <debian@jff-webhosting.net>2019-12-29 15:50:38 +0100
commitc7ed3af5765539e212ecd5f93bd7ea5f9785bc25 (patch)
tree586ea369a93cb817c45c47dc2609ab58648f94ab /src/engine/SCons/Node
parentc7665433b2004d2b404d6fb9d6fd064998486f63 (diff)
parente2cfc8f485631bfd5f61d4af1921c7346a062875 (diff)
Merge branch 'release/debian/3.1.2+repack-1'debian/3.1.2+repack-1
Diffstat (limited to 'src/engine/SCons/Node')
-rw-r--r--src/engine/SCons/Node/Alias.py2
-rw-r--r--src/engine/SCons/Node/AliasTests.py2
-rw-r--r--src/engine/SCons/Node/FS.py14
-rw-r--r--src/engine/SCons/Node/FSTests.py9
-rw-r--r--src/engine/SCons/Node/NodeTests.py2
-rw-r--r--src/engine/SCons/Node/Python.py2
-rw-r--r--src/engine/SCons/Node/PythonTests.py2
-rw-r--r--src/engine/SCons/Node/__init__.py15
8 files changed, 23 insertions, 25 deletions
diff --git a/src/engine/SCons/Node/Alias.py b/src/engine/SCons/Node/Alias.py
index a9defb6..5c62677 100644
--- a/src/engine/SCons/Node/Alias.py
+++ b/src/engine/SCons/Node/Alias.py
@@ -30,7 +30,7 @@ This creates a hash of global Aliases (dummy targets).
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
-__revision__ = "src/engine/SCons/Node/Alias.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/Alias.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import collections
diff --git a/src/engine/SCons/Node/AliasTests.py b/src/engine/SCons/Node/AliasTests.py
index 764ac67..40f3ff3 100644
--- a/src/engine/SCons/Node/AliasTests.py
+++ b/src/engine/SCons/Node/AliasTests.py
@@ -21,7 +21,7 @@
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
-__revision__ = "src/engine/SCons/Node/AliasTests.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/AliasTests.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import sys
import unittest
diff --git a/src/engine/SCons/Node/FS.py b/src/engine/SCons/Node/FS.py
index 21ccecc..65d1ac1 100644
--- a/src/engine/SCons/Node/FS.py
+++ b/src/engine/SCons/Node/FS.py
@@ -33,7 +33,7 @@ that can be used by scripts or modules looking for the canonical default.
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
from __future__ import print_function
-__revision__ = "src/engine/SCons/Node/FS.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/FS.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import fnmatch
import os
@@ -963,14 +963,14 @@ class Entry(Base):
def disambiguate(self, must_exist=None):
"""
- """
- if self.isdir():
- self.__class__ = Dir
- self._morph()
- elif self.isfile():
+ """
+ if self.isfile():
self.__class__ = File
self._morph()
self.clear()
+ elif self.isdir():
+ self.__class__ = Dir
+ self._morph()
else:
# There was nothing on-disk at this location, so look in
# the src directory.
@@ -3436,6 +3436,8 @@ class File(Base):
Boolean - Indicates if node(File) has changed.
"""
+ if node is None:
+ node = self
# Now get sconsign name -> csig map and then get proper prev_ni if possible
bi = node.get_stored_info().binfo
rebuilt = False
diff --git a/src/engine/SCons/Node/FSTests.py b/src/engine/SCons/Node/FSTests.py
index 2366a4d..3b4d78b 100644
--- a/src/engine/SCons/Node/FSTests.py
+++ b/src/engine/SCons/Node/FSTests.py
@@ -22,7 +22,7 @@
#
from __future__ import division, print_function
-__revision__ = "src/engine/SCons/Node/FSTests.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/FSTests.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import SCons.compat
@@ -2545,11 +2545,10 @@ class FileTestCase(_tempdirTestCase):
def get_ninfo(self):
""" mocked to ensure csig will equal the filename"""
- try:
- return self.ninfo
- except AttributeError:
- self.ninfo = FakeNodeInfo(self.name, self.timestamp)
+ if self.ninfo is not None:
return self.ninfo
+ self.ninfo = FakeNodeInfo(self.name, self.timestamp)
+ return self.ninfo
def get_csig(self):
ninfo = self.get_ninfo()
diff --git a/src/engine/SCons/Node/NodeTests.py b/src/engine/SCons/Node/NodeTests.py
index ce44b7d..3e186de 100644
--- a/src/engine/SCons/Node/NodeTests.py
+++ b/src/engine/SCons/Node/NodeTests.py
@@ -20,7 +20,7 @@
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-__revision__ = "src/engine/SCons/Node/NodeTests.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/NodeTests.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import SCons.compat
diff --git a/src/engine/SCons/Node/Python.py b/src/engine/SCons/Node/Python.py
index d338051..ec23b3f 100644
--- a/src/engine/SCons/Node/Python.py
+++ b/src/engine/SCons/Node/Python.py
@@ -27,7 +27,7 @@ Python nodes.
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
-__revision__ = "src/engine/SCons/Node/Python.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/Python.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import SCons.Node
diff --git a/src/engine/SCons/Node/PythonTests.py b/src/engine/SCons/Node/PythonTests.py
index 98137c7..94501d2 100644
--- a/src/engine/SCons/Node/PythonTests.py
+++ b/src/engine/SCons/Node/PythonTests.py
@@ -21,7 +21,7 @@
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
-__revision__ = "src/engine/SCons/Node/PythonTests.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/PythonTests.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import sys
import unittest
diff --git a/src/engine/SCons/Node/__init__.py b/src/engine/SCons/Node/__init__.py
index 5455bd6..32f4bba 100644
--- a/src/engine/SCons/Node/__init__.py
+++ b/src/engine/SCons/Node/__init__.py
@@ -43,7 +43,7 @@ from __future__ import print_function
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-__revision__ = "src/engine/SCons/Node/__init__.py e724ae812eb96f4858a132f5b8c769724744faf6 2019-07-21 00:04:47 bdeegan"
+__revision__ = "src/engine/SCons/Node/__init__.py bee7caf9defd6e108fc2998a2520ddb36a967691 2019-12-17 02:07:09 bdeegan"
import os
import collections
@@ -614,6 +614,7 @@ class Node(object, with_metaclass(NoSlotsPyPy)):
self._func_rexists = 1
self._func_get_contents = 0
self._func_target_from_source = 0
+ self.ninfo = None
self.clear_memoized_values()
@@ -1131,11 +1132,10 @@ class Node(object, with_metaclass(NoSlotsPyPy)):
return ninfo
def get_ninfo(self):
- try:
- return self.ninfo
- except AttributeError:
- self.ninfo = self.new_ninfo()
+ if self.ninfo is not None:
return self.ninfo
+ self.ninfo = self.new_ninfo()
+ return self.ninfo
def new_binfo(self):
binfo = self.BuildInfo()
@@ -1661,10 +1661,7 @@ class Node(object, with_metaclass(NoSlotsPyPy)):
if k not in old_bkids:
lines.append("`%s' is a new dependency\n" % stringify(k))
else:
- try:
- changed = _decider_map[k.changed_since_last_build](k, self, osig[k])
- except DeciderNeedsNode as e:
- changed = e.decider(self, osig[k], node=self)
+ changed = _decider_map[k.changed_since_last_build](k, self, osig[k])
if changed:
lines.append("`%s' changed\n" % stringify(k))