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

Make VariantArray and Dictionary constructors visible to Java #685

Merged
merged 2 commits into from
Sep 12, 2024

Conversation

CedNaru
Copy link
Member

@CedNaru CedNaru commented Sep 5, 2024

I just discovered from a Discord conversation that it was not possible to create a new VariantArray and Dictionary from Java.
They both require a KClass which is a Kotlin STD object and the fake constructor we use for it is inlined when the actual one is internal. Inline functions are not visible from Java.

I created a new public constructor that directly take Java classes as arguments. Boilerplate to use, but we have no choice.

@CedNaru CedNaru changed the title Make constructors visible to Java Make VariantArray and Dictionary constructors visible to Java Sep 5, 2024
@CedNaru CedNaru force-pushed the java/make_array_dict_constructors_visible branch from 1f0fc90 to 4b5143e Compare September 7, 2024 03:56
@CedNaru CedNaru merged commit 8008eaa into master Sep 12, 2024
50 checks passed
@CedNaru CedNaru deleted the java/make_array_dict_constructors_visible branch September 12, 2024 08:42
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