Skip to content

Remove empty list error states in waitAny* functions #154

@414owen

Description

@414owen

I was debugging a thread blocked indefinitely on STM Transaction error recently, which ended up being caused by calling waitAnyCancel with an empty list.

More recent versions of async throw custom errors when this family of functions is passed an empty list.

I was wondering if, instead of throwing an error when passed empty lists, it would be better for these functions to take a Data.List.NonEmpty, which is in base?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions