https://github.com/yusukehosonuma/flatten
Flatten method reference that resolved to SE-0042.
https://github.com/yusukehosonuma/flatten
functional-programming swift
Last synced: 2 days ago
JSON representation
Flatten method reference that resolved to SE-0042.
- Host: GitHub
- URL: https://github.com/yusukehosonuma/flatten
- Owner: YusukeHosonuma
- License: mit
- Created: 2020-03-27T05:32:35.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-07-22T05:44:54.000Z (almost 3 years ago)
- Last Synced: 2025-03-16T09:14:52.270Z (4 months ago)
- Topics: functional-programming, swift
- Language: Swift
- Size: 30.3 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Flatten
[](https://cocoapods.org/pods/Flatten)

[](https://github.com/YusukeHosonuma/Flatten/blob/master/LICENSE)
[](https://twitter.com/tobi462)Flatten instance method reference that resolved to [SE-0042](https://github.com/apple/swift-evolution/blob/master/proposals/0042-flatten-method-types.md).
```swift
let f: (String) -> (String) -> Bool = String.hasPrefix// function is curried
f("Hello")("He") // => truelet __f: (String, String) -> Bool = flatten(f)
// function is flattend
__f("Hello", "He") // => true
```## Limitation
Only up to **20 arguments** are supported.
## Author
Yusuke Hosonuma / [email protected] / [@tobi462](https://twitter.com/tobi462)
## License
[Flatten](https://github.com/YusukeHosonuma/Flatten) is available under the MIT license. See the LICENSE file for more info.