Skip to content

Flipping curried functions. #54

Open

Description

@nikita-leonov

By default, Swift provides all entity functions as curried static functions so calls to entity functions can be represented in a two ways:

//regular use
let something: Something = ...
something.map { ... }
//curried function use
Something.map(something)({ ... })

The existing implementation of flip works only on uncurried functions, while there are a lot of use cases for a curried version of flip. Does it make sense to introduce a curried version of flip?

Activity

  1. 335g commented on Sep 28, 2016

    @335g
    Collaborator

    I think it's a good idea 👍

  2. werediver commented on Oct 5, 2016

    @werediver
    Contributor

    I think both the curried and the uncurried flip are of great value and should be implemented (I would write both from the start).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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