Highlights
- switch to
Sequence
for a bunch of APIs- Some of the API return type has been changed from
Collection
orList
toSequence
, which will allow performance improvement if you use case involved early termination. - Note that because
Sequence
is lazily evaluated, it requires a terminal operation to make actual compute happen. Please check you uses around the impacted APIs to see if they have a terminal operation. Most common use case isCollection.map{}
which will iterate through the collection by itself, but is non-terminal forSequence
and should be companied withtoList()
or replaced withforEach
- For the whole list of APIs impacted by this change, please refer to this commit.
- Some of the API return type has been changed from
- Added
KSDeclaration.getDocString()
API for getting the document comment. Note that it returns as is and you might need to process the string. - Origin for KS symbols from binaries is now split into
KOTLIN_LIB
andJAVA_LIB
. - Added name mapping helper for mapping names from Kotlin to Java and Java to Kotlin.
asMemberOf()
is now a member function ofKSPropertyDeclaration
andKSFunctionDeclaration
, instead ofResolver
- Add KSType.outerType and KSType.innerArguments
- Introduce KSType.isFunctionType and KSType.isSuspendFunctionType