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

Add UnstableCollections rule #99

Merged
merged 2 commits into from
Oct 10, 2022
Merged

Add UnstableCollections rule #99

merged 2 commits into from
Oct 10, 2022

Conversation

mrmans0n
Copy link
Contributor

@mrmans0n mrmans0n commented Oct 10, 2022

The Compose compiler cannot infer stability for kotlin collection interfaces (List/Set/Map), so any composable with one of those (which is pretty likely) as a parameter will be deemed unstable by the compiler. This rule detects those cases and prompt the user to use the Kotlinx Immutable Collections alternative instead, or an @Immutable wrapper.

Fixes #44. (the remaining open inquiry)

The Compose compiler cannot infer stability for kotlin collection interfaces (List/Set/Map), so any composable with one of those (which is pretty likely) as a parameter will be deemed unstable by the compiler.
This rule detects those cases and prompt the user to use the Kotlinx Immutable Collections alternative instead, or an `@Immutable` wrapper.
@mrmans0n mrmans0n force-pushed the nacho/unstable-collections branch from fa0b251 to 8cd5c7c Compare October 10, 2022 10:02
@mrmans0n mrmans0n merged commit 97e9158 into main Oct 10, 2022
@mrmans0n mrmans0n deleted the nacho/unstable-collections branch October 10, 2022 11:23
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.

Discussion: How should linter requests be handled that should rather be provided by Google?
2 participants