Last active
March 17, 2018 02:53
-
-
Save marksands/239e62186f73157092110d098c78c467 to your computer and use it in GitHub Desktop.
This file contains 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
func =(_ lhs: UInt8, _ rhs: UInt8) -> UInt8 { return 0 } | |
struct WHelper { | |
subscript(_ a: (UInt8, UInt8) -> (UInt8)) -> () -> Void { | |
get { return { } } | |
} | |
} | |
func w(_ a: () -> Void) -> WHelper { | |
return WHelper() | |
} | |
struct X { | |
subscript(_ a: (UInt8, UInt8) -> (UInt8)) -> (() -> Void) -> Void { | |
get { return { _ in } } | |
} | |
} | |
let x = X() | |
struct Y { | |
subscript(_ a: (UInt8, UInt8) -> (UInt8), _ b: () -> Void) -> () -> Void { | |
get { return { } } | |
} | |
} | |
let y = Y() | |
struct z { | |
subscript(_ a: (UInt8, UInt8) -> (UInt8), _ b: () -> Void) -> Void { | |
get { } | |
} | |
} | |
w{}[&]() | |
x[&](){} | |
y[&]{}() | |
z()[&]{} | |
w{}[=]() | |
x[=](){} | |
y[=]{}() | |
z()[=]{} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment