Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
JSoto
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
10 ms
·
1.
▲
by
JSoto
11y ago
iOS engineer who worked on the Fabric app here :) I gave a talk about this topic at a Swift conference last year, if you wanna check that out! https://www.youtube.com/watch?v=Ent6LJDIB3I
2.
▲
by
JSoto
12y ago
Oh yeah that's a good point! (and a really interesting optimization that can be applied to immutable values)
3.
▲
by
JSoto
12y ago
I agree that it would be a little cleaner, because it would express the intention better (the fact that you're simply giving out the same error). However, the type would be wrong: Yeah, this is correct. This would be wrong: func
4.
▲
by
JSoto
12y ago
Yeah, this is correct. This would be wrong: func map<U>(f: T -> U) -> Result<U> { switch self { case let .Value(value): return Result<U>.Value(Box(f(value.unbox))) case let .
5.
▲
by
JSoto
12y ago
Thanks! I think that would make for another interesting article. I purposely ignored those details to make sure I kept my article more practical and less academic :) I also didn't mention the unit function of Monads (is that equivalent
6.
▲
Functor and Monad in Swift
(javiersoto.me)
50 points
by
JSoto
12y ago
|
18 comments
7.
▲
MSActiveConfig: Remote configuration and A/B Testing framework for iOS
(github.com)
8 points
by
JSoto
13y ago
|
0 comments