"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "engine/SCons/Subst.py" between
scons-3.0.1.tar.gz and scons-3.0.2.tar.gz

About: SCons is a software construction tool (a Python script and a set of modules as a superior alternative to the classic "Make" build tool).

Subst.py  (scons-3.0.1):Subst.py  (scons-3.0.2)
"""SCons.Subst """SCons.Subst
SCons string substitution. SCons string substitution.
""" """
# #
# Copyright (c) 2001 - 2017 The SCons Foundation # Copyright (c) 2001 - 2018 The SCons Foundation
# #
# Permission is hereby granted, free of charge, to any person obtaining # Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the # a copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including # "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publish, # without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and to # distribute, sublicense, and/or sell copies of the Software, and to
# permit persons to whom the Software is furnished to do so, subject to # permit persons to whom the Software is furnished to do so, subject to
# the following conditions: # the following conditions:
# #
# The above copyright notice and this permission notice shall be included # The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software. # in all copies or substantial portions of the Software.
# #
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE # KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND # WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION # LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
__revision__ = "src/engine/SCons/Subst.py 74b2c53bc42290e911b334a6b44f187da698a6 68 2017/11/14 13:16:53 bdbaddog" __revision__ = "src/engine/SCons/Subst.py 425375072d7b582a2df0db815c8eaeaa489468 ab 2019-01-01 18:32:02 bdbaddog"
import collections import collections
import re import re
import SCons.Errors import SCons.Errors
from SCons.Util import is_String, is_Sequence from SCons.Util import is_String, is_Sequence
# Indexed by the SUBST_* constants below. # Indexed by the SUBST_* constants below.
_strconv = [SCons.Util.to_String_for_subst, _strconv = [SCons.Util.to_String_for_subst,
skipping to change at line 85 skipping to change at line 85
return 1 return 1
def __eq__(self, other): def __eq__(self, other):
if not isinstance(other, Literal): if not isinstance(other, Literal):
return False return False
return self.lstr == other.lstr return self.lstr == other.lstr
def __neq__(self, other): def __neq__(self, other):
return not self.__eq__(other) return not self.__eq__(other)
def __hash__(self):
return hash(self.lstr)
class SpecialAttrWrapper(object): class SpecialAttrWrapper(object):
"""This is a wrapper for what we call a 'Node special attribute.' """This is a wrapper for what we call a 'Node special attribute.'
This is any of the attributes of a Node that we can reference from This is any of the attributes of a Node that we can reference from
Environment variable substitution, such as $TARGET.abspath or Environment variable substitution, such as $TARGET.abspath or
$SOURCES[1].filebase. We implement the same methods as Literal $SOURCES[1].filebase. We implement the same methods as Literal
so we can handle special characters, plus a for_signature method, so we can handle special characters, plus a for_signature method,
such that we can return some canonical string during signature such that we can return some canonical string during signature
calculation to avoid unnecessary rebuilds.""" calculation to avoid unnecessary rebuilds."""
def __init__(self, lstr, for_signature=None): def __init__(self, lstr, for_signature=None):
 End of changes. 3 change blocks. 
2 lines changed or deleted 5 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)