@@ -853,7 +853,7 @@ extension Driver {
853853
854854extension Driver {
855855 public mutating func computeOutputCacheKeyForJob( commandLine: [ Job . ArgTemplate ] ,
856- inputs: [ TypedVirtualPath ] ) throws -> [ TypedVirtualPath : String ] {
856+ inputs: [ ( TypedVirtualPath , Int ) ] ) throws -> [ TypedVirtualPath : String ] {
857857 // No caching setup, return empty dictionary.
858858 guard let cas = self . cas else {
859859 return [ : ]
@@ -863,22 +863,20 @@ extension Driver {
863863 let arguments : [ String ] = try resolver. resolveArgumentList ( for: commandLine)
864864
865865 return try inputs. reduce ( into: [ : ] ) { keys, input in
866- let remappedPath = remapPath ( input. file)
867- keys [ input] = try cas. computeCacheKey ( commandLine: arguments, input: remappedPath. name)
866+ keys [ input. 0 ] = try cas. computeCacheKey ( commandLine: arguments, index: input. 1 )
868867 }
869868 }
870869
871870 public mutating func computeOutputCacheKey( commandLine: [ Job . ArgTemplate ] ,
872- input : TypedVirtualPath ) throws -> String ? {
871+ index : Int ) throws -> String ? {
873872 // No caching setup, return empty dictionary.
874873 guard let cas = self . cas else {
875874 return nil
876875 }
877876 // Resolve command-line first.
878877 let resolver = try ArgsResolver ( fileSystem: fileSystem)
879878 let arguments : [ String ] = try resolver. resolveArgumentList ( for: commandLine)
880- let remappedPath = remapPath ( input. file)
881- return try cas. computeCacheKey ( commandLine: arguments, input: remappedPath. name)
879+ return try cas. computeCacheKey ( commandLine: arguments, index: index)
882880 }
883881}
884882
0 commit comments