This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protocol A { } | |
struct AImpl: A { | |
init() { } | |
} | |
protocol B { | |
associatedtype BA: A | |
var a: BA { get } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// started from https://gist.github.com/chriseidhof/f6d9b42c709a83413e84cafc0f7295cd | |
import SwiftUI | |
import Combine | |
struct Reader<R, A> { | |
public let run: (R) -> A | |
public static func pure(_ a: A) -> Reader<R, A> { | |
return Reader<R, A> { _ in a } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct Hole<T> { | |
static var value: T { | |
fatalError("Unfilled hole of type `\(String(describing: T.self))`") | |
} | |
} | |
enum Result<T, E: Error> { | |
case success(T) | |
case failure(E) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am r-peck on github. | |
* I am ryanpeck (https://keybase.io/ryanpeck) on keybase. | |
* I have a public key whose fingerprint is 18A5 26D3 7296 9175 9DD6 3345 68EC 2FE0 CD84 1547 | |
To claim this, I am signing this object: |