mirror of https://github.com/sbt/sbt.git
Merge pull request #8469 from xuwei-k/redundant-asInstanceOf
[2.x] Remove redundant `asInstanceOf`
This commit is contained in:
commit
4ff1d77e26
|
|
@ -88,7 +88,7 @@ object Previous {
|
|||
}
|
||||
Def.ScopedKey(enclosing.scope.copy(extra = Select(am)), enclosing.key)
|
||||
}
|
||||
}.asInstanceOf[AnyTaskKey]
|
||||
}
|
||||
}
|
||||
private[sbt] object Key {
|
||||
def apply[T, U](key: ScopedKey[Task[T]], enclosing: ScopedKey[Task[U]]): Key[T] =
|
||||
|
|
@ -133,7 +133,7 @@ object Previous {
|
|||
(k, v) <- successfulTaskResults
|
||||
keys <- reverse.get(k)
|
||||
key <- keys if successfulTaskResults.contains(key.enclosing)
|
||||
ref <- map.get(key.asInstanceOf[Key[Any]])
|
||||
ref <- map.get(key)
|
||||
} {
|
||||
val out = streams(key.cacheKey).cacheStoreFactory.make(StreamName)
|
||||
try out.write(v)(using ref.stamped)
|
||||
|
|
|
|||
|
|
@ -241,7 +241,7 @@ trait Init:
|
|||
m.backing.par
|
||||
.map { (k, ss) =>
|
||||
val deps = ss.iterator.flatMap(_.dependencies).toSet
|
||||
k -> Compiled(k.asInstanceOf[ScopedKey[Any]], deps, ss.asInstanceOf[SettingSeq[Any]])
|
||||
k -> Compiled(k, deps, ss)
|
||||
}
|
||||
.to(Map)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue