Last active
May 16, 2016 03:49
-
-
Save matux/ecfd82472d6f50b7553f to your computer and use it in GitHub Desktop.
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 Protocolable { | |
| func function() | |
| } | |
| extension Protocolable where Self: BaseClass { | |
| func function() { | |
| print("yay") | |
| } | |
| } | |
| extension Class: Protocolable { | |
| } | |
| //////////////////////////////////////////////////////////////////////////////////////////// | |
| // separate file | |
| class BaseClass {} | |
| class Class: BaseClass { | |
| func theFunction() { | |
| self.function() | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment