Skip to content
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

Remove all deprecated APIs from the compiler plugin. #1476

Merged
merged 4 commits into from
Aug 15, 2023

Conversation

cmelchior
Copy link
Contributor

@cmelchior cmelchior commented Aug 7, 2023

This PR reworks the compiler plugin, so it no longer uses deprecated APIs. This should move us closer to K2 support, but I'm keeping support out of this for now.

  • All APIs using descriptors have been changed to IR-based APIs.
  • All APIs marked with @FirIncompatiblePluginAPI has been reworked.
  • Both of the two above required changing from using FqNames to ClassId and CallableId.

Regarding testing. Our library is built and tested with Kotlin 1.8.21. We do have a minimal sample project being built with 1.8.20, but I'll see if all tests run on 1.8.20 as well, just to be sure we are not breaking backwards compatibility.

@cmelchior cmelchior changed the title Remove all descriptor based APIs from the compiler plugin. Remove all deprecated APIs from the compiler plugin. Aug 7, 2023
@cmelchior
Copy link
Contributor Author

Using Kotlin 1.8.0, Gradle 7.3.3, and AGP 7.2.0, I hit a few cases not covered by our minimal sample project. I had to backport a single helper method and work around another case where a helper method was no longer available. But with these changes all tests run locally.

@cmelchior cmelchior requested a review from rorbech August 7, 2023 19:52
Copy link
Contributor

@rorbech rorbech left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - Only some minor suggestions, but you may skip them. Seems like we still have identifiers here and there anyway, so wouldn't bother if we don't normalize all of them in this go.

@cmelchior cmelchior merged commit 310556e into main Aug 15, 2023
1 check passed
@cmelchior cmelchior deleted the cm/remote-descriptor-based-api branch August 15, 2023 10:47
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants