Potential fix for some random errors about "cannot choose between equals invoke functions".
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
OUT:
|
||||
Buildfile: [TestData]/build.xml
|
||||
|
||||
build:
|
||||
[kotlinc] Compiling [[TestData]/test.kt] => [[Temp]/test.jar]
|
||||
[exec] 6
|
||||
|
||||
BUILD SUCCESSFUL
|
||||
Total time: [time]
|
||||
|
||||
Return code: 0
|
||||
@@ -0,0 +1,12 @@
|
||||
<project name="Ant Task Test" default="build">
|
||||
<taskdef resource="org/jetbrains/kotlin/ant/antlib.xml" classpath="${kotlin.lib}/kotlin-ant.jar"/>
|
||||
|
||||
<target name="build">
|
||||
<kotlinc src="${test.data}/test.kt" classpath="${test.data}/valInside.jar" output="${temp}/test.jar" nowarn="true" />
|
||||
|
||||
<exec executable="java">
|
||||
<arg line="-classpath ${temp}/test.jar bar.TestKt"/>
|
||||
</exec>
|
||||
</target>
|
||||
|
||||
</project>
|
||||
@@ -0,0 +1,10 @@
|
||||
package bar
|
||||
|
||||
@Suppress("REDECLARATION")
|
||||
val foo: Int = 6
|
||||
|
||||
operator fun Int.invoke() = this
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
println(foo())
|
||||
}
|
||||
Binary file not shown.
Reference in New Issue
Block a user