diff options
Diffstat (limited to 'src/engine/SCons/Environment.py')
-rw-r--r-- | src/engine/SCons/Environment.py | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/engine/SCons/Environment.py b/src/engine/SCons/Environment.py index 529e3a3..d7b4022 100644 --- a/src/engine/SCons/Environment.py +++ b/src/engine/SCons/Environment.py @@ -2238,7 +2238,20 @@ class Base(SubstitutionEnvironment): # srcnode = file.srcnode() # while srcnode != file.srcnode(): # srcnode = file.srcnode() - + # ------------------------------------------------------------------ + # Sure!, the above code is like: + # + # a = b + # while a != b: + # a = b + # return c + # + # Let's do the job as below: + def final_source(node): + while (node != node.srcnode()): + node = node.srcnode() + return node + sources = map( final_source, sources ); # remove duplicates return list(set(sources)) |