Skip to content

Commit

Permalink
(#19) Fix fallback strategy for ImmutableCollection
Browse files Browse the repository at this point in the history
  • Loading branch information
jayasuryat committed Apr 13, 2024
1 parent 49e124c commit 3b39f29
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,15 @@ internal class ExistingDeclarations(
}
internal val persistentList: KSType by unsafeLazy {
val ksName = resolver.getKSNameFromString(Names.persistentList.canonicalName)
resolver.getClassDeclarationByName(ksName)!!.asStarProjectedType()
resolver.getClassDeclarationByName(ksName)?.asStarProjectedType() ?: builtIns.unitType
}
internal val persistentSet: KSType by unsafeLazy {
val ksName = resolver.getKSNameFromString(Names.persistentSet.canonicalName)
resolver.getClassDeclarationByName(ksName)!!.asStarProjectedType()
resolver.getClassDeclarationByName(ksName)?.asStarProjectedType() ?: builtIns.unitType
}
internal val persistentMap: KSType by unsafeLazy {
val ksName = resolver.getKSNameFromString(Names.persistentMap.canonicalName)
resolver.getClassDeclarationByName(ksName)!!.asStarProjectedType()
resolver.getClassDeclarationByName(ksName)?.asStarProjectedType() ?: builtIns.unitType
}
internal val mutableStateFlow: KSType by unsafeLazy {
val ksName = resolver.getKSNameFromString(Names.mutableStateFlowName.canonicalName)
Expand Down

0 comments on commit 3b39f29

Please sign in to comment.