objcio / issue-16-functional-apis

Example playground for the article http://www.objc.io/issue16/functional-swift-apis.html
13 stars 3 forks source link

Added Objective-C implementation #3

Open etrep opened 9 years ago

etrep commented 9 years ago

I was having problems running the Swift version of this code sample (see https://github.com/objcio/issue-16-functional-apis/issues/2) so I decided to write an Objective-C version.

I'm new to functional programming, and I'm enjoying the topic very much. I've tried to stick as close to the Swift implementation as possible. The ability to override or define new operators does not exist in Objective-C so my implementation of the filter composition syntax is not quite as elegant, but I can still see the benefits of this approach in general.

I don't know if this Objective-C version can be of interest to anyone, but I'm happy to offer it if it's helpful.