Add explicit return types to several test data files so that AST access is not needed

Test cases are chosen so that addition/removal of explicit type will not interfere with the original purpose of the test
This commit is contained in:
Pavel V. Talanov
2014-04-10 18:39:42 +04:00
parent a807712ce7
commit 72bdacb074
29 changed files with 38 additions and 38 deletions
@@ -1,3 +1,3 @@
package test
fun <T> f() = 1
fun <T> f(): Int = 1
@@ -1,3 +1,3 @@
package test
fun <P> funParamParam(a: Int, b: P) = 1
fun <P> funParamParam(a: Int, b: P): Int = 1
@@ -1,3 +1,3 @@
package test
fun <P> funParamParam(a: Int, b: P) = 1
fun <P> funParamParam(a: Int, b: P): Int = 1
@@ -1,3 +1,3 @@
package test
fun <P, Q : P> funParamReferencesParam() = 1
fun <P, Q : P> funParamReferencesParam(): Int = 1
@@ -3,6 +3,6 @@ package test
trait Foo
trait Bar
fun <T> foo()
fun <T> foo(): Unit
where T : Foo, T : Bar
= Unit.VALUE
@@ -1,3 +1,3 @@
package test
fun <A : java.lang.Number> uno() = 1
fun <A : java.lang.Number> uno(): Int = 1
@@ -1,3 +1,3 @@
package test
fun <A> tres() where A : java.lang.Number, A : java.io.Serializable = 1
fun <A> tres(): Int where A : java.lang.Number, A : java.io.Serializable = 1
@@ -1,3 +1,3 @@
package test
fun <A : java.io.Serializable> dos() = 1
fun <A : java.io.Serializable> dos(): Int = 1
@@ -1,3 +1,3 @@
package test
fun <P> funParamVarargParam(a: Int, vararg b: P) = 1
fun <P> funParamVarargParam(a: Int, vararg b: P): Int = 1
@@ -1,3 +1,3 @@
package test
fun <P, Q> funTwoTypeParams() = 1
fun <P, Q> funTwoTypeParams(): Int = 1
@@ -1,5 +1,5 @@
package test
class River {
fun song() = 1
fun song(): Int = 1
}
@@ -1,5 +1,5 @@
package test
class ClassFunGetFoo {
fun getFoo() = 1
fun getFoo(): Int = 1
}
@@ -1,6 +1,6 @@
package test
class ClassFunGetFoo {
fun getFoo() = 1
fun getFoo(): Int = 1
fun setFoo(p: Int) {}
}
@@ -1,3 +1,3 @@
package test
fun Int.shuffle() = 1
fun Int.shuffle(): Int = 1
@@ -1,5 +1,5 @@
package test
class ExtFunInClass {
fun Int.shuffle() = 1
fun Int.shuffle(): Int = 1
}
@@ -1,3 +1,3 @@
package test
fun funDefaultArg(p: Int, q: Int = 17, r: Int = 18) = 19
fun funDefaultArg(p: Int, q: Int = 17, r: Int = 18): Int = 19
@@ -1,3 +1,3 @@
package test
fun fff(a: java.lang.Integer) = 1
fun fff(a: java.lang.Integer): Int = 1
@@ -1,3 +1,3 @@
package test
fun varargInt(a: Int, vararg b: Int) = 1
fun varargInt(a: Int, vararg b: Int): Int = 1
@@ -1,3 +1,3 @@
package test
fun varargCharSequence(a: Int, vararg b: java.lang.Integer) = 1
fun varargCharSequence(a: Int, vararg b: java.lang.Integer): Int = 1
@@ -1,5 +1,5 @@
package test
open class ModifierOpen {
open fun abs() = 1
open fun abs(): Int = 1
}
@@ -1,3 +1,3 @@
package test
fun f() = 1
fun f(): Int = 1
@@ -1,3 +1,3 @@
package test
fun getFoo() = 1
fun getFoo(): Int = 1