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

No orEmpty function for ImmutableList? #182

Open
Abhimanyu14 opened this issue May 15, 2024 · 1 comment · May be fixed by #183
Open

No orEmpty function for ImmutableList? #182

Abhimanyu14 opened this issue May 15, 2024 · 1 comment · May be fixed by #183

Comments

@Abhimanyu14
Copy link

Abhimanyu14 commented May 15, 2024

Can we add an extension function similar to List for ImmutableList?

@kotlin.internal.InlineOnly
public inline fun <T> ImmutableList<T>?.orEmpty(): ImmutableList<T> = this ?: persistentListOf()
@Goooler Goooler linked a pull request May 15, 2024 that will close this issue
@qurbonzoda
Copy link
Contributor

qurbonzoda commented Nov 3, 2024

Related #10, #181

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 a pull request may close this issue.

2 participants