Minor refactoring of ResolveElementCache #KT-21132 Fixed

Get rid of SoftValueMap.containsKey
This commit is contained in:
Mikhail Glukhikh
2017-11-10 16:27:45 +03:00
parent f51974b271
commit f43360177a
@@ -172,8 +172,8 @@ class ResolveElementCache(
val resolveToCache = CachedPartialResolve(bindingContext, file, bodyResolveMode)
for (statement in (statementFilter as PartialBodyResolveFilter).allStatementsToResolve) {
if (!partialResolveMap.containsKey(statement) && bindingContext[BindingContext.PROCESSED, statement] == true) {
partialResolveMap[statement] = resolveToCache
if (bindingContext[BindingContext.PROCESSED, statement] == true) {
partialResolveMap.putIfAbsent(statement, resolveToCache)
}
}