-
Notifications
You must be signed in to change notification settings - Fork 37
2.2.0 compiler migration #335
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
e9a38b6
to
33f5ff2
Compare
33f5ff2
to
0761ddd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR migrates the compiler plugin to support Kotlin 2.2.0-Beta1 by updating API usages and introducing new version‐specific helper methods via the vsApi mechanism. The key changes include adapting symbol and declaration retrieval methods, refactoring checker implementations to use object declarations and VS suffixes, and updating the IR code generation in the backend.
Reviewed Changes
Copilot reviewed 40 out of 40 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
compiler-plugin/compiler-plugin-k2/src/main/latest/kotlinx/rpc/codegen/FirVersionSpecificApiImpl.kt | Adds new VS-specific API functions for declaration and function retrieval. |
compiler-plugin/compiler-plugin-k2/src/main/core/kotlinx/rpc/codegen/serialization/annotation.kt | Updates annotation constructor resolution to conform to new vsApi calls. |
compiler-plugin/compiler-plugin-k2/src/main/core/kotlinx/rpc/codegen/checkers/*.kt | Refactors checkers to use object declarations and VS-specific methods. |
compiler-plugin/compiler-plugin-backend/** | Updates several VersionSpecificApiImpl and IR generation files to use new vsApi patterns. |
compiler-plugin/compiler-plugin-k2/build.gradle.kts | Replaces context receiver enabling with context parameter checks for Kotlin 2.2.0+ |
Comments suppressed due to low confidence (1)
compiler-plugin/compiler-plugin-backend/src/main/core/kotlinx/rpc/codegen/extension/RpcStubGenerator.kt:1484
- [nitpick] Since several similar vsApi blocks are used to assign dispatchReceiverParameterVS, consider abstracting this assignment into a helper function to reduce repetition and improve clarity.
vsApi { dispatchReceiverParameterVS = it }
...ugin/compiler-plugin-backend/src/main/core/kotlinx/rpc/codegen/extension/RpcStubGenerator.kt
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, please check minor comments
krpc/krpc-ktor/krpc-ktor-client/src/commonMain/kotlin/kotlinx/rpc/krpc/ktor/client/Krpc.kt
Outdated
Show resolved
Hide resolved
...er-plugin/compiler-plugin-k2/src/main/v_2_2/kotlinx/rpc/codegen/checkers/FirRpcCheckersVS.kt
Show resolved
Hide resolved
...er-plugin/compiler-plugin-k2/src/main/v_2_2/kotlinx/rpc/codegen/FirVersionSpecificApiImpl.kt
Show resolved
Hide resolved
...ugin/compiler-plugin-backend/src/main/core/kotlinx/rpc/codegen/extension/RpcStubGenerator.kt
Show resolved
Hide resolved
(cherry picked from commit eaaba79)
Subsystem
Compiler Plugin
Problem Description
2.2.0 Kotlin brings a lot of changes in compiler API.
Solution
Using
2.2.0-Beta1
version perform the migration