Skip to content

Generalize filterM (etc.?) to Applicative #162

@glebec

Description

@glebec

Today I noticed that PureScript filterM is constrained to Monad, whereas Haskell filterM is constrained to Applicative. After looking at the source code for each and asking on FP Slack, it seems there is no particular reason filterM cannot be more general in PS.

#35 was set to change this and some other things (e.g. replicateM). However, that PR was closed due to staleness. The author @DavidHarrison was going to split it up into individual PRs, but hasn't gotten around to it yet. It seems worthwhile to double-check that PR to see if there is anything else from it you may want to merge.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions