Skip to content

[FIR] Change companion extension (de)serialization#6495

Open
Kirill Rakhman (cypressious) wants to merge 2 commits into
masterfrom
krakhman/companion_extensions_metadata
Open

[FIR] Change companion extension (de)serialization#6495
Kirill Rakhman (cypressious) wants to merge 2 commits into
masterfrom
krakhman/companion_extensions_metadata

Conversation

@cypressious

Copy link
Copy Markdown
Contributor

No description provided.

@kotlin-safemerge

kotlin-safemerge Bot commented Jul 2, 2026

Copy link
Copy Markdown

@kodee-bot

kodee-bot Bot commented Jul 2, 2026

Copy link
Copy Markdown

This merge request potentially modifies the stubs format, but doesn't update KotlinStubVersions.kt.
Please verify whether a stub version bump is needed in compiler/psi/psi-api/src/org/jetbrains/kotlin/psi/stubs/KotlinStubVersions.kt.
If you are unsure, please consult with the Analysis API team (#kotlin-analysis-api in Slack).

Write companion extension receiver type to a new field instead of
reusing the extension receiver parameter field.

Don't write the isStatic flag for companion extensions because it can be
inferred from the new field mentioned above.

#KT-87389 Fixed
@cypressious Kirill Rakhman (cypressious) force-pushed the krakhman/companion_extensions_metadata branch from b04264f to 898f41e Compare July 2, 2026 11:30

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

/final

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

/final

@demiurg906

Copy link
Copy Markdown
Contributor

Please create a follow-up issue for supporting the new metadata field in kotlinx-metadata.

@yanex

Copy link
Copy Markdown
Member

Inviting Dmitrii Gridin (@dimonchik0036) as an owner of the deserialization subsystem.

@udalov Alexander Udalov (udalov) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I suggest to increase MetadataVersion.INSTANCE to 2.4.1. It will help in case we'd need some dirty hacks to differentiate between the old and new metadata.

@cypressious

Copy link
Copy Markdown
Contributor Author

Please create a follow-up issue for supporting the new metadata field in kotlinx-metadata.

KT-87407

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants