Skip to content

Commit

Permalink
Make dynamic explicit
Browse files Browse the repository at this point in the history
  • Loading branch information
ZacSweers committed Dec 5, 2021
1 parent 17dc85e commit b62ec84
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ package com.squareup.moshi.kotlin.codegen.api

import com.squareup.kotlinpoet.AnnotationSpec
import com.squareup.kotlinpoet.ClassName
import com.squareup.kotlinpoet.Dynamic
import com.squareup.kotlinpoet.LambdaTypeName
import com.squareup.kotlinpoet.ParameterizedTypeName
import com.squareup.kotlinpoet.TypeName
Expand Down Expand Up @@ -55,6 +56,6 @@ internal fun TypeName.unwrapTypeAlias(): TypeName {
is LambdaTypeName -> {
unwrapTypeAliasInternal() ?: deepCopy(TypeName::unwrapTypeAlias)
}
else -> throw UnsupportedOperationException("Type '${javaClass.simpleName}' is illegal. Only classes, parameterized types, wildcard types, or type variables are allowed.")
Dynamic -> throw UnsupportedOperationException("Type '${javaClass.simpleName}' is illegal. Only classes, parameterized types, wildcard types, or type variables are allowed.")
}
}

0 comments on commit b62ec84

Please sign in to comment.