Get rid of deprecated annotations and modifiers in project code

This commit is contained in:
Denis Zharkov
2015-09-14 16:26:59 +03:00
parent 02aafe4262
commit 9c4564a5a6
204 changed files with 485 additions and 439 deletions
@@ -45,8 +45,7 @@ import org.jetbrains.kotlin.types.typeUtil.TypeNullability
import org.jetbrains.kotlin.types.typeUtil.nullability
import java.util.*
@tailRecursive
fun <T : Any> LookupElement.putUserDataDeep(key: Key<T>, value: T?) {
tailrec fun <T : Any> LookupElement.putUserDataDeep(key: Key<T>, value: T?) {
if (this is LookupElementDecorator<*>) {
getDelegate().putUserDataDeep(key, value)
}
@@ -55,8 +54,7 @@ fun <T : Any> LookupElement.putUserDataDeep(key: Key<T>, value: T?) {
}
}
@tailRecursive
fun <T : Any> LookupElement.getUserDataDeep(key: Key<T>): T? {
tailrec fun <T : Any> LookupElement.getUserDataDeep(key: Key<T>): T? {
if (this is LookupElementDecorator<*>) {
return getDelegate().getUserDataDeep(key)
}
@@ -169,7 +169,7 @@ fun<TDescriptor: DeclarationDescriptor?> MutableCollection<LookupElement>.addLoo
for (info in expectedInfos) {
val classification = infoClassifier(info)
if (classification.substitutor != null) {
@suppress("UNCHECKED_CAST")
@Suppress("UNCHECKED_CAST")
val substitutedDescriptor = descriptor.substituteFixed(classification.substitutor)
val map = if (classification.makeNotNullable) makeNullableInfos else matchedInfos
map.getOrPut(ItemData(substitutedDescriptor, info.itemOptions)) { ArrayList() }.add(info)
@@ -24,7 +24,7 @@ import org.jetbrains.kotlin.idea.core.formatter.JetCodeStyleSettings
import org.jetbrains.kotlin.idea.test.PluginTestCaseBase
import java.io.File
deprecated("All tests from here to be moved to the generated test")
@Deprecated("All tests from here to be moved to the generated test")
public class BasicCompletionHandlerTest : CompletionHandlerTestBase(){
private fun checkResult(){
fixture.checkResultByFile(getTestName(false) + ".kt.after")