Skip to content

Generalize (.) ? #309

@ekmett

Description

@ekmett

Is your feature request related to a problem? Please describe.
Right now folks are generally used to being able to throw (.) at their problems. Can Prelude.Linear's (.) be generalized?

Describe the solution you'd like

(.) :: (b %m -> c) %m -> (a %m -> b) %m -> (a %m -> c)
(.) f g x = f (g x)

Describe alternatives you've considered
Defining a one-off linear (.) can also be done, but this subsumes both. With LinearHaskell turned off it seems like this falls back to the regular (.).

Additional context
Add any other context or screenshots about the feature request here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions