[Scons-users] Module Scons.Util

James Rinkevich rinkevichjm at gmail.com
Sun Oct 1 13:16:27 EDT 2017


in this function
def to_String_for_subst(s,
                        isinstance=isinstance, str=str, to_String=to_String,
                        BaseStringTypes=BaseStringTypes,
SequenceTypes=SequenceTypes,
                        UserString=UserString):

    # Note that the test cases are sorted by order of probability.
    if isinstance(s, BaseStringTypes):
        return s
    elif isinstance(s, SequenceTypes):
        l = []
        for e in s:
            l.append(to_String_for_subst(e))
        return ' '.join( s )
    elif isinstance(s, UserString):
        # s.data can only be either a unicode or a regular
        # string. Please see the UserString initializer.
        return s.data
    else:
        return str(s)

the lines
        l = []
        for e in s:
            l.append(to_String_for_subst(e))
have no effect and just waste time, perhaps someone intended the return
line to be
       return ' '.join( l )
instead of
       return ' '.join( s )
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20171001/c074fcdd/attachment.html>


More information about the Scons-users mailing list