Skip to content

ZipList is Bind #219

Open
Open
@worldmaker18349276

Description

@worldmaker18349276

instance zipListIsNotBind
:: Fail (Text """
ZipList is not Bind. Any implementation would break the associativity law.
Possible alternatives:
Data.List.List
Data.List.Lazy.List
""")
=> Bind ZipList where
bind = unsafeCrashWith "bind: unreachable"

ZipList is Bind, in which join is just diagonal. It's also Monad and MonadPlus.

Example: https://try.purescript.org/?gist=4888527a78d71d12df75fa628acd4719

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