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

Cast result of requireNoNulls to be non-null #141

Merged
merged 2 commits into from
May 24, 2021
Merged

Cast result of requireNoNulls to be non-null #141

merged 2 commits into from
May 24, 2021

Conversation

passsy
Copy link
Owner

@passsy passsy commented May 24, 2021

  • KtIterable<T?>.requireNonNulls() now returns KtIterable<T>. Same for KtList
  • New KtIterable<T>.cast<R>()allows lazily casting of KtIterable. This is useful to map between T? and T without iterating over all elements using .map. Also works for KtList
  • Fixes .dart to work for all KtIterable<T>. Was accidentally registered for KtIterable<T extends Comparable<T>> only

@passsy passsy merged commit 8d6d217 into master May 24, 2021
@passsy passsy deleted the cast branch May 24, 2021 13:51
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.

1 participant