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

Kotlin: Don't convert back and forth between ClassId and FqName #14529

Merged
merged 1 commit into from Oct 20, 2023

Conversation

igfoo
Copy link
Contributor

@igfoo igfoo commented Oct 17, 2023

This showed up as a bug in Kotlin 2 mode:

We were starting with the Class Id "java/util/Map.Entry", which we then converted to the FqName "java.util.Map.Entry", and then back to a Class Id with ClassId.topLevel. This gave us a Class Id that referenceClass wasn't able to resolve.

Now we just stick with the Class Id that we started with, and the class can be resolved by Kotlin 2.

This showed up as a bug in Kotlin 2 mode:

We were starting with the Class Id "java/util/Map.Entry", which we then
converted to the FqName "java.util.Map.Entry", and then back to a
Class Id with ClassId.topLevel. This gave us a Class Id that
referenceClass wasn't able to resolve.

Now we just stick with the Class Id that we started with, and the class
can be resolved by Kotlin 2.
@igfoo igfoo marked this pull request as ready for review October 19, 2023 17:19
@igfoo igfoo requested a review from a team as a code owner October 19, 2023 17:19
@igfoo igfoo merged commit a4ef183 into github:main Oct 20, 2023
12 checks passed
@igfoo igfoo deleted the igfoo/classid_fqname branch October 20, 2023 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants