diff options
author | Egor Andreevich <egor@squareup.com> | 2021-11-18 09:07:30 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-18 09:07:30 -0500 |
commit | 9783e0f04a7d75e70f5152b553d0d57deb957554 (patch) | |
tree | dd0e405cdf4fc31c0f8f48858c802d67a435628d /kotlinpoet | |
parent | 9a6bf87ddaa6e111f4e4c08cf09fea4211253843 (diff) | |
download | kotlinpoet-9783e0f04a7d75e70f5152b553d0d57deb957554.tar.gz |
Kotlin 1.6.0 (#1188)
* Kotlin 1.6.0
* Update KCT
* Synthetic method annotations may not always be present
* typeNameOf not experimental anymore
Co-authored-by: Zac Sweers <pandanomic@gmail.com>
Diffstat (limited to 'kotlinpoet')
4 files changed, 0 insertions, 4 deletions
diff --git a/kotlinpoet/src/main/java/com/squareup/kotlinpoet/TypeName.kt b/kotlinpoet/src/main/java/com/squareup/kotlinpoet/TypeName.kt index 0b42187b..d6af6926 100644 --- a/kotlinpoet/src/main/java/com/squareup/kotlinpoet/TypeName.kt +++ b/kotlinpoet/src/main/java/com/squareup/kotlinpoet/TypeName.kt @@ -294,5 +294,4 @@ public fun Type.asTypeName(): TypeName = TypeName.get(this, mutableMapOf()) * Returns a [TypeName] equivalent of the reified type parameter [T] using reflection, maybe using kotlin-reflect * if required. */ -@ExperimentalStdlibApi public inline fun <reified T> typeNameOf(): TypeName = typeOf<T>().asTypeName() diff --git a/kotlinpoet/src/test/java/com/squareup/kotlinpoet/FileSpecTest.kt b/kotlinpoet/src/test/java/com/squareup/kotlinpoet/FileSpecTest.kt index ef71a607..5dec3945 100644 --- a/kotlinpoet/src/test/java/com/squareup/kotlinpoet/FileSpecTest.kt +++ b/kotlinpoet/src/test/java/com/squareup/kotlinpoet/FileSpecTest.kt @@ -1059,7 +1059,6 @@ class FileSpecTest { class WackyKey class OhNoThisDoesNotCompile - @OptIn(ExperimentalStdlibApi::class) @Test fun longCommentWithTypes() { val someLongParameterizedTypeName = typeNameOf<List<Map<in String, Collection<Map<WackyKey, out OhNoThisDoesNotCompile>>>>>() val param = ParameterSpec.builder("foo", someLongParameterizedTypeName).build() diff --git a/kotlinpoet/src/test/java/com/squareup/kotlinpoet/TypeNameKotlinTest.kt b/kotlinpoet/src/test/java/com/squareup/kotlinpoet/TypeNameKotlinTest.kt index cbbe5bdf..3c16242a 100644 --- a/kotlinpoet/src/test/java/com/squareup/kotlinpoet/TypeNameKotlinTest.kt +++ b/kotlinpoet/src/test/java/com/squareup/kotlinpoet/TypeNameKotlinTest.kt @@ -18,7 +18,6 @@ package com.squareup.kotlinpoet import com.google.common.truth.Truth.assertThat import org.junit.Test -@ExperimentalStdlibApi class TypeNameKotlinTest { @Test diff --git a/kotlinpoet/src/test/java/com/squareup/kotlinpoet/UtilTest.kt b/kotlinpoet/src/test/java/com/squareup/kotlinpoet/UtilTest.kt index 20376501..09ad8f0c 100644 --- a/kotlinpoet/src/test/java/com/squareup/kotlinpoet/UtilTest.kt +++ b/kotlinpoet/src/test/java/com/squareup/kotlinpoet/UtilTest.kt @@ -96,7 +96,6 @@ class UtilTest { assertThat("with_unicode_punctuation\u2026".escapeIfNecessary()).isEqualTo("`with_unicode_punctuation\u2026`") } - @OptIn(ExperimentalStdlibApi::class) @Test fun escapeSpaceInName() { val generated = FileSpec.builder("a", "b") .addFunction( |