Add tests for obsolete issues

#KT-32207 Obsolete
 #KT-32836 Obsolete
 #KT-32949 Obsolete
 #KT-9384 Obsolete
This commit is contained in:
Mikhail Zarechenskiy
2019-08-15 10:58:38 +03:00
parent 1969ad6e9d
commit d59b910403
15 changed files with 183 additions and 0 deletions
@@ -0,0 +1,17 @@
// !DIAGNOSTICS: -UNUSED_PARAMETER
inline fun <reified T> parse(json: String): T? = TODO()
class MyType
fun parseMyData(json: String): MyType =
try {
parse(json) // error with new inf only: Cannot use 'Nothing?' as reified type parameter
?: throw IllegalArgumentException("Can't parse")
} catch (e: Exception) {
throw IllegalArgumentException("Can't parse")
}
fun main() {
parseMyData("")
}