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

Probable missuse of Optin #22

Open
Gounlaf opened this issue Dec 27, 2023 · 0 comments
Open

Probable missuse of Optin #22

Gounlaf opened this issue Dec 27, 2023 · 0 comments

Comments

@Gounlaf
Copy link

Gounlaf commented Dec 27, 2023

👋

I found your library on #kotlinlang slack 🙂.

Looking at arrays and gradle file, I'm a bit confused about the OptIn. If I'm right, you should not OptIn yourself, but propagate it (because you are building a library).

Here is a thread about this issue : https://kotlinlang.slack.com/archives/C3SGXARS6/p1696410990448249

Quoting CLOVIS-AI:

if you're making library, do not opt-in at the module-level, in fact, do not opt-in at all. Instead, propagate the warning to your users, otherwise their projects will break whenever this gets changed

You're calling a function which is marked as experimental by the @ExperimentalSerializationApi annotation.
If you want to propagate the experimental warning to your caller, just annotate your function with @ExperimentalSerializationApi as well, this way they get the same warning :)

I may be wrong.

Regards.

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

No branches or pull requests

1 participant