Last active
February 19, 2019 08:15
-
-
Save mateuszszklarek/07e06efa16b61ead13db691eb36bcd39 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 foo(_ fn: @autoclosure () -> Int) {} | |
func bar(_ fn: @autoclosure () -> Int) { | |
foo(fn) // Incorrect, `fn` can't be forwarded and has to be called. | |
foo(fn()) // OK | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment