mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-11 00:21:29 +00:00
The `@SinceKotlin("X.Y.Z")` annotation now hides a particular declaration from
resolution when the API version specified by the `-api-version` option is
_less_ than X.Y.Z. The comparison is performed as for versions in Maven:
MavenComparableVersion is in fact a copy of
org.apache.maven.artifact.versioning.ComparableVersion.
Also support "!API_VERSION" directive in diagnostic tests
#KT-14298 Fixed
19 lines
228 B
Kotlin
Vendored
19 lines
228 B
Kotlin
Vendored
// !API_VERSION: 1.1
|
|
|
|
@SinceKotlin("0.9")
|
|
fun ok1() {}
|
|
|
|
@SinceKotlin("1.0")
|
|
fun ok2() {}
|
|
|
|
@SinceKotlin("1.1")
|
|
fun ok3() {}
|
|
|
|
@SinceKotlin("0.9.9")
|
|
fun ok4() {}
|
|
|
|
fun t1() = ok1()
|
|
fun t2() = ok2()
|
|
fun t3() = ok3()
|
|
fun t4() = ok4()
|