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

Data.List.NonEmpty.intersect and Data.List.NonEmpty.intersectBy throw when intersection empty #216

Open
evaogbe-vermeer opened this issue Dec 11, 2023 · 2 comments · May be fixed by #217
Open
Labels
good first issue First-time contributors who are looking to help should work on these issues. type: bug Something that should function correctly isn't.

Comments

@evaogbe-vermeer
Copy link

I think they should be changed to match the implementation of the corresponding functions in NonEmptyArray, i.e. return a List instead of a NonEmptyList.

Alternatively, I saw the discussion in #184 about potentially removing the set functions from Array, List, NonEmptyList, NonEmptyArray, etc. and replacing them with an ordered set type. This might be more evidence supporting those who want to remove them.

@garyb
Copy link
Member

garyb commented Dec 11, 2023

Ah yeah, they should definitely return List!

@garyb garyb added type: bug Something that should function correctly isn't. good first issue First-time contributors who are looking to help should work on these issues. labels Dec 11, 2023
@evaogbe
Copy link

evaogbe commented Dec 14, 2023

Oops just realized I reported the issue on my work account. The PR with the fix is using the correct personal account.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue First-time contributors who are looking to help should work on these issues. type: bug Something that should function correctly isn't.
Projects
None yet
3 participants