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

Fix compilation on Kotlin/Native #172

Merged
merged 1 commit into from
Aug 20, 2024
Merged

Fix compilation on Kotlin/Native #172

merged 1 commit into from
Aug 20, 2024

Conversation

Mr3zee
Copy link
Collaborator

@Mr3zee Mr3zee commented Aug 20, 2024

Subsystem
Compiler plugin

Problem Description
Compilation on Kotlin/Native targets produces wrong IR, leading to

kotlinx.serialization.SerializationException: Serializer for class 'rpcMethod' is not found.
Please ensure that class is marked as '@Serializable' and that the serialization compiler plugin is applied.
To get enum serializer on Kotlin/Native, it should be annotated with @Serializable annotation.
To get interface serializer on Kotlin/Native, use PolymorphicSerializer() constructor function.

Solution
Remove supertype overriding for rpcMethod classes, fixing the issue

@Mr3zee Mr3zee requested a review from e5l August 20, 2024 11:05
@Mr3zee Mr3zee self-assigned this Aug 20, 2024
@Stexxe Stexxe self-requested a review August 20, 2024 11:34
@Mr3zee Mr3zee removed the request for review from e5l August 20, 2024 11:34
@Mr3zee Mr3zee merged commit ceb9083 into main Aug 20, 2024
@Mr3zee Mr3zee deleted the fix-native-compilation branch August 20, 2024 11:36
Mr3zee added a commit that referenced this pull request Aug 27, 2024
Mr3zee added a commit that referenced this pull request Aug 27, 2024
Mr3zee added a commit that referenced this pull request Aug 30, 2024
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.

2 participants